summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHauke Mehrtens <hauke@hauke-m.de>2013-10-23 19:22:00 +0200
committerHauke Mehrtens <hauke@hauke-m.de>2013-10-23 19:24:41 +0200
commitf409c746403d29fddc79cda0d415d2072ec628e0 (patch)
tree98682b4ac09d49164a9b1b70f56cec8d0122da4c
parent1729522ac1a5477b972dd8b5a63f423d72441ceb (diff)
backports: remove linux/pagemap.h
This was just used by some GPU drivers Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
-rw-r--r--backport/backport-include/linux/pagemap.h78
1 files changed, 0 insertions, 78 deletions
diff --git a/backport/backport-include/linux/pagemap.h b/backport/backport-include/linux/pagemap.h
deleted file mode 100644
index 8f47a535..00000000
--- a/backport/backport-include/linux/pagemap.h
+++ /dev/null
@@ -1,78 +0,0 @@
-#ifndef __BACKPORT_LINUX_PAGEMAP_H
-#define __BACKPORT_LINUX_PAGEMAP_H
-#include_next <linux/pagemap.h>
-#include <linux/version.h>
-
-#if LINUX_VERSION_CODE < KERNEL_VERSION(3,5,0)
-#include <asm/uaccess.h>
-/*
- * This backports:
- *
- * commit f56f821feb7b36223f309e0ec05986bb137ce418
- * Author: Daniel Vetter <daniel.vetter@ffwll.ch>
- * Date: Sun Mar 25 19:47:41 2012 +0200
- *
- * mm: extend prefault helpers to fault in more than PAGE_SIZE
- *
- * The new functions are used by drm/i915 driver.
- *
- */
-
-#define fault_in_multipages_writeable LINUX_BACKPORT(fault_in_multipages_writeable)
-static inline int fault_in_multipages_writeable(char __user *uaddr, int size)
-{
- int ret = 0;
- char __user *end = uaddr + size - 1;
-
- if (unlikely(size == 0))
- return ret;
-
- /*
- * Writing zeroes into userspace here is OK, because we know that if
- * the zero gets there, we'll be overwriting it.
- */
- while (uaddr <= end) {
- ret = __put_user(0, uaddr);
- if (ret != 0)
- return ret;
- uaddr += PAGE_SIZE;
- }
-
- /* Check whether the range spilled into the next page. */
- if (((unsigned long)uaddr & PAGE_MASK) ==
- ((unsigned long)end & PAGE_MASK))
- ret = __put_user(0, end);
-
- return ret;
-}
-
-#define fault_in_multipages_readable LINUX_BACKPORT(fault_in_multipages_readable)
-static inline int fault_in_multipages_readable(const char __user *uaddr,
- int size)
-{
- volatile char c;
- int ret = 0;
- const char __user *end = uaddr + size - 1;
-
- if (unlikely(size == 0))
- return ret;
-
- while (uaddr <= end) {
- ret = __get_user(c, uaddr);
- if (ret != 0)
- return ret;
- uaddr += PAGE_SIZE;
- }
-
- /* Check whether the range spilled into the next page. */
- if (((unsigned long)uaddr & PAGE_MASK) ==
- ((unsigned long)end & PAGE_MASK)) {
- ret = __get_user(c, end);
- (void)c;
- }
-
- return ret;
-}
-#endif /* < 3.5 */
-
-#endif /* __BACKPORT_LINUX_PAGEMAP_H */