]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
media: verisilicon: Fix IMX8 native pixel-format step values
authorBenjamin Gaignard <benjamin.gaignard@collabora.com>
Thu, 12 Dec 2024 15:43:34 +0000 (15:43 +0000)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Fri, 13 Dec 2024 19:48:25 +0000 (19:48 +0000)
The Hantro decoder non post-processed pixel-format steps are different
from the post-processed ones. Fix the steps according to the hardware
limitations. Since reference frame pixel-format issues have been fixed,
it is possible to use V4L2_PIX_FMT_NV15_4L4 rather V4L2_PIX_FMT_P010_4L4
for 10bit streams.

Fluster VP9 score goes up to 207/305.
HEVC score is still 141/147.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@collabora.com>
Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Signed-off-by: Sebastian Fricke <sebastian.fricke@collabora.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/platform/verisilicon/imx8m_vpu_hw.c

index f850d8bddef6bc5426e96aa49803f7de37f83908..35799da534edcaf9446f3fd46b0350e6f0589eb0 100644 (file)
@@ -187,23 +187,23 @@ static const struct hantro_fmt imx8m_vpu_g2_dec_fmts[] = {
                .frmsize = {
                        .min_width = FMT_MIN_WIDTH,
                        .max_width = FMT_UHD_WIDTH,
-                       .step_width = TILE_MB_DIM,
+                       .step_width = 8,
                        .min_height = FMT_MIN_HEIGHT,
                        .max_height = FMT_UHD_HEIGHT,
-                       .step_height = TILE_MB_DIM,
+                       .step_height = 32,
                },
        },
        {
-               .fourcc = V4L2_PIX_FMT_P010_4L4,
+               .fourcc = V4L2_PIX_FMT_NV15_4L4,
                .codec_mode = HANTRO_MODE_NONE,
                .match_depth = true,
                .frmsize = {
                        .min_width = FMT_MIN_WIDTH,
                        .max_width = FMT_UHD_WIDTH,
-                       .step_width = TILE_MB_DIM,
+                       .step_width = 8,
                        .min_height = FMT_MIN_HEIGHT,
                        .max_height = FMT_UHD_HEIGHT,
-                       .step_height = TILE_MB_DIM,
+                       .step_height = 32,
                },
        },
        {