mbox series

[v1,0/6] Move dma_buf_mmap_internal() to dynamic locking specification

Message ID 20221110201349.351294-1-dmitry.osipenko@collabora.com (mailing list archive)
Headers show
Series Move dma_buf_mmap_internal() to dynamic locking specification | expand

Message

Dmitry Osipenko Nov. 10, 2022, 8:13 p.m. UTC
Hello,

Recently, dma-buf got a common locking convention for importers and
exporters. All the dma-buf functions were moved to the new locking
convention, apart from the dma_buf_mmap_internal() that was missed out
by accident. This series moves dma_buf_mmap_internal() to the dynamic
locking specification and updates drivers that support mmaping of
dma-bufs to use the debug-assert of the lock.

Thanks to Daniel Vetter for spotting the missed function!

Dmitry Osipenko (6):
  dma-buf: Move dma_buf_mmap_internal() to dynamic locking specification
  drm: Assert held reservation lock for dma-buf mmapping
  udmabuf: Assert held reservation lock for dma-buf mmapping
  dma-buf/heaps: Assert held reservation lock for dma-buf mmapping
  media: videobuf2: Assert held reservation lock for dma-buf mmapping
  fastrpc: Assert held reservation lock for dma-buf mmapping

 drivers/dma-buf/dma-buf.c                             | 7 ++++++-
 drivers/dma-buf/heaps/cma_heap.c                      | 3 +++
 drivers/dma-buf/heaps/system_heap.c                   | 3 +++
 drivers/dma-buf/udmabuf.c                             | 3 +++
 drivers/gpu/drm/drm_prime.c                           | 2 ++
 drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c            | 2 ++
 drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c             | 2 ++
 drivers/gpu/drm/tegra/gem.c                           | 2 ++
 drivers/media/common/videobuf2/videobuf2-dma-contig.c | 3 +++
 drivers/media/common/videobuf2/videobuf2-dma-sg.c     | 3 +++
 drivers/media/common/videobuf2/videobuf2-vmalloc.c    | 3 +++
 drivers/misc/fastrpc.c                                | 3 +++
 12 files changed, 35 insertions(+), 1 deletion(-)

Comments

Dmitry Osipenko Nov. 11, 2022, 8:59 p.m. UTC | #1
On 11/10/22 23:13, Dmitry Osipenko wrote:
> Hello,
> 
> Recently, dma-buf got a common locking convention for importers and
> exporters. All the dma-buf functions were moved to the new locking
> convention, apart from the dma_buf_mmap_internal() that was missed out
> by accident. This series moves dma_buf_mmap_internal() to the dynamic
> locking specification and updates drivers that support mmaping of
> dma-bufs to use the debug-assert of the lock.
> 
> Thanks to Daniel Vetter for spotting the missed function!
> 
> Dmitry Osipenko (6):
>   dma-buf: Move dma_buf_mmap_internal() to dynamic locking specification
>   drm: Assert held reservation lock for dma-buf mmapping
>   udmabuf: Assert held reservation lock for dma-buf mmapping
>   dma-buf/heaps: Assert held reservation lock for dma-buf mmapping
>   media: videobuf2: Assert held reservation lock for dma-buf mmapping
>   fastrpc: Assert held reservation lock for dma-buf mmapping
> 
>  drivers/dma-buf/dma-buf.c                             | 7 ++++++-
>  drivers/dma-buf/heaps/cma_heap.c                      | 3 +++
>  drivers/dma-buf/heaps/system_heap.c                   | 3 +++
>  drivers/dma-buf/udmabuf.c                             | 3 +++
>  drivers/gpu/drm/drm_prime.c                           | 2 ++
>  drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c            | 2 ++
>  drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c             | 2 ++
>  drivers/gpu/drm/tegra/gem.c                           | 2 ++
>  drivers/media/common/videobuf2/videobuf2-dma-contig.c | 3 +++
>  drivers/media/common/videobuf2/videobuf2-dma-sg.c     | 3 +++
>  drivers/media/common/videobuf2/videobuf2-vmalloc.c    | 3 +++
>  drivers/misc/fastrpc.c                                | 3 +++
>  12 files changed, 35 insertions(+), 1 deletion(-)
> 

Applied to drm-misc-next