path: root/LICENSES/preferred/BSD-2-Clause
diff options
authorJustin Green <greenjustin@chromium.org>2022-06-06 18:24:11 +0100
committerMauro Carvalho Chehab <mchehab@kernel.org>2022-06-20 10:30:36 +0100
commit377301bfb6f0dffbf1f8f7ae009c88c2301f9812 (patch)
tree83e83938477acd1ebfd94c55feacfd7cd6b78554 /LICENSES/preferred/BSD-2-Clause
parent54b4d1911ef7e8616e76804c8b562b9803612cee (diff)
media: mediatek/vcodec: Enable incoherent buffer allocation
Set allow_cache_hints to 1 for the vb2_queue source and destination queues in the mediatek vcodec V4L2 driver. This allows us to allocate buffers with the V4L2_MEMORY_FLAG_NON_COHERENT set. On Mediatek SoCs, this enables caching for this memory, which vastly improves performance when being read from CPU. Read performance for these buffers is in turn important for detiling MM21 video frames in userspace software, such as libyuv or gstreamer. This change should be safe from race conditions since videobuf2 already invalidates or flushes the appropriate cache lines in its prepare() and finish() methods. Tested on a MT8183 SoC. Resulted in both correct detiling and a 10X speedup. Signed-off-by: Justin Green <greenjustin@chromium.org> Suggested-by: Nicolas Dufresne <nicolas.dufresne@collabora.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'LICENSES/preferred/BSD-2-Clause')
0 files changed, 0 insertions, 0 deletions

Privacy Policy