diff options
author | Guo Ren | 2020-05-24 10:44:38 +0000 |
---|---|---|
committer | Guo Ren | 2020-05-28 00:18:36 +0000 |
commit | e0bbb53843b5fdfe464b099217e3b9d97e8a75d7 (patch) | |
tree | 051f4bc65fe08337d910e3e3bcd2f99b69acbacf /arch/csky/kernel | |
parent | 900897591b2bf01154db8f59f6ecf8d60e60f15e (diff) |
csky: Fixup abiv2 syscall_trace break a4 & a5
Current implementation could destory a4 & a5 when strace, so we need to get them
from pt_regs by SAVE_ALL.
Signed-off-by: Guo Ren <guoren@linux.alibaba.com>
Diffstat (limited to 'arch/csky/kernel')
-rw-r--r-- | arch/csky/kernel/entry.S | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/csky/kernel/entry.S b/arch/csky/kernel/entry.S index bfbef30f8a53..76dc7299681b 100644 --- a/arch/csky/kernel/entry.S +++ b/arch/csky/kernel/entry.S @@ -173,8 +173,10 @@ csky_syscall_trace: ldw a3, (sp, LSAVE_A3) #if defined(__CSKYABIV2__) subi sp, 8 - stw r5, (sp, 0x4) - stw r4, (sp, 0x0) + ldw r9, (sp, LSAVE_A4) + stw r9, (sp, 0x0) + ldw r9, (sp, LSAVE_A5) + stw r9, (sp, 0x4) #else ldw r6, (sp, LSAVE_A4) ldw r7, (sp, LSAVE_A5) |