aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mm.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/mm.h')
-rw-r--r--include/linux/mm.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h
index a862a96952e0..f28a0338574f 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -235,6 +235,14 @@ static inline int get_page_unless_zero(struct page *page)
235struct page *vmalloc_to_page(const void *addr); 235struct page *vmalloc_to_page(const void *addr);
236unsigned long vmalloc_to_pfn(const void *addr); 236unsigned long vmalloc_to_pfn(const void *addr);
237 237
238/* Determine if an address is within the vmalloc range */
239static inline int is_vmalloc_addr(const void *x)
240{
241 unsigned long addr = (unsigned long)x;
242
243 return addr >= VMALLOC_START && addr < VMALLOC_END;
244}
245
238static inline struct page *compound_head(struct page *page) 246static inline struct page *compound_head(struct page *page)
239{ 247{
240 if (unlikely(PageTail(page))) 248 if (unlikely(PageTail(page)))