aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64/mm
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2008-02-26 20:30:02 -0500
committerDavid S. Miller <davem@davemloft.net>2008-02-26 20:30:02 -0500
commit622eaec613130e6ea78f2a5d5070e3278b21cd8f (patch)
treef1d9e4d5d9b1b05a99b9a29085a471bea474d40a /arch/sparc64/mm
parent896aef430e5afb56b5f7b1d959226b8a6a08108a (diff)
[SPARC64]: Loosen checks in exception table handling.
Some parts of the kernel now do things like do *_user() accesses while set_fs(KERNEL_DS) that fault on purpose. See, for example, the code added by changeset a0c1e9073ef7428a14309cba010633a6cd6719ea ("futex: runtime enable pi and robust functionality"). That trips up the ASI sanity checking we make in do_kernel_fault(). Just remove it for now. Maybe we can add it back later with an added conditional which looks at the current get_fs() value. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64/mm')
-rw-r--r--arch/sparc64/mm/fault.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/arch/sparc64/mm/fault.c b/arch/sparc64/mm/fault.c
index e2027f27c0fe..918363360280 100644
--- a/arch/sparc64/mm/fault.c
+++ b/arch/sparc64/mm/fault.c
@@ -244,16 +244,8 @@ static void do_kernel_fault(struct pt_regs *regs, int si_code, int fault_code,
244 if (regs->tstate & TSTATE_PRIV) { 244 if (regs->tstate & TSTATE_PRIV) {
245 const struct exception_table_entry *entry; 245 const struct exception_table_entry *entry;
246 246
247 if (asi == ASI_P && (insn & 0xc0800000) == 0xc0800000) { 247 entry = search_exception_tables(regs->tpc);
248 if (insn & 0x2000) 248 if (entry) {
249 asi = (regs->tstate >> 24);
250 else
251 asi = (insn >> 5);
252 }
253
254 /* Look in asi.h: All _S asis have LS bit set */
255 if ((asi & 0x1) &&
256 (entry = search_exception_tables(regs->tpc))) {
257 regs->tpc = entry->fixup; 249 regs->tpc = entry->fixup;
258 regs->tnpc = regs->tpc + 4; 250 regs->tnpc = regs->tpc + 4;
259 return; 251 return;