media: coda: mark last pending buffer or last meta on decoder stop command

If there is still a buffer pending, mark it as the last buffer. It will
create a meta that is flagged as last when the buffer is copied into the
bitstream ring buffer. If there are no more buffers pending, find the
last bitstream meta and mark it as last. If there is no bitstream meta
either, wake up the capture queue as there will be no more decoded
frames.

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>
Cette révision appartient à :
Philipp Zabel
2019-06-18 12:45:31 -04:00
révisé par Mauro Carvalho Chehab
Parent 9ee50a9489
révision d09ed31014
3 fichiers modifiés avec 42 ajouts et 7 suppressions

Voir le fichier

@@ -146,6 +146,7 @@ struct coda_buffer_meta {
u64 timestamp;
unsigned int start;
unsigned int end;
bool last;
};
/* Per-queue, driver-specific private data */