Bring in patch from kernel for remap_pfn_range
parent
d76f734f68
commit
ad87dd8427
|
@ -645,8 +645,8 @@ int drm_mmap(struct file *filp, struct vm_area_struct *vma)
|
||||||
vma->vm_end - vma->vm_start,
|
vma->vm_end - vma->vm_start,
|
||||||
vma->vm_page_prot, 0))
|
vma->vm_page_prot, 0))
|
||||||
#else
|
#else
|
||||||
if (remap_page_range(DRM_RPR_ARG(vma) vma->vm_start,
|
if (remap_pfn_range(DRM_RPR_ARG(vma) vma->vm_start,
|
||||||
VM_OFFSET(vma) + offset,
|
(VM_OFFSET(vma) + offset) >> PAGE_SHIFT,
|
||||||
vma->vm_end - vma->vm_start,
|
vma->vm_end - vma->vm_start,
|
||||||
vma->vm_page_prot))
|
vma->vm_page_prot))
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -130,9 +130,10 @@ int i810_mmap_buffers(struct file *filp, struct vm_area_struct *vma)
|
||||||
buf_priv->currently_mapped = I810_BUF_MAPPED;
|
buf_priv->currently_mapped = I810_BUF_MAPPED;
|
||||||
unlock_kernel();
|
unlock_kernel();
|
||||||
|
|
||||||
if (remap_page_range(DRM_RPR_ARG(vma) vma->vm_start,
|
if (remap_pfn_range(DRM_RPR_ARG(vma) vma->vm_start,
|
||||||
VM_OFFSET(vma),
|
VM_OFFSET(vma) >> PAGE_SHIFT,
|
||||||
vma->vm_end - vma->vm_start, vma->vm_page_prot))
|
vma->vm_end - vma->vm_start,
|
||||||
|
vma->vm_page_prot))
|
||||||
return -EAGAIN;
|
return -EAGAIN;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -131,9 +131,10 @@ int i830_mmap_buffers(struct file *filp, struct vm_area_struct *vma)
|
||||||
buf_priv->currently_mapped = I830_BUF_MAPPED;
|
buf_priv->currently_mapped = I830_BUF_MAPPED;
|
||||||
unlock_kernel();
|
unlock_kernel();
|
||||||
|
|
||||||
if (remap_page_range(DRM_RPR_ARG(vma) vma->vm_start,
|
if (remap_pfn_range(DRM_RPR_ARG(vma) vma->vm_start,
|
||||||
VM_OFFSET(vma),
|
VM_OFFSET(vma) >> PAGE_SHIFT,
|
||||||
vma->vm_end - vma->vm_start, vma->vm_page_prot))
|
vma->vm_end - vma->vm_start,
|
||||||
|
vma->vm_page_prot))
|
||||||
return -EAGAIN;
|
return -EAGAIN;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue