summaryrefslogtreecommitdiff
path: root/linux-core
diff options
context:
space:
mode:
Diffstat (limited to 'linux-core')
-rw-r--r--linux-core/drm_vm.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/linux-core/drm_vm.c b/linux-core/drm_vm.c
index 47693b03..02520c76 100644
--- a/linux-core/drm_vm.c
+++ b/linux-core/drm_vm.c
@@ -34,6 +34,9 @@
*/
#include "drmP.h"
+#if defined(__ia64__)
+#include <linux/efi.h>
+#endif
/**
* \c nopage method for AGP virtual memory.
@@ -639,9 +642,13 @@ int drm_mmap(struct file *filp, struct vm_area_struct *vma)
vma->vm_flags |= VM_IO; /* not in core dump */
}
#if defined(__ia64__)
- if (map->type != _DRM_AGP)
+ if (efi_range_is_wc(vma->vm_start, vma->vm_end -
+ vma->vm_start))
+ vma->vm_page_prot =
+ pgprot_writecombine(vma->vm_page_prot);
+ else
vma->vm_page_prot =
- pgprot_writecombine(vma->vm_page_prot);
+ pgprot_noncached(vma->vm_page_prot);
#endif
offset = dev->driver->get_reg_ofs(dev);
#ifdef __sparc__