Linux MIPS Architecture development
 help / color / mirror / Atom feed
* mips64 LOAD_KPTE2 fix
@ 2003-06-02 11:14 Atsushi Nemoto
  2003-06-02 11:23 ` Atsushi Nemoto
  0 siblings, 1 reply; 8+ messages in thread
From: Atsushi Nemoto @ 2003-06-02 11:14 UTC (permalink / raw)
  To: linux-mips, ralf

If a TLB exception occured on very high address (such as
0xffffffffffffffff), invalid_vmalloc_address should be called but
currently not.

I think it is because LOAD_KPTE2 in arch/mips64/mm/tlbex-r4k.S does
not check overflow of (kptbl + offset).  Here is a patch (both 2.4 and
2.5).


diff -u linux-mips-cvs/arch/mips64/mm/tlbex-r4k.S linux.new/arch/mips64/mm/tlbex-r4k.S
--- linux-mips-cvs/arch/mips64/mm/tlbex-r4k.S	Mon Apr 28 09:44:54 2003
+++ linux.new/arch/mips64/mm/tlbex-r4k.S	Mon Jun  2 19:44:57 2003
@@ -72,6 +72,8 @@
 	/*
 	 * Determine that fault address is within vmalloc range.
 	 */
+	bgez	\ptr, \not_vmalloc		# check overflow
+	nop
 	dla	\tmp, ekptbl
 	sltu	\tmp, \ptr, \tmp
 	beqz	\tmp, \not_vmalloc		# not vmalloc
---
Atsushi Nemoto

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2003-06-05 12:20 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-06-02 11:14 mips64 LOAD_KPTE2 fix Atsushi Nemoto
2003-06-02 11:23 ` Atsushi Nemoto
2003-06-03 12:58   ` Maciej W. Rozycki
2003-06-04  1:02     ` Atsushi Nemoto
2003-06-04 14:09       ` Maciej W. Rozycki
2003-06-05  0:58         ` Atsushi Nemoto
2003-06-05 12:15           ` Maciej W. Rozycki
2003-06-05 12:19             ` Ralf Baechle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox