diff options
Diffstat (limited to 'arch/arm/include/asm/syscall.h')
-rw-r--r-- | arch/arm/include/asm/syscall.h | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/arch/arm/include/asm/syscall.h b/arch/arm/include/asm/syscall.h index db969a2972ae..080ce70cab12 100644 --- a/arch/arm/include/asm/syscall.h +++ b/arch/arm/include/asm/syscall.h | |||
@@ -65,26 +65,12 @@ static inline void syscall_get_arguments(struct task_struct *task, | |||
65 | 65 | ||
66 | static inline void syscall_set_arguments(struct task_struct *task, | 66 | static inline void syscall_set_arguments(struct task_struct *task, |
67 | struct pt_regs *regs, | 67 | struct pt_regs *regs, |
68 | unsigned int i, unsigned int n, | ||
69 | const unsigned long *args) | 68 | const unsigned long *args) |
70 | { | 69 | { |
71 | if (n == 0) | 70 | regs->ARM_ORIG_r0 = args[0]; |
72 | return; | 71 | args++; |
73 | 72 | ||
74 | if (i + n > SYSCALL_MAX_ARGS) { | 73 | memcpy(®s->ARM_r0 + 1, args, 5 * sizeof(args[0])); |
75 | pr_warn("%s called with max args %d, handling only %d\n", | ||
76 | __func__, i + n, SYSCALL_MAX_ARGS); | ||
77 | n = SYSCALL_MAX_ARGS - i; | ||
78 | } | ||
79 | |||
80 | if (i == 0) { | ||
81 | regs->ARM_ORIG_r0 = args[0]; | ||
82 | args++; | ||
83 | i++; | ||
84 | n--; | ||
85 | } | ||
86 | |||
87 | memcpy(®s->ARM_r0 + i, args, n * sizeof(args[0])); | ||
88 | } | 74 | } |
89 | 75 | ||
90 | static inline int syscall_get_arch(void) | 76 | static inline int syscall_get_arch(void) |