summaryrefslogtreecommitdiffstats
path: root/include/linux/pagemap.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/pagemap.h')
-rw-r--r--include/linux/pagemap.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h
index a1176b978..a3b897378 100644
--- a/include/linux/pagemap.h
+++ b/include/linux/pagemap.h
@@ -36,7 +36,7 @@
/*
* From a kernel address, get the "struct page *"
*/
-#define page_cache_entry(x) (mem_map + MAP_NR(x))
+#define page_cache_entry(x) virt_to_page(x)
extern unsigned int page_hash_bits;
#define PAGE_HASH_BITS (page_hash_bits)