]> git.baikalelectronics.ru Git - kernel.git/commit
csky: Set regs->usp to kernel sp, when the exception is from kernel
authorGuo Ren <guoren@linux.alibaba.com>
Tue, 17 Dec 2019 03:12:55 +0000 (11:12 +0800)
committerGuo Ren <guoren@linux.alibaba.com>
Fri, 21 Feb 2020 07:43:24 +0000 (15:43 +0800)
commit02759933c1d391b35760a347a074ae336c9bf27c
tree0de930c6cf557570a44beb5c167384ca0692d791
parentc7bc7113391703711e35e5e06d1334e99cff6764
csky: Set regs->usp to kernel sp, when the exception is from kernel

In the past, we didn't care about kernel sp when saving pt_reg. But in some
cases, we still need pt_reg->usp to represent the kernel stack before enter
exception.

For cmpxhg in atomic.S, we need save and restore usp for above.

Signed-off-by: Guo Ren <guoren@linux.alibaba.com>
arch/csky/abiv1/inc/abi/entry.h
arch/csky/abiv2/inc/abi/entry.h
arch/csky/kernel/atomic.S