|
Hello All.
I am using playbin3 pipeline with H/W decoder/sink in our TV target.
When I seek operation from our media player, pipeline hangs up.
Following is simple scenario.
1) File Duration is 15 sec.
2) Perform flush-seek to 1 sec when current position reaches around 10 sec.
3) Pipeline hangs up.
I checked the back trace with gdb and log message.
Actually, our H/W decoder pulls and enqueues much more data than S/W decoder.
So, they receive EOS event at running time around 5 sec.
Then, H/W decoder tries to drain all remain data to downstream(sink) after detecting EOS event.
But, at that time, our media player does not know this situation and starts seek operation(with flush) and Flush-Start event is sent. Multiqueue does not get result the pushed EOS event from the H/W decoder and tries to call gst_pad_pause_task(sq->srcpad).
Thus, deadlock is happened.
So, this hang up(dead lock) problem is caused by
1) GST_PAD_STREAM_LOCK (mq->srcpad) is called when pushing EOS event by streaming thread.
2) The EOS event is not returned by Flush-Start event and GST_PAD_STREAM_UNLOCK (mq->srcpad) is not called.
3) GST_PAD_STREAM_LOCK (mq->srcpad) is called again by gst_pad_pause_task (sq->srcpad) in gst_single_queue_flush ().
If it is difficult to modify in our H/W decoder side, Is there any good way to avoid this problem?
Please check my deadlock problem and give me some information to avoid this problem.
Thanks.
|