[SPARC64]: Solidify check in cheetah_check_main_memory().
Need to make sure the address is below high_memory before
passing it to kern_addr_valid().
Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/arch/sparc64/kernel/traps.c b/arch/sparc64/kernel/traps.c
index eeb1e83..7f190fc 100644
--- a/arch/sparc64/kernel/traps.c
+++ b/arch/sparc64/kernel/traps.c
@@ -1333,6 +1333,9 @@
{
unsigned long vaddr = PAGE_OFFSET + paddr;
+ if (vaddr > high_memory)
+ return 0;
+
return kern_addr_valid(vaddr);
}