From: Nicolas Dufresne <nicolas.dufresne@collabora.com>
To: aiyengar1990@gmail.com,
Benjamin Gaignard <benjamin.gaignard@collabora.com>,
Philipp Zabel <p.zabel@pengutronix.de>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Andrzej Pietrasiewicz <andrzej.p@collabora.com>,
Hans Verkuil <hverkuil@kernel.org>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
Cc: linux-media@vger.kernel.org, linux-rockchip@lists.infradead.org,
linux-kernel@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH v3 1/5] media: verisilicon: Size the VP8 segment map for the largest frame
Date: Mon, 30 Nov 2026 17:39:43 -0500 [thread overview]
Message-ID: <5b0d87ab643bbff722b6dc4e02eca92479c4fecd.camel@collabora.com> (raw)
In-Reply-To: <20261130-hantro-fixes-v3-1-5324f239c22e@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1680 bytes --]
Le lundi 30 novembre 2026 à 21:53 +0000, Arun Iyengar via B4 Relay a écrit :
> From: Arun Iyengar <aiyengar1990@gmail.com>
>
> The segment map is sized at STREAMON, but the CAPTURE format can grow
> while streaming and overrun it. Size it for the largest frame, as VP9
> does.
Its shouldn't really grow while streaming, I wonder if some VP9 feature didn't
leak into VP8 and if we shouldn't simply protect VP8 against that, instead of
supported something that will break anyway, and just use more memory for no good
reason.
Nicolas
>
> Fixes: bbd267daf4fc ("media: verisilicon: vp9: Allow to change resolution while streaming")
> Cc: stable@vger.kernel.org
> Reviewed-by: Benjamin Gaignard <benjamin.gaignard@collabora.com>
> Signed-off-by: Arun Iyengar <aiyengar1990@gmail.com>
> ---
> drivers/media/platform/verisilicon/hantro_vp8.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/media/platform/verisilicon/hantro_vp8.c b/drivers/media/platform/verisilicon/hantro_vp8.c
> index 65648c017e76..19a89722bf05 100644
> --- a/drivers/media/platform/verisilicon/hantro_vp8.c
> +++ b/drivers/media/platform/verisilicon/hantro_vp8.c
> @@ -150,8 +150,8 @@ int hantro_vp8_dec_init(struct hantro_ctx *ctx)
> int ret;
>
> /* segment map table size calculation */
> - mb_width = DIV_ROUND_UP(ctx->dst_fmt.width, 16);
> - mb_height = DIV_ROUND_UP(ctx->dst_fmt.height, 16);
> + mb_width = DIV_ROUND_UP(ctx->vpu_src_fmt->frmsize.max_width, 16);
> + mb_height = DIV_ROUND_UP(ctx->vpu_src_fmt->frmsize.max_height, 16);
> segment_map_size = round_up(DIV_ROUND_UP(mb_width * mb_height, 4), 64);
>
> /*
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2026-11-30 22:39 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-30 21:53 [PATCH v3 0/5] media: verisilicon: Keep the CAPTURE format in line with the decoder Arun Iyengar via B4 Relay
2026-11-30 21:53 ` [PATCH v3 1/5] media: verisilicon: Size the VP8 segment map for the largest frame Arun Iyengar via B4 Relay
2026-11-30 22:39 ` Nicolas Dufresne [this message]
2026-11-30 21:53 ` [PATCH v3 2/5] media: verisilicon: Set need_postproc before resetting the CAPTURE format Arun Iyengar via B4 Relay
2026-11-30 21:53 ` [PATCH v3 3/5] media: verisilicon: Size reference frames by the stream bit depth Arun Iyengar via B4 Relay
2026-11-30 21:53 ` [PATCH v3 4/5] media: verisilicon: Keep the CAPTURE format at the stream's " Arun Iyengar via B4 Relay
2026-11-30 21:53 ` [PATCH v3 5/5] media: verisilicon: Set the bit depth again when its control is rewritten Arun Iyengar via B4 Relay
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=5b0d87ab643bbff722b6dc4e02eca92479c4fecd.camel@collabora.com \
--to=nicolas.dufresne@collabora.com \
--cc=aiyengar1990@gmail.com \
--cc=andrzej.p@collabora.com \
--cc=benjamin.gaignard@collabora.com \
--cc=ezequiel@vanguardiasur.com.ar \
--cc=hverkuil@kernel.org \
--cc=jernej.skrabec@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=mchehab@kernel.org \
--cc=p.zabel@pengutronix.de \
--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
all inboxes | Powered by JetHome®