[PATCH 2/2] media: rkvdec: vdpu381: Compress the co-located motion vectors of HEVC
Arun Iyengar via B4 Relay
devnull+aiyengar1990.gmail.com at kernel.org
Mon Nov 9 23:18:31 PST 2026
From: Arun Iyengar <aiyengar1990 at gmail.com>
Like for H.264, store the co-located motion vectors of HEVC frames
compressed, which the vendor code (MPP, hal_h265d_vdpu34x.c) always
does. The previous commit reserved space for the compressed layout.
On RK3588, a 24 Mbit/s 3840x2160 HEVC stream (240 frames, x265
ultrafast) decodes at 104.6 fps instead of 98.6-102.8 fps, and the
decoded frames are identical.
Signed-off-by: Arun Iyengar <aiyengar1990 at gmail.com>
---
drivers/media/platform/rockchip/rkvdec/rkvdec-vdpu381-hevc.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/media/platform/rockchip/rkvdec/rkvdec-vdpu381-hevc.c b/drivers/media/platform/rockchip/rkvdec/rkvdec-vdpu381-hevc.c
index e1936e87f45b..2473c176b319 100644
--- a/drivers/media/platform/rockchip/rkvdec/rkvdec-vdpu381-hevc.c
+++ b/drivers/media/platform/rockchip/rkvdec/rkvdec-vdpu381-hevc.c
@@ -404,6 +404,9 @@ static void config_registers(struct rkvdec_ctx *ctx,
/* Set HEVC mode */
regs->common.reg009_dec_mode.dec_mode = VDPU381_MODE_HEVC;
+ /* Store the co-located motion vectors compressed, as for H.264 */
+ regs->common.reg012_secondary_en.colmv_compress_en = 1;
+
/* Set config */
regs->common.reg011_important_en.buf_empty_en = 1;
regs->common.reg011_important_en.dec_clkgate_e = 1;
--
2.55.0
More information about the Linux-rockchip
mailing list