aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/char/mem.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/char/mem.c b/drivers/char/mem.c
index 1256454b2d43..436a99017998 100644
--- a/drivers/char/mem.c
+++ b/drivers/char/mem.c
@@ -47,10 +47,7 @@ static inline unsigned long size_inside_page(unsigned long start,
47#ifndef ARCH_HAS_VALID_PHYS_ADDR_RANGE 47#ifndef ARCH_HAS_VALID_PHYS_ADDR_RANGE
48static inline int valid_phys_addr_range(unsigned long addr, size_t count) 48static inline int valid_phys_addr_range(unsigned long addr, size_t count)
49{ 49{
50 if (addr + count > __pa(high_memory)) 50 return addr + count <= __pa(high_memory);
51 return 0;
52
53 return 1;
54} 51}
55 52
56static inline int valid_mmap_phys_addr_range(unsigned long pfn, size_t size) 53static inline int valid_mmap_phys_addr_range(unsigned long pfn, size_t size)