mftransform: Fix deadlock when MFT requests processing output twice
authorSeungha Yang <seungha@centricular.com>
Mon, 8 Jun 2020 14:46:43 +0000 (23:46 +0900)
committerSeungha Yang <seungha@centricular.com>
Mon, 8 Jun 2020 14:46:43 +0000 (23:46 +0900)
commit52a82f5b84c74d3e1b94c44d7ee8391be9512551
treee4a1a4eb570f71f7cbfc33a5e2dd7669a0ac310a
parent309c679c43a1ea3df5ab34a8d0d9f1f369f3dcc5
mftransform: Fix deadlock when MFT requests processing output twice

This sequence of event/data flow might happen

1) Initially we have one pending output event
  1-1) Then, process the pending output data
2) No pending input event, then we should wait new pending input event
  2-1) Wakeup by new pending event (but it's pending output event)

In above case, MFT will not report new pending input event
if pending output is not processed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1325>
sys/mediafoundation/gstmftransform.cpp