diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-08-20 11:07:56 +1000 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-08-20 11:07:56 +1000 |
commit | 4f0dbc2781b9dc457159b676289f874ab2dc3560 (patch) | |
tree | 2b8af0f301eaf0bc47d643b99d48a84611b4bed3 /arch/powerpc/kernel/exceptions-64s.S | |
parent | 3c15a68880023722fc794018768df556f438ae98 (diff) | |
parent | 20002ded4d937ca87aca6253b874920a96a763c4 (diff) | |
download | kernel-crypto-4f0dbc2781b9dc457159b676289f874ab2dc3560.tar.gz kernel-crypto-4f0dbc2781b9dc457159b676289f874ab2dc3560.tar.xz kernel-crypto-4f0dbc2781b9dc457159b676289f874ab2dc3560.zip |
Merge commit 'paulus-perf/master' into next
Diffstat (limited to 'arch/powerpc/kernel/exceptions-64s.S')
-rw-r--r-- | arch/powerpc/kernel/exceptions-64s.S | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/exceptions-64s.S b/arch/powerpc/kernel/exceptions-64s.S index 50f2ad36ed0..1808876edcc 100644 --- a/arch/powerpc/kernel/exceptions-64s.S +++ b/arch/powerpc/kernel/exceptions-64s.S @@ -731,6 +731,11 @@ BEGIN_FTR_SECTION bne- do_ste_alloc /* If so handle it */ END_FTR_SECTION_IFCLR(CPU_FTR_SLB) + clrrdi r11,r1,THREAD_SHIFT + lwz r0,TI_PREEMPT(r11) /* If we're in an "NMI" */ + andis. r0,r0,NMI_MASK@h /* (i.e. an irq when soft-disabled) */ + bne 77f /* then don't call hash_page now */ + /* * On iSeries, we soft-disable interrupts here, then * hard-enable interrupts so that the hash_page code can spin on @@ -835,6 +840,20 @@ handle_page_fault: bl .low_hash_fault b .ret_from_except +/* + * We come here as a result of a DSI at a point where we don't want + * to call hash_page, such as when we are accessing memory (possibly + * user memory) inside a PMU interrupt that occurred while interrupts + * were soft-disabled. We want to invoke the exception handler for + * the access, or panic if there isn't a handler. + */ +77: bl .save_nvgprs + mr r4,r3 + addi r3,r1,STACK_FRAME_OVERHEAD + li r5,SIGSEGV + bl .bad_page_fault + b .ret_from_except + /* here we have a segment miss */ do_ste_alloc: bl .ste_allocate /* try to insert stab entry */ |