From 0428189c5e231e48fc3f689b2235277f635812a2 Mon Sep 17 00:00:00 2001 From: Zhao Yi Date: Thu, 24 Sep 2020 21:43:37 +0800 Subject: [PATCH] amvdec_h265: unstable pts for multi-instance [3/3] PD#SWPL-32372 Problem: multi-instance h265 decoder didn't get param unstable-pts from vdec->sys_info Solution: Get unstable-pts from vdec->sys_info Verify: AndroidQ Signed-off-by: Zhao Yi Change-Id: I7edd73a66901d195ea0141b2d2c134860ee9b28a --- drivers/frame_provider/decoder/h265/vh265.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/frame_provider/decoder/h265/vh265.c b/drivers/frame_provider/decoder/h265/vh265.c index 9615388..10d1402 100644 --- a/drivers/frame_provider/decoder/h265/vh265.c +++ b/drivers/frame_provider/decoder/h265/vh265.c @@ -11844,6 +11844,7 @@ static int vh265_local_init(struct hevc_state_s *hevc) { int i; int ret = -1; + struct vdec_s *vdec = hw_to_vdec(hevc); #ifdef DEBUG_PTS hevc->pts_missed = 0; @@ -11890,8 +11891,9 @@ static int vh265_local_init(struct hevc_state_s *hevc) hevc->i_only = 0x0; hevc->error_watchdog_count = 0; hevc->sei_present_flag = 0; - pts_unstable = ((unsigned long)hevc->vh265_amstream_dec_info.param - & 0x40) >> 6; + if (vdec->sys_info) + pts_unstable = ((unsigned long)vdec->sys_info->param + & 0x40) >> 6; hevc_print(hevc, 0, "h265:pts_unstable=%d\n", pts_unstable); /* -- 2.20.1