From: Stefan Wahren <wahrenst@gmx.net>
To: Umang Jain <umang.jain@ideasonboard.com>,
linux-media@vger.kernel.org, kernel-list@raspberrypi.com,
linux-kernel@vger.kernel.org,
linux-rpi-kernel@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-staging@lists.linux.dev
Cc: Dave Stevenson <dave.stevenson@raspberrypi.com>,
Kieran Bingham <kieran.bingham@ideasonboard.com>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
"Ricardo B . Marliere" <ricardo@marliere.net>,
Dan Carpenter <error27@gmail.com>,
Naushir Patuck <naush@raspberrypi.com>
Subject: Re: [PATCH v2 07/15] media: uapi: v4l2-core: Add ISP statistics output V4L2 fourcc type
Date: Sat, 18 Nov 2023 14:11:06 +0100 [thread overview]
Message-ID: <6e06ee01-4ccb-4e34-bb6c-1d5fb8ab9e3c@gmx.net> (raw)
In-Reply-To: <20231109210309.638594-8-umang.jain@ideasonboard.com>
Hi Umang,
Am 09.11.23 um 22:02 schrieb Umang Jain:
> From: Naushir Patuck <naush@raspberrypi.com>
>
> Add V4L2_META_FMT_BCM2835_ISP_STATS V4L2 format type.
>
> This new format will be used by the bcm2835-isp device to return
> out ISP statistics for 3A.
>
> Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
> Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>
> ---
> .../userspace-api/media/v4l/meta-formats.rst | 1 +
> .../v4l/pixfmt-meta-bcm2835-isp-stats.rst | 32 +++++++++++++++++++
> drivers/media/v4l2-core/v4l2-ioctl.c | 1 +
> include/uapi/linux/videodev2.h | 1 +
> 4 files changed, 35 insertions(+)
> create mode 100644 Documentation/userspace-api/media/v4l/pixfmt-meta-bcm2835-isp-stats.rst
>
> diff --git a/Documentation/userspace-api/media/v4l/meta-formats.rst b/Documentation/userspace-api/media/v4l/meta-formats.rst
> index 919f595576b9..534542f235bc 100644
> --- a/Documentation/userspace-api/media/v4l/meta-formats.rst
> +++ b/Documentation/userspace-api/media/v4l/meta-formats.rst
> @@ -12,6 +12,7 @@ These formats are used for the :ref:`metadata` interface only.
> .. toctree::
> :maxdepth: 1
>
> + pixfmt-meta-bcm2835-isp-stats
> metafmt-d4xx
> metafmt-intel-ipu3
> metafmt-rkisp1
> diff --git a/Documentation/userspace-api/media/v4l/pixfmt-meta-bcm2835-isp-stats.rst b/Documentation/userspace-api/media/v4l/pixfmt-meta-bcm2835-isp-stats.rst
> new file mode 100644
> index 000000000000..2219235e0ecb
> --- /dev/null
> +++ b/Documentation/userspace-api/media/v4l/pixfmt-meta-bcm2835-isp-stats.rst
> @@ -0,0 +1,32 @@
> +.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
> +.. _v4l2-meta-fmt-bcm2835-isp-stats:
> +
> ++*****************************************
> +V4L2_META_FMT_BCM2835_ISP_STATS ('BSTA')
> +*****************************************
> +
> +BCM2835 ISP Statistics
> +
> +Description
> +===========
> +
> +The BCM2835 ISP hardware calculate image statistics for an input Bayer frame.
> +These statistics are obtained from the "bcm2835-isp0-capture3" device node
> +using the :c:type:`v4l2_meta_format` interface. They are formatted as described
> +by the :c:type:`bcm2835_isp_stats` structure below.
> +
> +.. code-block:: c
> +
> + #define DEFAULT_AWB_REGIONS_X 16
> + #define DEFAULT_AWB_REGIONS_Y 12
> +
> + #define NUM_HISTOGRAMS 2
> + #define NUM_HISTOGRAM_BINS 128
> + #define AWB_REGIONS (DEFAULT_AWB_REGIONS_X * DEFAULT_AWB_REGIONS_Y)
> + #define FLOATING_REGIONS 16
> + #define AGC_REGIONS 16
> + #define FOCUS_REGIONS 12
> +
> +.. kernel-doc:: include/uapi/linux/bcm2835-isp.h
> + :functions: bcm2835_isp_stats_hist bcm2835_isp_stats_region
> + bcm2835_isp_stats_focus bcm2835_isp_stats
> diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c
> index 7f29886568b8..6f0f0f6526c9 100644
> --- a/drivers/media/v4l2-core/v4l2-ioctl.c
> +++ b/drivers/media/v4l2-core/v4l2-ioctl.c
> @@ -1463,6 +1463,7 @@ static void v4l_fill_fmtdesc(struct v4l2_fmtdesc *fmt)
> case V4L2_META_FMT_GENERIC_CSI2_20: descr = "8b Generic Meta, 20b CSI-2"; break;
> case V4L2_META_FMT_GENERIC_CSI2_24: descr = "8b Generic Meta, 24b CSI-2"; break;
> case V4L2_META_FMT_GENERIC_CSI2_2_24: descr = "2x8b Generic Meta, 24b CSI-2"; break;
> + case V4L2_META_FMT_BCM2835_ISP_STATS: descr = "BCM2835 ISP Image Statistics"; break;
tab instead of space?
>
> default:
> /* Compressed formats */
> diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h
> index 85b60199c618..eddaea8598db 100644
> --- a/include/uapi/linux/videodev2.h
> +++ b/include/uapi/linux/videodev2.h
> @@ -836,6 +836,7 @@ struct v4l2_pix_format {
> #define V4L2_META_FMT_UVC v4l2_fourcc('U', 'V', 'C', 'H') /* UVC Payload Header metadata */
> #define V4L2_META_FMT_D4XX v4l2_fourcc('D', '4', 'X', 'X') /* D4XX Payload Header metadata */
> #define V4L2_META_FMT_VIVID v4l2_fourcc('V', 'I', 'V', 'D') /* Vivid Metadata */
> +#define V4L2_META_FMT_BCM2835_ISP_STATS v4l2_fourcc('B', 'S', 'T', 'A') /* BCM2835 ISP image statistics output */
Shouldn't this go to the vendor specific ones?
>
> /* Vendor specific - used for RK_ISP1 camera sub-system */
> #define V4L2_META_FMT_RK_ISP1_PARAMS v4l2_fourcc('R', 'K', '1', 'P') /* Rockchip ISP1 3A Parameters */
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2023-11-18 13:11 UTC|newest]
Thread overview: 45+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-09 21:02 [PATCH v2 00/15] staging: vc04_services: bcm2835-isp support Umang Jain
2023-11-09 21:02 ` [PATCH v2 01/15] staging: vc04_services: Add new vc-sm-cma driver Umang Jain
2023-11-13 17:56 ` Stefan Wahren
2023-11-15 19:56 ` Laurent Pinchart
2023-11-15 20:48 ` Stefan Wahren
2023-11-20 9:52 ` Dan Carpenter
2023-11-09 21:02 ` [PATCH v2 02/15] staging: vc04_services: vchiq_arm: Register vcsm-cma driver Umang Jain
2023-11-14 19:32 ` Stefan Wahren
2023-11-09 21:02 ` [PATCH v2 03/15] media: videobuf2: Allow exporting of a struct dmabuf Umang Jain
2023-11-14 19:41 ` Stefan Wahren
2023-11-15 19:31 ` Laurent Pinchart
2023-11-15 21:00 ` Stefan Wahren
2023-11-09 21:02 ` [PATCH v2 04/15] staging: mmal-vchiq: Add support for event callbacks Umang Jain
2023-11-20 10:00 ` Dan Carpenter
2023-11-09 21:02 ` [PATCH v2 05/15] staging: mmal-vchiq: Use vc-sm-cma to support zero copy Umang Jain
2023-11-15 19:03 ` Stefan Wahren
2023-11-15 19:27 ` Laurent Pinchart
2023-11-09 21:02 ` [PATCH v2 06/15] staging: mmal_vchiq: Add image formats to be used by bcm2835-isp Umang Jain
2023-11-09 21:02 ` [PATCH v2 07/15] media: uapi: v4l2-core: Add ISP statistics output V4L2 fourcc type Umang Jain
2023-11-18 13:11 ` Stefan Wahren [this message]
2023-11-09 21:03 ` [PATCH v2 08/15] uapi: bcm2835-isp: Add bcm2835-isp uapi header file Umang Jain
2023-11-09 21:03 ` [PATCH v2 09/15] staging: vc04_services: Add helpers for vchiq driver data Umang Jain
2023-11-18 14:43 ` Stefan Wahren
2023-11-09 21:03 ` [PATCH v2 10/15] staging: vc04_services: bcm2835-isp: Add a more complex ISP processing component Umang Jain
2023-11-13 14:07 ` [PATCH] fixup! " Umang Jain
2023-11-13 15:25 ` Stefan Wahren
2023-11-23 12:56 ` Greg KH
2023-11-23 13:53 ` Laurent Pinchart
2023-11-18 14:53 ` [PATCH v2 10/15] " Stefan Wahren
2023-11-18 18:56 ` Laurent Pinchart
2023-11-19 12:02 ` Stefan Wahren
2023-11-20 10:33 ` Dan Carpenter
2023-11-09 21:03 ` [PATCH v2 11/15] vc04_services: bcm2835-isp: Allow formats with different colour spaces Umang Jain
2023-11-09 21:03 ` [PATCH v2 12/15] vc04_services: bcm2835-isp: Permit all sRGB colour spaces on ISP outputs Umang Jain
2023-11-09 21:03 ` [PATCH v2 13/15] staging: vc04_services: bcm2835_isp: Allow multiple users Umang Jain
2023-11-09 21:03 ` [PATCH v2 14/15] docs: admin-guide: media: bcm2835-isp: Add documentation for bcm2835-isp Umang Jain
2023-11-09 21:03 ` [PATCH v2 15/15] staging: vc04_services: vchiq: Register bcm2835-isp Umang Jain
2023-11-10 10:32 ` [PATCH v2 00/15] staging: vc04_services: bcm2835-isp support Stefan Wahren
2023-11-13 13:38 ` Umang Jain
2023-11-13 15:09 ` Stefan Wahren
2023-11-15 19:59 ` Laurent Pinchart
2023-11-15 20:57 ` Stefan Wahren
2023-11-16 0:50 ` Laurent Pinchart
2023-11-16 10:54 ` Ivan T. Ivanov
2023-11-16 10:57 ` Peter Robinson
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=6e06ee01-4ccb-4e34-bb6c-1d5fb8ab9e3c@gmx.net \
--to=wahrenst@gmx.net \
--cc=dave.stevenson@raspberrypi.com \
--cc=error27@gmail.com \
--cc=kernel-list@raspberrypi.com \
--cc=kieran.bingham@ideasonboard.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=linux-staging@lists.linux.dev \
--cc=naush@raspberrypi.com \
--cc=ricardo@marliere.net \
--cc=umang.jain@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