v4l2: camera: Handle memory mapping of buffers directly

In the upcoming FrameBuffer API the memory mapping of buffers will be
left to the user of the FrameBuffer objects. Prepare the V4L2
compatibility layer to this upcoming change to ease conversion to the
new API.

Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
Niklas Söderlund 2020-01-09 15:20:44 +01:00
parent 35ac23dca1
commit 3c4b872443
5 changed files with 30 additions and 15 deletions

View file

@ -223,7 +223,7 @@ void *V4L2CompatManager::mmap(void *addr, size_t length, int prot, int flags,
if (!proxy)
return fops_.mmap(addr, length, prot, flags, fd, offset);
void *map = proxy->mmap(length, prot, flags, offset);
void *map = proxy->mmap(addr, length, prot, flags, offset);
if (map == MAP_FAILED)
return map;