vh264: fix channel switching system hangup issue in vh264 remove [1/1]

PD#SWPL-6377

Problem:
hw bus dead lock in h264 remove.

Solution:
wait for decoder hw stopped completely before h264 remove

Verify:
X301

Change-Id: Ia3555e687ecfe452948922d3e221c0fae0ad499d
Signed-off-by: Hui Zhang <hui.zhang@amlogic.com>
This commit is contained in:
Hui Zhang
2019-04-03 10:12:56 +08:00
committed by Dongjin Kim
parent e61469d472
commit 97a997d366

View File

@@ -3712,11 +3712,10 @@ static int amvdec_h264_remove(struct platform_device *pdev)
cancel_work_sync(&notify_work);
cancel_work_sync(&set_clk_work);
cancel_work_sync(&userdata_push_work);
mutex_lock(&vh264_mutex);
vh264_stop(MODE_FULL);
wait_vh264_search_done();
mutex_lock(&vh264_mutex);
vdec_source_changed(VFORMAT_H264, 0, 0, 0);
#ifdef DUMP_USER_DATA
vh264_dump_userdata();
#endif