summaryrefslogtreecommitdiff
path: root/linux/i810_dma.c
diff options
context:
space:
mode:
Diffstat (limited to 'linux/i810_dma.c')
-rw-r--r--linux/i810_dma.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/linux/i810_dma.c b/linux/i810_dma.c
index 79ea3baf..f4eef3a3 100644
--- a/linux/i810_dma.c
+++ b/linux/i810_dma.c
@@ -276,8 +276,12 @@ static unsigned long i810_alloc_page(drm_device_t *dev)
set_bit(PG_locked, &virt_to_page(address)->flags);
#else
get_page(virt_to_page(address));
+#if LINUX_VERSION_CODE < 0x020500
+ LockPage(virt_to_page(address));
+#else
SetPageLocked(virt_to_page(address));
#endif
+#endif
return address;
}