Skip to contentSkip to conversation

media: verisilicon: AV1: Set IDR flag for intra_only frame type

PATCH In review Benjamin Gaignard 2 participants 2 messages Jan 8

Subsystems (3)
lore
Share & tools
lore

Benjamin Gaignard

author maintainer
#0 lore raw

PATCH 1/1 media: verisilicon: AV1: Set IDR flag for intra_only frame type

Intra_only frame could be considered as a key frame so Instantaneous Decoding Refresh (IDR) flag must be set of the both case and not only for key frames.

Fixes 727a400686a2c ("media: verisilicon: Add Rockchip AV1 decoder")
---
 drivers/media/platform/verisilicon/rockchip_vpu981_hw_av1_dec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/platform/verisilicon/rockchip_vpu981_hw_av1_dec.c +1 -1
index 1605cfd55d36..3a8123bbe144 100644
@@ -2047,7 +2047,7 @@ static void rockchip_vpu981_av1_dec_set_parameters(struct hantro_ctx *ctx)
 			 !!(ctrls->frame->quantization.flags
 			    & V4L2_AV1_QUANTIZATION_FLAG_DELTA_Q_PRESENT));
 
-	hantro_reg_write(vpu, &av1_idr_pic_e, !ctrls->frame->frame_type);
+	hantro_reg_write(vpu, &av1_idr_pic_e, IS_INTRA(ctrls->frame->frame_type));
 	hantro_reg_write(vpu, &av1_quant_base_qindex, ctrls->frame->quantization.base_q_idx);
 	hantro_reg_write(vpu, &av1_bit_depth_y_minus8, ctx->bit_depth - 8);
 	hantro_reg_write(vpu, &av1_bit_depth_c_minus8, ctx->bit_depth - 8);
Signature · 1 line
2.43.0
maintainer Reviewed-by on v1 1/1
#1 lore raw

Le jeudi 08 janvier 2026 à 14:29 +0100, Benjamin Gaignard a écrit :

Quoted 7 lines

Intra_only frame could be considered as a key frame so Instantaneous Decoding Refresh (IDR) flag must be set of the both case and not only for key frames.

Fixes 727a400686a2c ("media: verisilicon: Add Rockchip AV1 decoder")
Quoted 17 lines

---
 drivers/media/platform/verisilicon/rockchip_vpu981_hw_av1_dec.c | 2 +-

 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/platform/verisilicon/rockchip_vpu981_hw_av1_dec.c +0 -0
index 1605cfd55d36..3a8123bbe144 100644
@@ -2047,7 +2047,7 @@ static void rockchip_vpu981_av1_dec_set_parameters(struct hantro_ctx *ctx)

  !!(ctrls->frame->quantization.flags
      & V4L2_AV1_QUANTIZATION_FLAG_DELTA_Q_PRESENT));

drivers/media/platform/verisilicon/rockchip_vpu981_hw_av1_dec.c +1 -1
-	hantro_reg_write(vpu, &av1_idr_pic_e, !ctrls->frame->frame_type);
+	hantro_reg_write(vpu, &av1_idr_pic_e, IS_INTRA(ctrls->frame->frame_type));

  hantro_reg_write(vpu, &av1_quant_base_qindex, ctrls->frame->quantization.base_q_idx); hantro_reg_write(vpu, &av1_bit_depth_y_minus8, ctx->bit_depth - 8); hantro_reg_write(vpu, &av1_bit_depth_c_minus8, ctx->bit_depth - 8);