diff options
author | Ingo Molnar <mingo@kernel.org> | 2019-04-10 09:14:42 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2019-04-10 09:14:42 +0200 |
commit | 54bbfe75cbb10384b0a62efae80fde21deea1dd0 (patch) | |
tree | eed22c29cdecce36153bbb83ee7a9da7eed60ccd /arch/xtensa/include/asm/syscall.h | |
parent | ddb20d1d3aed8f130519c0a29cd5392efcc067b8 (diff) | |
parent | 771acc7e4a6e5dba779cb1a7fd851a164bc81033 (diff) | |
download | talos-op-linux-54bbfe75cbb10384b0a62efae80fde21deea1dd0.tar.gz talos-op-linux-54bbfe75cbb10384b0a62efae80fde21deea1dd0.zip |
Merge branch 'linus' into locking/core, to pick up fixes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/xtensa/include/asm/syscall.h')
-rw-r--r-- | arch/xtensa/include/asm/syscall.h | 33 |
1 files changed, 6 insertions, 27 deletions
diff --git a/arch/xtensa/include/asm/syscall.h b/arch/xtensa/include/asm/syscall.h index a168bf81c7f4..91dc06d58060 100644 --- a/arch/xtensa/include/asm/syscall.h +++ b/arch/xtensa/include/asm/syscall.h @@ -59,45 +59,24 @@ static inline void syscall_set_return_value(struct task_struct *task, static inline void syscall_get_arguments(struct task_struct *task, struct pt_regs *regs, - unsigned int i, unsigned int n, unsigned long *args) { static const unsigned int reg[] = XTENSA_SYSCALL_ARGUMENT_REGS; - unsigned int j; + unsigned int i; - if (n == 0) - return; - - WARN_ON_ONCE(i + n > SYSCALL_MAX_ARGS); - - for (j = 0; j < n; ++j) { - if (i + j < SYSCALL_MAX_ARGS) - args[j] = regs->areg[reg[i + j]]; - else - args[j] = 0; - } + for (i = 0; i < 6; ++i) + args[i] = regs->areg[reg[i]]; } static inline void syscall_set_arguments(struct task_struct *task, struct pt_regs *regs, - unsigned int i, unsigned int n, const unsigned long *args) { static const unsigned int reg[] = XTENSA_SYSCALL_ARGUMENT_REGS; - unsigned int j; - - if (n == 0) - return; - - if (WARN_ON_ONCE(i + n > SYSCALL_MAX_ARGS)) { - if (i < SYSCALL_MAX_ARGS) - n = SYSCALL_MAX_ARGS - i; - else - return; - } + unsigned int i; - for (j = 0; j < n; ++j) - regs->areg[reg[i + j]] = args[j]; + for (i = 0; i < 6; ++i) + regs->areg[reg[i]] = args[i]; } asmlinkage long xtensa_rt_sigreturn(struct pt_regs*); |