c3597996a3
[ Upstream commit d6c5f06e46a836e6a70c7cfd95bb38a67d9252ec ] Currently, we store syscall nr in pt_regs::regs[11] and syscall execve() accidentally overrides it during its execution: sys_execve() -> do_execve() -> do_execveat_common() -> bprm_execve() -> exec_binprm() -> search_binary_handler() -> load_elf_binary() -> ELF_PLAT_INIT() ELF_PLAT_INIT() reset regs[11] to 0, so in syscall_exit_to_user_mode() we later get a wrong syscall nr. This breaks tools like execsnoop since it relies on execve() tracepoints. Skip pt_regs::regs[11] reset in ELF_PLAT_INIT() to fix the issue. Signed-off-by: Hengqi Chen <hengqi.chen@gmail.com> Signed-off-by: Huacai Chen <chenhuacai@loongson.cn> Signed-off-by: Sasha Levin <sashal@kernel.org> |
||
---|---|---|
.. | ||
boot | ||
configs | ||
include | ||
kernel | ||
lib | ||
mm | ||
net | ||
pci | ||
vdso | ||
Kbuild | ||
Kconfig | ||
Kconfig.debug | ||
Makefile |