1
0
Fork 0

xtensa: fix syscall_set_return_value

syscall return value is in the register a2, not a0.

Cc: stable@vger.kernel.org # v5.0+
Fixes: 9f24f3c106 ("xtensa: implement tracehook functions and enable HAVE_ARCH_TRACEHOOK")
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
alistair/sunxi64-5.5-dsi
Max Filippov 2019-11-14 15:05:40 -08:00
parent d80a505348
commit c2d9aa3b6e
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ static inline void syscall_set_return_value(struct task_struct *task,
struct pt_regs *regs,
int error, long val)
{
regs->areg[0] = (long) error ? error : val;
regs->areg[2] = (long) error ? error : val;
}
#define SYSCALL_MAX_ARGS 6