]> git.baikalelectronics.ru Git - kernel.git/commitdiff
media: hantro: Stop using H.264 parameter pic_num
authorNicolas Dufresne <nicolas.dufresne@collabora.com>
Fri, 13 May 2022 20:29:19 +0000 (22:29 +0200)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Tue, 17 May 2022 08:09:10 +0000 (10:09 +0200)
The hardware expects FrameNumWrap or long_term_frame_idx. Picture
numbers are per field, and are mostly used during the memory
management process, which is done in userland. This fixes two
ITU conformance tests:

  - MR6_BT_B
  - MR8_BT_B

Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Reviewed-by: Sebastian Fricke <sebastian.fricke@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/staging/media/hantro/hantro_h264.c

index 0b4d2491be3b831783cdaa37f9297c3f3cdb88f9..228629fb3cdf9b4d5716fc4ed831eae618e0e6b6 100644 (file)
@@ -354,8 +354,6 @@ u16 hantro_h264_get_ref_nbr(struct hantro_ctx *ctx, unsigned int dpb_idx)
 
        if (!(dpb->flags & V4L2_H264_DPB_ENTRY_FLAG_ACTIVE))
                return 0;
-       if (dpb->flags & V4L2_H264_DPB_ENTRY_FLAG_LONG_TERM)
-               return dpb->pic_num;
        return dpb->frame_num;
 }