summaryrefslogtreecommitdiffstats
path: root/arch/sparc64
diff options
context:
space:
mode:
authorDavid S. Miller <davem@sunset.davemloft.net>2005-09-28 21:48:25 -0700
committerDavid S. Miller <davem@sunset.davemloft.net>2005-09-28 21:48:25 -0700
commited3ffaf7b5e0262cb860f106a6632933671cc88f (patch)
tree5b5260e523d5383922cc90f539c1f31e664e78f6 /arch/sparc64
parent10147570f9eaff3920f0c67bad7244c2eb958d4f (diff)
downloadlinux-ed3ffaf7b5e0262cb860f106a6632933671cc88f.tar.gz
linux-ed3ffaf7b5e0262cb860f106a6632933671cc88f.tar.bz2
linux-ed3ffaf7b5e0262cb860f106a6632933671cc88f.zip
[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>
Diffstat (limited to 'arch/sparc64')
-rw-r--r--arch/sparc64/kernel/traps.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/sparc64/kernel/traps.c b/arch/sparc64/kernel/traps.c
index eeb1e835c423..7f190fc57545 100644
--- a/arch/sparc64/kernel/traps.c
+++ b/arch/sparc64/kernel/traps.c
@@ -1333,6 +1333,9 @@ static int cheetah_check_main_memory(unsigned long paddr)
{
unsigned long vaddr = PAGE_OFFSET + paddr;
+ if (vaddr > high_memory)
+ return 0;
+
return kern_addr_valid(vaddr);
}