* [PATCH] media: rkisp1: Add NV16M and NV61M to output formats
@ 2022-07-13 7:24 Paul Elder
2022-07-13 20:33 ` Laurent Pinchart
0 siblings, 1 reply; 2+ messages in thread
From: Paul Elder @ 2022-07-13 7:24 UTC (permalink / raw)
To: linux-media
Cc: Paul Elder, Dafna Hirschfeld, Mauro Carvalho Chehab,
Heiko Stuebner, linux-rockchip, linux-arm-kernel, linux-kernel,
laurent.pinchart
Add support for NV16M and NV61M as output formats. As NV16, NV61, NV12M
and NV21M are already supported, the infrastructure is already in place
to support NV16M and NV61M, so it is sufficient to simply add relevant
entries to the list of output formats.
Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
---
.../platform/rockchip/rkisp1/rkisp1-capture.c | 22 +++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c b/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c
index fee2aaacb26b..43547ab55fab 100644
--- a/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c
+++ b/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c
@@ -110,6 +110,16 @@ static const struct rkisp1_capture_fmt_cfg rkisp1_mp_fmts[] = {
.uv_swap = 1,
.write_format = RKISP1_MI_CTRL_MP_WRITE_YUV_SPLA,
.mbus = MEDIA_BUS_FMT_YUYV8_2X8,
+ }, {
+ .fourcc = V4L2_PIX_FMT_NV16M,
+ .uv_swap = 0,
+ .write_format = RKISP1_MI_CTRL_MP_WRITE_YUV_SPLA,
+ .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
+ }, {
+ .fourcc = V4L2_PIX_FMT_NV61M,
+ .uv_swap = 1,
+ .write_format = RKISP1_MI_CTRL_MP_WRITE_YUV_SPLA,
+ .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
}, {
.fourcc = V4L2_PIX_FMT_YVU422M,
.uv_swap = 1,
@@ -237,6 +247,18 @@ static const struct rkisp1_capture_fmt_cfg rkisp1_sp_fmts[] = {
.write_format = RKISP1_MI_CTRL_SP_WRITE_SPLA,
.output_format = RKISP1_MI_CTRL_SP_OUTPUT_YUV422,
.mbus = MEDIA_BUS_FMT_YUYV8_2X8,
+ }, {
+ .fourcc = V4L2_PIX_FMT_NV16M,
+ .uv_swap = 0,
+ .write_format = RKISP1_MI_CTRL_SP_WRITE_SPLA,
+ .output_format = RKISP1_MI_CTRL_SP_OUTPUT_YUV422,
+ .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
+ }, {
+ .fourcc = V4L2_PIX_FMT_NV61M,
+ .uv_swap = 1,
+ .write_format = RKISP1_MI_CTRL_SP_WRITE_SPLA,
+ .output_format = RKISP1_MI_CTRL_SP_OUTPUT_YUV422,
+ .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
}, {
.fourcc = V4L2_PIX_FMT_YVU422M,
.uv_swap = 1,
--
2.30.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] media: rkisp1: Add NV16M and NV61M to output formats
2022-07-13 7:24 [PATCH] media: rkisp1: Add NV16M and NV61M to output formats Paul Elder
@ 2022-07-13 20:33 ` Laurent Pinchart
0 siblings, 0 replies; 2+ messages in thread
From: Laurent Pinchart @ 2022-07-13 20:33 UTC (permalink / raw)
To: Paul Elder
Cc: linux-media, Dafna Hirschfeld, Mauro Carvalho Chehab,
Heiko Stuebner, linux-rockchip, linux-arm-kernel, linux-kernel
Hi Paul,
Thank you for the patch.
On Wed, Jul 13, 2022 at 04:24:58PM +0900, Paul Elder wrote:
> Add support for NV16M and NV61M as output formats. As NV16, NV61, NV12M
> and NV21M are already supported, the infrastructure is already in place
> to support NV16M and NV61M, so it is sufficient to simply add relevant
> entries to the list of output formats.
>
> Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
> .../platform/rockchip/rkisp1/rkisp1-capture.c | 22 +++++++++++++++++++
> 1 file changed, 22 insertions(+)
>
> diff --git a/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c b/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c
> index fee2aaacb26b..43547ab55fab 100644
> --- a/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c
> +++ b/drivers/media/platform/rockchip/rkisp1/rkisp1-capture.c
> @@ -110,6 +110,16 @@ static const struct rkisp1_capture_fmt_cfg rkisp1_mp_fmts[] = {
> .uv_swap = 1,
> .write_format = RKISP1_MI_CTRL_MP_WRITE_YUV_SPLA,
> .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
> + }, {
> + .fourcc = V4L2_PIX_FMT_NV16M,
> + .uv_swap = 0,
> + .write_format = RKISP1_MI_CTRL_MP_WRITE_YUV_SPLA,
> + .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
> + }, {
> + .fourcc = V4L2_PIX_FMT_NV61M,
> + .uv_swap = 1,
> + .write_format = RKISP1_MI_CTRL_MP_WRITE_YUV_SPLA,
> + .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
> }, {
> .fourcc = V4L2_PIX_FMT_YVU422M,
> .uv_swap = 1,
> @@ -237,6 +247,18 @@ static const struct rkisp1_capture_fmt_cfg rkisp1_sp_fmts[] = {
> .write_format = RKISP1_MI_CTRL_SP_WRITE_SPLA,
> .output_format = RKISP1_MI_CTRL_SP_OUTPUT_YUV422,
> .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
> + }, {
> + .fourcc = V4L2_PIX_FMT_NV16M,
> + .uv_swap = 0,
> + .write_format = RKISP1_MI_CTRL_SP_WRITE_SPLA,
> + .output_format = RKISP1_MI_CTRL_SP_OUTPUT_YUV422,
> + .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
> + }, {
> + .fourcc = V4L2_PIX_FMT_NV61M,
> + .uv_swap = 1,
> + .write_format = RKISP1_MI_CTRL_SP_WRITE_SPLA,
> + .output_format = RKISP1_MI_CTRL_SP_OUTPUT_YUV422,
> + .mbus = MEDIA_BUS_FMT_YUYV8_2X8,
> }, {
> .fourcc = V4L2_PIX_FMT_YVU422M,
> .uv_swap = 1,
--
Regards,
Laurent Pinchart
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-07-13 20:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-13 7:24 [PATCH] media: rkisp1: Add NV16M and NV61M to output formats Paul Elder
2022-07-13 20:33 ` Laurent Pinchart
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox