diff options
author | Christophe Leroy <christophe.leroy@csgroup.eu> | 2021-03-12 13:50:19 +0100 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2021-03-29 04:22:04 +0200 |
commit | 79f4bb17f18162dd95d6aeb6dc3b7da54d6139aa (patch) | |
tree | 22cac6e15631b112c308e4b436510719ea184a5c /arch/powerpc/kernel/entry_32.S | |
parent | powerpc/32: Entry cpu time accounting in C (diff) | |
download | linux-79f4bb17f18162dd95d6aeb6dc3b7da54d6139aa.tar.xz linux-79f4bb17f18162dd95d6aeb6dc3b7da54d6139aa.zip |
powerpc/32: Handle bookE debugging in C in exception entry
The handling of SPRN_DBCR0 and other registers can easily
be done in C instead of ASM.
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/6d6b2497115890b90cfa72a2b3ab1da5f78123c2.1615552866.git.christophe.leroy@csgroup.eu
Diffstat (limited to 'arch/powerpc/kernel/entry_32.S')
-rw-r--r-- | arch/powerpc/kernel/entry_32.S | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S index 0f3f1bdd909e..4ffbcf3df72e 100644 --- a/arch/powerpc/kernel/entry_32.S +++ b/arch/powerpc/kernel/entry_32.S @@ -146,32 +146,9 @@ transfer_to_handler: addi r2, r12, -THREAD addi r11,r1,STACK_FRAME_OVERHEAD stw r11,PT_REGS(r12) -#if defined(CONFIG_40x) || defined(CONFIG_BOOKE) - /* Check to see if the dbcr0 register is set up to debug. Use the - internal debug mode bit to do this. */ - lwz r12,THREAD_DBCR0(r12) - andis. r12,r12,DBCR0_IDM@h -#endif #ifdef CONFIG_PPC_BOOK3S_32 kuep_lock r11, r12 #endif -#if defined(CONFIG_40x) || defined(CONFIG_BOOKE) - beq+ 3f - /* From user and task is ptraced - load up global dbcr0 */ - li r12,-1 /* clear all pending debug events */ - mtspr SPRN_DBSR,r12 - lis r11,global_dbcr0@ha - tophys_novmstack r11,r11 - addi r11,r11,global_dbcr0@l -#ifdef CONFIG_SMP - lwz r9,TASK_CPU(r2) - slwi r9,r9,2 - add r11,r11,r9 -#endif - lwz r12,0(r11) - mtspr SPRN_DBCR0,r12 -#endif - b 3f 2: /* if from kernel, check interrupted DOZE/NAP mode and |