v4l2: resolve a busy loop [1/1]
authorSong Zhao <song.zhao@amlogic.com>
Tue, 22 Dec 2020 00:54:00 +0000 (16:54 -0800)
committerSong Zhao <song.zhao@amlogic.com>
Tue, 22 Dec 2020 06:28:10 +0000 (22:28 -0800)
commit4968a7411444b3e5a3efb1d9f5b856e6d0f6cc37
tree84856c046f18de8b6c5bafabc61c39991a7d33d6
parent550dc42835e20600f06fbbf0700893b40eeceda1
v4l2: resolve a busy loop [1/1]

PD#SWPL-38455

Problem:
When decoder ES chunk is full, aml_vdec_worker can get next source
buffer but can't not decoder it with vdec_if_decode(). But it will
trigger v4l2_m2m_job_finish() and do another try immediately. This
is a busy loop.

Solution:
Sleep for 50ms when ES chun is full.

Verify:
T5D + TRC

Change-Id: Ide6163242075981c769d6381ecf7edebe7837b4f
Signed-off-by: Song Zhao <song.zhao@amlogic.com>
drivers/amvdec_ports/aml_vcodec_dec.c