summaryrefslogtreecommitdiff
authorYixin Peng <yixin.peng@amlogic.com>2020-03-10 02:05:33 (GMT)
committer Shen Liu <shen.liu@amlogic.com>2020-06-01 08:30:20 (GMT)
commit925e834e12df4fe864bb8f923037e451b596b38e (patch)
tree8a1e9d791fae06b25b79c0338a2f97e7473cab1f
parent02f4d52052268fbf634584726639fc51fdb3cb48 (diff)
downloadmedia_modules-925e834e12df4fe864bb8f923037e451b596b38e.zip
media_modules-925e834e12df4fe864bb8f923037e451b596b38e.tar.gz
media_modules-925e834e12df4fe864bb8f923037e451b596b38e.tar.bz2
media_module: fixed playback stuck issue [1/1]
PD#SWPL-21645 Problem: When input data insufficient and decoder does not work properly, timeout was not in effect. Solution: Modify the logic to make the timer work properly. Verify: U212 Change-Id: I49a4c3571e7611bd5c953c2d5349786a3e4582bd Signed-off-by: Yixin Peng <yixin.peng@amlogic.com>
Diffstat
-rw-r--r--drivers/frame_provider/decoder/h264_multi/vmh264.c7
-rw-r--r--drivers/frame_provider/decoder/h265/vh265.c4
-rw-r--r--drivers/frame_provider/decoder/mpeg4/vmpeg4_multi.c2
3 files changed, 3 insertions, 10 deletions
diff --git a/drivers/frame_provider/decoder/h264_multi/vmh264.c b/drivers/frame_provider/decoder/h264_multi/vmh264.c
index bfffff7..3b13f79 100644
--- a/drivers/frame_provider/decoder/h264_multi/vmh264.c
+++ b/drivers/frame_provider/decoder/h264_multi/vmh264.c
@@ -6090,11 +6090,8 @@ static void check_timer_func(unsigned long arg)
rval = 0;
radr = 0;
}
- if (h264_debug_flag & 0x800000)
- pr_info("hw->start_process_time %ld timeout_val %d timeout_count %d mby_mbx 0x%x dpb status 0x%x\n",hw->start_process_time, timeout_val, hw->decode_timeout_count,READ_VREG(MBY_MBX),READ_VREG(DPB_STATUS_REG));
- if ((input_frame_based(vdec) ||
- (READ_VREG(VLD_MEM_VIFIFO_LEVEL) > 0xb0)) &&
- ((h264_debug_flag & DISABLE_ERROR_HANDLE) == 0) &&
+
+ if (((h264_debug_flag & DISABLE_ERROR_HANDLE) == 0) &&
(timeout_val > 0) &&
(hw->start_process_time > 0) &&
((1000 * (jiffies - hw->start_process_time) / HZ)
diff --git a/drivers/frame_provider/decoder/h265/vh265.c b/drivers/frame_provider/decoder/h265/vh265.c
index a1c345f..c868d9f 100644
--- a/drivers/frame_provider/decoder/h265/vh265.c
+++ b/drivers/frame_provider/decoder/h265/vh265.c
@@ -9359,9 +9359,7 @@ static void vh265_check_timer_func(unsigned long arg)
}
if (hevc->m_ins_flag) {
- if ((input_frame_based(hw_to_vdec(hevc)) ||
- (READ_VREG(HEVC_STREAM_LEVEL) > 0xb0)) &&
- ((get_dbg_flag(hevc) &
+ if (((get_dbg_flag(hevc) &
H265_DEBUG_DIS_LOC_ERROR_PROC) == 0) &&
(decode_timeout_val > 0) &&
(hevc->start_process_time > 0) &&
diff --git a/drivers/frame_provider/decoder/mpeg4/vmpeg4_multi.c b/drivers/frame_provider/decoder/mpeg4/vmpeg4_multi.c
index 8d512d5..6bd028e 100644
--- a/drivers/frame_provider/decoder/mpeg4/vmpeg4_multi.c
+++ b/drivers/frame_provider/decoder/mpeg4/vmpeg4_multi.c
@@ -1554,8 +1554,6 @@ static void check_timer_func(unsigned long arg)
}
if (((debug_enable & PRINT_FLAG_TIMEOUT_STATUS) == 0) &&
- (vdec_frame_based(vdec) ||
- ((u32)READ_VREG(VLD_MEM_VIFIFO_LEVEL) > 0x100)) &&
(timeout_val > 0) &&
(hw->start_process_time > 0) &&
((1000 * (jiffies - hw->start_process_time) / HZ)