Skip to content

Commit 03150a9

Browse files
ruanjinjie-engThomas Gleixner
authored andcommitted
entry: Remove unused syscall argument from syscall_trace_enter()
The 'syscall' argument of syscall_trace_enter() is immediately overwritten before any real use and serves only as a local variable, so drop the parameter. No functional change intended. Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com> Signed-off-by: Thomas Gleixner <tglx@kernel.org> Link: https://patch.msgid.link/20260128031934.3906955-2-ruanjinjie@huawei.com
1 parent 8f0b4cc commit 03150a9

2 files changed

Lines changed: 4 additions & 5 deletions

File tree

include/linux/entry-common.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
SYSCALL_WORK_SYSCALL_EXIT_TRAP | \
4646
ARCH_SYSCALL_WORK_EXIT)
4747

48-
long syscall_trace_enter(struct pt_regs *regs, long syscall, unsigned long work);
48+
long syscall_trace_enter(struct pt_regs *regs, unsigned long work);
4949

5050
/**
5151
* syscall_enter_from_user_mode_work - Check and handle work before invoking
@@ -75,7 +75,7 @@ static __always_inline long syscall_enter_from_user_mode_work(struct pt_regs *re
7575
unsigned long work = READ_ONCE(current_thread_info()->syscall_work);
7676

7777
if (work & SYSCALL_WORK_ENTER)
78-
syscall = syscall_trace_enter(regs, syscall, work);
78+
syscall = syscall_trace_enter(regs, work);
7979

8080
return syscall;
8181
}

kernel/entry/syscall-common.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,9 @@ static inline void syscall_enter_audit(struct pt_regs *regs, long syscall)
1717
}
1818
}
1919

20-
long syscall_trace_enter(struct pt_regs *regs, long syscall,
21-
unsigned long work)
20+
long syscall_trace_enter(struct pt_regs *regs, unsigned long work)
2221
{
23-
long ret = 0;
22+
long syscall, ret = 0;
2423

2524
/*
2625
* Handle Syscall User Dispatch. This must comes first, since

0 commit comments

Comments
 (0)