Skip to content

Commit a5447fb

Browse files
committed
csky: Fixup kprobes handler couldn't change pc
The "Changing Execution Path" section in the Documentation/kprobes.txt said: Since kprobes can probe into a running kernel code, it can change the register set, including instruction pointer. Signed-off-by: Guo Ren <[email protected]> Cc: Arnd Bergmann <[email protected]>
1 parent f788bb2 commit a5447fb

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

arch/csky/abiv2/mcount.S

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,9 @@
5555

5656
.macro mcount_exit_regs
5757
RESTORE_REGS_FTRACE
58-
ldw t1, (sp, 0)
58+
subi sp, 152
59+
ldw t1, (sp, 4)
60+
addi sp, 152
5961
ldw r8, (sp, 4)
6062
ldw lr, (sp, 8)
6163
addi sp, 12

0 commit comments

Comments
 (0)