]> git.ipfire.org Git - thirdparty/linux.git/commit
media: videobuf2: add begin/end cpu_access callbacks to dma-contig
authorSergey Senozhatsky <senozhatsky@chromium.org>
Thu, 14 May 2020 16:01:49 +0000 (18:01 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Tue, 23 Jun 2020 11:37:57 +0000 (13:37 +0200)
commitd5adf1b0c2a31f8244ded805578188e067baaf5e
tree65b8635fcc268b967b00d0daedcc2015f8adde7c
parent093067ed1285d027d1e4a0e3dba72160849fbb84
media: videobuf2: add begin/end cpu_access callbacks to dma-contig

Provide begin_cpu_access() and end_cpu_access() callbacks for
cache synchronisation on exported buffers.

The patch also adds a new helper function - vb2_dc_buffer_consistent(),
which returns true is if the buffer is consistent (DMA_ATTR_NON_CONSISTENT
bit cleared), so then we don't need to sync anything.

Signed-off-by: Sergey Senozhatsky <senozhatsky@chromium.org>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/common/videobuf2/videobuf2-dma-contig.c