1. 16 10月, 2015 1 次提交
  2. 11 8月, 2015 1 次提交
    • D
      drm/rockchip: Don't grab dev->struct_mutex for in mmap offset ioctl · 648a4ce7
      Daniel Vetter 提交于
      Since David Herrmann's mmap vma manager rework we don't need to grab
      dev->struct_mutex any more to prevent races when looking up the mmap
      offset. Drop it and instead don't forget to use the unref_unlocked
      variant (since the drm core still cares).
      
      Aside: I stumbled over the mmap handler which directly does a
      dma_mmap_attrs. But totally fails to grab a reference on the
      underlying object and hence looks like it happily just leaks the ptes
      since there's no guarantee the mmap isn't still around when
      gem_free_object is called. Which the kerneldoc of dma_mmap_attrs
      explicitly forbids.
      
      v2: Fixup compile fail 0-day spotted.
      
      Cc: Mark Yao <mark.yao@rock-chips.com>
      Reviewed-by: NThierry Reding <treding@nvidia.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@intel.com>
      648a4ce7
  3. 13 7月, 2015 1 次提交
    • D
      drm/rockchip: use drm_gem_mmap helpers · 8915bf20
      Daniel Kurtz 提交于
      Rather than (incompletely [0]) re-implementing drm_gem_mmap() and
      drm_gem_mmap_obj() helpers, call them directly from the rockchip mmap
      routines.
      
      Once the core functions return successfully, the rockchip mmap routines
      can still use dma_mmap_attrs() to simply mmap the entire buffer.
      
      [0] Previously, we were performing the mmap() without first taking a
      reference on the underlying gem buffer.  This could leak ptes if the gem
      object is destroyed while userspace is still holding the mapping.
      Signed-off-by: NDaniel Kurtz <djkurtz@chromium.org>
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Cc: stable@vger.kernel.org
      8915bf20
  4. 07 7月, 2015 1 次提交
    • D
      drm/rockchip: use drm_gem_mmap helpers · 41315b79
      Daniel Kurtz 提交于
      Rather than (incompletely [0]) re-implementing drm_gem_mmap() and
      drm_gem_mmap_obj() helpers, call them directly from the rockchip mmap
      routines.
      
      Once the core functions return successfully, the rockchip mmap routines
      can still use dma_mmap_attrs() to simply mmap the entire buffer.
      
      [0] Previously, we were performing the mmap() without first taking a
      reference on the underlying gem buffer.  This could leak ptes if the gem
      object is destroyed while userspace is still holding the mapping.
      Signed-off-by: NDaniel Kurtz <djkurtz@chromium.org>
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Cc: stable@vger.kernel.org
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      41315b79
  5. 16 3月, 2015 1 次提交
  6. 09 1月, 2015 1 次提交
  7. 02 12月, 2014 1 次提交