Skip to content

Commit

Permalink
x86: fix sys_sigreturn() return type to be long, not unsigned long
Browse files Browse the repository at this point in the history
Same as with other system calls, sys_sigreturn() should return a value
of type long, not unsigned long. This also matches the behaviour for
IA32_EMULATION, see sys32_sigreturn() in arch/x86/ia32/ia32_signal.c .

Cc: Andi Kleen <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Jiri Slaby <[email protected]>
Cc: [email protected]
Cc: Michael Tautschnig <[email protected]>
Reviewed-by: Thomas Gleixner <[email protected]>
Signed-off-by: Dominik Brodowski <[email protected]>
Dominik Brodowski committed Apr 2, 2018
1 parent 66f4e88 commit 025bd39
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion arch/x86/include/asm/syscalls.h
Original file line number Diff line number Diff line change
@@ -35,7 +35,7 @@ asmlinkage long sys_get_thread_area(struct user_desc __user *);
#ifdef CONFIG_X86_32

/* kernel/signal.c */
asmlinkage unsigned long sys_sigreturn(void);
asmlinkage long sys_sigreturn(void);

/* kernel/vm86_32.c */
struct vm86_struct;
2 changes: 1 addition & 1 deletion arch/x86/kernel/signal.c
Original file line number Diff line number Diff line change
@@ -601,7 +601,7 @@ static int x32_setup_rt_frame(struct ksignal *ksig,
* Do a signal return; undo the signal stack.
*/
#ifdef CONFIG_X86_32
asmlinkage unsigned long sys_sigreturn(void)
asmlinkage long sys_sigreturn(void)
{
struct pt_regs *regs = current_pt_regs();
struct sigframe __user *frame;

0 comments on commit 025bd39

Please sign in to comment.