]> asedeno.scripts.mit.edu Git - linux.git/commit
media: coda: jpeg: add CODA960 JPEG encoder support
authorPhilipp Zabel <p.zabel@pengutronix.de>
Thu, 12 Dec 2019 14:02:55 +0000 (15:02 +0100)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Mon, 16 Dec 2019 09:07:59 +0000 (10:07 +0100)
commit96f6f62c4656d13744f0fc5b958a73396f54d91e
tree4215e3102758fda08dd8aa55296bf843cf365e6f
parent3bf6883a88c0e77bc9d0ff6f0c28c599d0e8fa99
media: coda: jpeg: add CODA960 JPEG encoder support

This patch adds JPEG encoding support for CODA960, handling the JPEG
hardware directly. A separate JPEG encoder video device is created due
to the separate hardware unit and different supported pixel formats.
While the hardware can not change subsampling on the fly, it can encode
4:2:2 subsampled images into JPEGs of the same subsampling.

There are two additional tracepoints added to the coda driver that can
be used together with the v4l2:v4l2_qbuf and v4l2:v4l2_dqbuf tracepoints
to to follow video frames through the mem2mem device when encoding or
decoding with the CODA960 JPEG codec:
    coda:coda_jpeg_run
    coda:coda_jpeg_done

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Tested-by: Richard Leitner <richard.leitner@skidata.com>
[hverkuil-cisco@xs4all.nl: removed unused k and q_data_dst variables]
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/platform/coda/coda-common.c
drivers/media/platform/coda/coda-jpeg.c
drivers/media/platform/coda/coda.h
drivers/media/platform/coda/trace.h