media: coda: only wake up capture queue if no pending buffers to encode
authorPhilipp Zabel <p.zabel@pengutronix.de>
Tue, 18 Jun 2019 16:45:28 +0000 (12:45 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Mon, 24 Jun 2019 18:43:25 +0000 (14:43 -0400)
commit0f8f633834357f2513d21a6468db6d5989e8c494
tree8ac6827f4e31cbc6016eefafc134d76cdc4d7d2e
parent0ee08a1e7b713dcf0d2526af35314dd7f21c8138
media: coda: only wake up capture queue if no pending buffers to encode

If there are no pending queued output buffers to be encoded, waking up
the capture queue with -EPIPE signals end of stream. If there are
pending buffers on the other hand, setting the V4L2_BUF_FLAG_LAST on
the resulting encoded capture buffers is all that is needed.

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/platform/coda/coda-common.c