diff options
author | Philipp Zabel <p.zabel@pengutronix.de> | 2014-10-08 13:09:27 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2014-10-28 15:41:07 -0200 |
commit | edc16cb1159c03864c74fd0411ec5d0bcce845be (patch) | |
tree | 155809aa32a8723a91928e709f174162ab3f31c9 /drivers/media/platform/coda/coda.h | |
parent | d4bb75f6eee2f9cd7dc0787e3a8fb6bb3e430802 (diff) |
[media] coda: drop JPEG buffers not framed by SOI and EOI markers
This patch adds a quick check for valid JPEG frames before feeding them into
the bitstream buffer: Frames that do not begin with the JPEG start of image
marker and end with the end of image marker are dropped.
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/platform/coda/coda.h')
-rw-r--r-- | drivers/media/platform/coda/coda.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/media/platform/coda/coda.h b/drivers/media/platform/coda/coda.h index 8dd81a75c2f..5dd47e5f97c 100644 --- a/drivers/media/platform/coda/coda.h +++ b/drivers/media/platform/coda/coda.h @@ -293,6 +293,7 @@ void coda_bit_stream_end_flag(struct coda_ctx *ctx); int coda_h264_padding(int size, char *p); +bool coda_jpeg_check_buffer(struct coda_ctx *ctx, struct vb2_buffer *vb); int coda_jpeg_write_tables(struct coda_ctx *ctx); void coda_set_jpeg_compression_quality(struct coda_ctx *ctx, int quality); |