From: Changhuang Liang <changhuang.liang@starfivetech.com>
To: Mauro Carvalho Chehab <mchehab@kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Matthias Brugger <matthias.bgg@gmail.com>,
Hans Verkuil <hverkuil-cisco@xs4all.nl>,
Ming Qian <ming.qian@nxp.com>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
Nicolas Dufresne <nicolas.dufresne@collabora.com>,
Benjamin Gaignard <benjamin.gaignard@collabora.com>,
Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>,
Mingjia Zhang <mingjia.zhang@mediatek.com>
Cc: Jack Zhu <jack.zhu@starfivetech.com>,
Changhuang Liang <changhuang.liang@starfivetech.com>,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-staging@lists.linux.dev
Subject: [PATCH v3 02/13] media: Documentation: Add description for StarFive ISP metadata formats
Date: Mon, 5 Feb 2024 01:04:13 -0800 [thread overview]
Message-ID: <20240205090424.40302-3-changhuang.liang@starfivetech.com> (raw)
In-Reply-To: <20240205090424.40302-1-changhuang.liang@starfivetech.com>
Add description for V4L2_META_FMT_STF_ISP_PARAMS and
V4L2_META_FMT_STF_ISP_STAT_3A meta data formats.
Signed-off-by: Changhuang Liang <changhuang.liang@starfivetech.com>
---
.../media/v4l/metafmt-starfive-isp.rst | 75 +++++++++++++++++++
MAINTAINERS | 1 +
2 files changed, 76 insertions(+)
create mode 100644 Documentation/userspace-api/media/v4l/metafmt-starfive-isp.rst
diff --git a/Documentation/userspace-api/media/v4l/metafmt-starfive-isp.rst b/Documentation/userspace-api/media/v4l/metafmt-starfive-isp.rst
new file mode 100644
index 000000000000..ebb4291833d6
--- /dev/null
+++ b/Documentation/userspace-api/media/v4l/metafmt-starfive-isp.rst
@@ -0,0 +1,75 @@
+.. SPDX-License-Identifier: GPL-2.0
+
+.. _v4l2-meta-fmt-stf-isp-params:
+
+.. _v4l2-meta-fmt-stf-isp-stat-3a:
+
+*****************************************************************************
+V4L2_META_FMT_STF_ISP_PARAMS ('stfp'), V4L2_META_FMT_STF_ISP_STAT_3A ('stfs')
+*****************************************************************************
+
+.. jh7110_isp_params_buffer
+
+Configuration parameters
+========================
+
+The configuration parameters are passed to the "output_params" metadata output
+video node, using the :c:type:`v4l2_meta_format` interface. They are formatted
+as described by the :c:type:`jh7110_isp_params_buffer` structure.
+
+.. code-block:: c
+
+ struct jh7110_isp_params_buffer {
+ __u32 enable_setting;
+ struct jh7110_isp_wb_setting wb_setting;
+ struct jh7110_isp_car_setting car_setting;
+ struct jh7110_isp_ccm_setting ccm_setting;
+ struct jh7110_isp_cfa_setting cfa_setting;
+ struct jh7110_isp_ctc_setting ctc_setting;
+ struct jh7110_isp_dbc_setting dbc_setting;
+ struct jh7110_isp_dnyuv_setting dnyuv_setting;
+ struct jh7110_isp_gmargb_setting gmargb_setting;
+ struct jh7110_isp_lccf_setting lccf_setting;
+ struct jh7110_isp_obc_setting obc_setting;
+ struct jh7110_isp_oecf_setting oecf_setting;
+ struct jh7110_isp_r2y_setting r2y_setting;
+ struct jh7110_isp_sat_setting sat_setting;
+ struct jh7110_isp_sharp_setting sharp_setting;
+ struct jh7110_isp_ycrv_setting ycrv_setting;
+ struct jh7110_isp_sc_setting sc_setting;
+ };
+
+.. jh7110_isp_sc_buffer
+
+3A and histogram statistics
+===========================
+
+The ISP device collects different statistics over an input Bayer frame.
+Those statistics are obtained from the "capture_scd" metadata capture video
+node, using the :c:type:`v4l2_meta_format` interface. They are formatted as
+described by the :c:type:`jh7110_isp_sc_buffer` structure.
+
+.. code-block:: c
+
+ struct jh7110_isp_sc_buffer {
+ __u32 y_histogram[64];
+ __u32 reserv0[33];
+ __u32 bright_sc[4096];
+ __u32 reserv1[96];
+ __u32 ae_hist_y[128];
+ __u32 reserv2[511];
+ __u16 flag;
+ };
+
+The statistics collected are Auto Exposure, AWB (Auto-white balance), Histogram
+and AF (Auto-focus). See :c:type:`jh7110_isp_sc_buffer` for details of the
+statistics.
+
+The 3A statistics and configuration parameters described here are usually
+consumed and produced by dedicated user space libraries that comprise the
+important tuning tools using software control loop.
+
+JH7110 ISP uAPI data types
+======================
+
+.. kernel-doc:: include/uapi/linux/jh7110-isp.h
diff --git a/MAINTAINERS b/MAINTAINERS
index d5679e5410bd..f4017aece273 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -20838,6 +20838,7 @@ L: linux-media@vger.kernel.org
S: Maintained
F: Documentation/admin-guide/media/starfive_camss.rst
F: Documentation/devicetree/bindings/media/starfive,jh7110-camss.yaml
+F: Documentation/userspace-api/media/v4l/metafmt-starfive-isp.rst
F: drivers/staging/media/starfive/camss
F: include/uapi/linux/jh7110-isp.h
--
2.25.1
next prev parent reply other threads:[~2024-02-05 11:37 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-05 9:04 [PATCH v3 00/13] Add ISP 3A for StarFive Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 01/13] media: starfive: Add JH7110 ISP module definitions Changhuang Liang
2024-02-05 9:04 ` Changhuang Liang [this message]
2024-02-05 9:04 ` [PATCH v3 03/13] media: videodev2.h, v4l2-ioctl: Add StarFive ISP meta buffer format Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 04/13] staging: media: starfive: Add a params sink pad and a scd source pad for ISP Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 05/13] staging: media: starfive: Separate buffer from ISP hardware operation Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 06/13] staging: media: starfive: Separate buffer be a common file Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 07/13] staging: media: starfive: Separate ISP hardware from capture device Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 08/13] staging: media: starfive: Add for StarFive ISP 3A SC Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 09/13] staging: media: starfive: Update ISP initialise config for 3A Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 10/13] staging: media: starfive: Add V4L2_CAP_IO_MC capability Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 11/13] staging: media: starfive: Add ISP params video device Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 12/13] staging: media: starfive: Add ISP parameters hardware configure Changhuang Liang
2024-02-05 9:04 ` [PATCH v3 13/13] admin-guide: media: Update documents for StarFive Camera Subsystem Changhuang Liang
2024-02-12 12:40 ` [PATCH v3 00/13] Add ISP 3A for StarFive Matthias Brugger
2024-02-12 16:33 ` Laurent Pinchart
2024-03-06 2:19 ` 回复: " Changhuang Liang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240205090424.40302-3-changhuang.liang@starfivetech.com \
--to=changhuang.liang@starfivetech.com \
--cc=benjamin.gaignard@collabora.com \
--cc=gregkh@linuxfoundation.org \
--cc=hverkuil-cisco@xs4all.nl \
--cc=jack.zhu@starfivetech.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=matthias.bgg@gmail.com \
--cc=mchehab@kernel.org \
--cc=ming.qian@nxp.com \
--cc=mingjia.zhang@mediatek.com \
--cc=nicolas.dufresne@collabora.com \
--cc=tomi.valkeinen+renesas@ideasonboard.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).