summaryrefslogtreecommitdiffstats
path: root/include/asm-sh
diff options
context:
space:
mode:
authorPaul Mundt <lethal@linux-sh.org>2007-05-23 17:40:56 +0900
committerPaul Mundt <lethal@hera.kernel.org>2007-06-08 02:43:42 +0000
commit5900711ad7173b1cf3ee72eb21572e20b263ca0d (patch)
treedc907af02d08229578b9e358cf391eb43839806f /include/asm-sh
parent678597be5e116516e9cfa806fc6ea6eb5de77d8f (diff)
downloadop-kernel-dev-5900711ad7173b1cf3ee72eb21572e20b263ca0d.zip
op-kernel-dev-5900711ad7173b1cf3ee72eb21572e20b263ca0d.tar.gz
sh: pfn_valid() depends on flatmem.
pfn_valid() is already defined in the sparsemem case, so we only need to define this for CONFIG_FLATMEM. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'include/asm-sh')
-rw-r--r--include/asm-sh/page.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/asm-sh/page.h b/include/asm-sh/page.h
index 011dfbe..cb54b25 100644
--- a/include/asm-sh/page.h
+++ b/include/asm-sh/page.h
@@ -135,7 +135,9 @@ typedef struct { unsigned long pgd; } pgd_t;
#define PFN_START (__MEMORY_START >> PAGE_SHIFT)
#define ARCH_PFN_OFFSET (PFN_START)
#define virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT)
+#ifdef CONFIG_FLATMEM
#define pfn_valid(pfn) ((pfn) >= min_low_pfn && (pfn) < max_low_pfn)
+#endif
#define virt_addr_valid(kaddr) pfn_valid(__pa(kaddr) >> PAGE_SHIFT)
#define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \
OpenPOWER on IntegriCloud