Skip to content

Commit e99b250

Browse files
committed
Merge tag 'core-urgent-2020-08-23' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull entry fix from Thomas Gleixner: "A single bug fix for the common entry code. The transcription of the x86 version messed up the reload of the syscall number from pt_regs after ptrace and seccomp which breaks syscall number rewriting" * tag 'core-urgent-2020-08-23' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: core/entry: Respect syscall number rewrites
2 parents d9232cb + d88d59b commit e99b250

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

kernel/entry/common.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@ static long syscall_trace_enter(struct pt_regs *regs, long syscall,
6565

6666
syscall_enter_audit(regs, syscall);
6767

68-
return ret ? : syscall;
68+
/* The above might have changed the syscall number */
69+
return ret ? : syscall_get_nr(current, regs);
6970
}
7071

7172
noinstr long syscall_enter_from_user_mode(struct pt_regs *regs, long syscall)

0 commit comments

Comments
 (0)