diff options
author | Philipp Zabel <p.zabel@pengutronix.de> | 2015-07-10 09:37:44 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2015-07-17 10:23:01 -0400 |
commit | 68aa7ee15cd683006ec1ac91ad60c019bf62d978 (patch) | |
tree | b0018fc03521e8cb6ab420c870c45d3f825690f3 /drivers/media/platform/coda | |
parent | 47f3fa63ee5c0e6bdf9c9d5ed73fc791981336e4 (diff) |
[media] coda: reset CODA960 hardware after sequence end
On i.MX6, sometimes after decoding a stream, encoding will produce macroblock
errors caused by missing 8-byte sequences in the output stream. Until the cause
for this is found, reset the hardware after sequence end, which seems to help.
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/platform/coda')
-rw-r--r-- | drivers/media/platform/coda/coda-bit.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/media/platform/coda/coda-bit.c b/drivers/media/platform/coda/coda-bit.c index 25910ccd2da0..bcb9911d5e3f 100644 --- a/drivers/media/platform/coda/coda-bit.c +++ b/drivers/media/platform/coda/coda-bit.c | |||
@@ -1347,6 +1347,14 @@ static void coda_seq_end_work(struct work_struct *work) | |||
1347 | "CODA_COMMAND_SEQ_END failed\n"); | 1347 | "CODA_COMMAND_SEQ_END failed\n"); |
1348 | } | 1348 | } |
1349 | 1349 | ||
1350 | /* | ||
1351 | * FIXME: Sometimes h.264 encoding fails with 8-byte sequences missing | ||
1352 | * from the output stream after the h.264 decoder has run. Resetting the | ||
1353 | * hardware after the decoder has finished seems to help. | ||
1354 | */ | ||
1355 | if (dev->devtype->product == CODA_960) | ||
1356 | coda_hw_reset(ctx); | ||
1357 | |||
1350 | kfifo_init(&ctx->bitstream_fifo, | 1358 | kfifo_init(&ctx->bitstream_fifo, |
1351 | ctx->bitstream.vaddr, ctx->bitstream.size); | 1359 | ctx->bitstream.vaddr, ctx->bitstream.size); |
1352 | 1360 | ||