staging: bcm2835_codec: Fix handling of VB2_MEMORY_DMABUF buffers
authorDave Stevenson <dave.stevenson@raspberrypi.org>
Fri, 15 Feb 2019 11:38:45 +0000 (11:38 +0000)
committerpopcornmix <popcornmix@gmail.com>
Mon, 13 May 2019 23:08:21 +0000 (00:08 +0100)
commitad36e6200d5c25c3a7abcef2c8ff131063f59aa8
tree9e77afc9724b02f1e1567af8f9afac491e7dc80a
parenta898c9ff1349af849e9e1c7fe0507bd73efbe893
staging: bcm2835_codec: Fix handling of VB2_MEMORY_DMABUF buffers

If the queue is configured as VB2_MEMORY_DMABUF then vb2_core_expbuf
fails as it ensures the queue is defined as VB2_MEMORY_MMAP.

Correct the handling so that we unmap the buffer from vcsm and the
VPU on cleanup, and then correctly get the dma buf of the new buffer.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
drivers/staging/vc04_services/bcm2835-codec/bcm2835-v4l2-codec.c
drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c
drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.h