summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/rockchip/rockchip_drm_gem.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2017-11-27 10:54:33 +0100
committerDaniel Vetter <daniel.vetter@ffwll.ch>2017-11-27 10:54:33 +0100
commit1420edf7a3fbc9b8b0bbe24c3724d582dd4def28 (patch)
tree919f3adb874b11cb5e4ed2df37a9370847300ea4 /drivers/gpu/drm/rockchip/rockchip_drm_gem.c
parent517f56839f581618d24f2e67a35738a5c6cbaecb (diff)
parent4fbd8d194f06c8a3fd2af1ce560ddb31f7ec8323 (diff)
Merge tag 'v4.15-rc1' into drm-misc-fixes
Linux 4.15-rc1 Pull in the merge window to resync. Dave didn't get his -fixes pull landed in time, and now there's another rockchip fix pending, so fast-forwarding isn't possible, hence backmerge. Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Diffstat (limited to 'drivers/gpu/drm/rockchip/rockchip_drm_gem.c')
-rw-r--r--drivers/gpu/drm/rockchip/rockchip_drm_gem.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_gem.c b/drivers/gpu/drm/rockchip/rockchip_drm_gem.c
index 1869c8bb76c8..1d9655576b6e 100644
--- a/drivers/gpu/drm/rockchip/rockchip_drm_gem.c
+++ b/drivers/gpu/drm/rockchip/rockchip_drm_gem.c
@@ -220,7 +220,7 @@ static int rockchip_drm_gem_object_mmap_iommu(struct drm_gem_object *obj,
{
struct rockchip_gem_object *rk_obj = to_rockchip_obj(obj);
unsigned int i, count = obj->size >> PAGE_SHIFT;
- unsigned long user_count = (vma->vm_end - vma->vm_start) >> PAGE_SHIFT;
+ unsigned long user_count = vma_pages(vma);
unsigned long uaddr = vma->vm_start;
unsigned long offset = vma->vm_pgoff;
unsigned long end = user_count + offset;