diff options
author | Dave Airlie <airlied@redhat.com> | 2013-12-17 09:22:26 +1000 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2013-12-17 09:22:26 +1000 |
commit | f1cd6594496aa4dc3b816794b4e781058f99867c (patch) | |
tree | c415543b4ff0c2192b38577459c581ee1238a954 /drivers/gpu | |
parent | b25b4427e9dfba073cf9bc86603956ed395eb6e3 (diff) | |
parent | d386735588c3e22129c2bc6eb64fc1d37a8f805c (diff) |
Merge branch 'ttm-fixes-3.13' of git://people.freedesktop.org/~thomash/linux into drm-next
A single ttm vm fix.
* 'ttm-fixes-3.13' of git://people.freedesktop.org/~thomash/linux:
drm/ttm: Fix accesses through vmas with only partial coverage
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/ttm/ttm_bo_vm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_bo_vm.c b/drivers/gpu/drm/ttm/ttm_bo_vm.c index b249ab9b1eb2..6440eeac22d2 100644 --- a/drivers/gpu/drm/ttm/ttm_bo_vm.c +++ b/drivers/gpu/drm/ttm/ttm_bo_vm.c @@ -169,9 +169,9 @@ static int ttm_bo_vm_fault(struct vm_area_struct *vma, struct vm_fault *vmf) } page_offset = ((address - vma->vm_start) >> PAGE_SHIFT) + - drm_vma_node_start(&bo->vma_node) - vma->vm_pgoff; - page_last = vma_pages(vma) + - drm_vma_node_start(&bo->vma_node) - vma->vm_pgoff; + vma->vm_pgoff - drm_vma_node_start(&bo->vma_node); + page_last = vma_pages(vma) + vma->vm_pgoff - + drm_vma_node_start(&bo->vma_node); if (unlikely(page_offset >= bo->num_pages)) { retval = VM_FAULT_SIGBUS; |