From: Philipp Zabel <p.zabel@pengutronix.de>
To: Fabio Estevam <festevam@gmail.com>, hverkuil-cisco@xs4all.nl
Cc: linux-media@vger.kernel.org, nicolas.dufresne@collabora.com,
ezequiel@collabora.com, kernel@iktek.de, stable@vger.kernel.org,
Fabio Estevam <festevam@denx.de>
Subject: Re: [PATCH v3 2/2] media: coda: Add more H264 levels for CODA960
Date: Fri, 11 Mar 2022 10:35:24 +0100 [thread overview]
Message-ID: <e44d9964784fe5b00697373531ab8fbad5bdf990.camel@pengutronix.de> (raw)
In-Reply-To: <20220309173636.1879419-2-festevam@gmail.com>
On Mi, 2022-03-09 at 14:36 -0300, Fabio Estevam wrote:
> From: Nicolas Dufresne <nicolas.dufresne@collabora.com>
>
> Add H264 level 1.0, 4.1, 4.2 to the list of supported formats.
> While the hardware does not fully support these levels, it does
> support
> most of them. The constraints on frame size and pixel formats already
> cover the limitation.
>
> This fixes negotiation of level on GStreamer 1.17.1.
>
> Cc: stable@vger.kernel.org
> Fixes: 42a68012e67c2 ("media: coda: add read-only h.264 decoder
> profile/level controls")
> Suggested-by: Philipp Zabel <p.zabel@pengutronix.de>
> Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
> Signed-off-by: Ezequiel Garcia <ezequiel@collabora.com>
> Signed-off-by: Fabio Estevam <festevam@denx.de>
> ---
> Changes since v2:
> - Remove 5.0 level and use Phillip's suggestion to get the correct
> levels
> being reported by v4l2h264enc:
>
> h264_level 0x00990a67 (menu) : min=0 max=13
> default=11 value=11
> 0: 1
> 5: 2
> 8: 3
> 9: 3.1
> 10: 3.2
> 11: 4
> 12: 4.1
> 13: 4.2
>
> drivers/media/platform/coda/coda-common.c | 9 ++++++---
> 1 file changed, 6 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/media/platform/coda/coda-common.c
> b/drivers/media/platform/coda/coda-common.c
> index 280d77f1567c..da8bc1f87ba0 100644
> --- a/drivers/media/platform/coda/coda-common.c
> +++ b/drivers/media/platform/coda/coda-common.c
> @@ -2349,12 +2349,15 @@ static void coda_encode_ctrls(struct coda_ctx
> *ctx)
> if (ctx->dev->devtype->product == CODA_960) {
> v4l2_ctrl_new_std_menu(&ctx->ctrls, &coda_ctrl_ops,
> V4L2_CID_MPEG_VIDEO_H264_LEVEL,
> - V4L2_MPEG_VIDEO_H264_LEVEL_4_0,
> - ~((1 << V4L2_MPEG_VIDEO_H264_LEVEL_2_0) |
> + V4L2_MPEG_VIDEO_H264_LEVEL_4_2,
> + ~((1 << V4L2_MPEG_VIDEO_H264_LEVEL_1_0) |
> + (1 << V4L2_MPEG_VIDEO_H264_LEVEL_2_0) |
> (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_0) |
> (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_1) |
> (1 << V4L2_MPEG_VIDEO_H264_LEVEL_3_2) |
> - (1 << V4L2_MPEG_VIDEO_H264_LEVEL_4_0)),
> + (1 << V4L2_MPEG_VIDEO_H264_LEVEL_4_0) |
> + (1 << V4L2_MPEG_VIDEO_H264_LEVEL_4_1) |
> + (1 << V4L2_MPEG_VIDEO_H264_LEVEL_4_2)),
> V4L2_MPEG_VIDEO_H264_LEVEL_4_0);
> }
> v4l2_ctrl_new_std(&ctx->ctrls, &coda_ctrl_ops,
Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>
regards
Philipp
prev parent reply other threads:[~2022-03-11 9:35 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-09 17:36 [PATCH v3 1/2] media: coda: Fix reported H264 profile Fabio Estevam
2022-03-09 17:36 ` [PATCH v3 2/2] media: coda: Add more H264 levels for CODA960 Fabio Estevam
2022-03-11 9:35 ` Philipp Zabel [this message]
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=e44d9964784fe5b00697373531ab8fbad5bdf990.camel@pengutronix.de \
--to=p.zabel@pengutronix.de \
--cc=ezequiel@collabora.com \
--cc=festevam@denx.de \
--cc=festevam@gmail.com \
--cc=hverkuil-cisco@xs4all.nl \
--cc=kernel@iktek.de \
--cc=linux-media@vger.kernel.org \
--cc=nicolas.dufresne@collabora.com \
--cc=stable@vger.kernel.org \
/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 NNTP newsgroup(s).