linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* properly support exec with kernel pointers v3
@ 2020-06-27  7:26 Christoph Hellwig
  2020-06-27  7:27 ` [PATCH 1/5] exec: cleanup the execve wrappers Christoph Hellwig
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Christoph Hellwig @ 2020-06-27  7:26 UTC (permalink / raw)
  To: Al Viro
  Cc: Arnd Bergmann, Brian Gerst, Luis Chamberlain, linux-arm-kernel,
	x86, linux-mips, linux-parisc, linuxppc-dev, linux-s390,
	sparclinux, linux-fsdevel, linux-arch, linux-kernel

Hi all,

this series first cleans up the exec code and then adds proper
kernel_execveat and kernel_wait callers instead of relying on the fact
that the early init code and kernel threads implicitly run with
the address limit set to KERNEL_DS.

Note that the cleanup removes the compat execve(at) handlers entirely, as
we can handle the compat difference very nicely in a unified codebase.
x32 needs two hacky #defines for that for now, although those can go
away if the x32 syscall rework from Brian gets merged.

I think this is ready to get picked up.  What would the best tree be?
Most important a git tree would be good, as I have other work building
on top of it.


Changes since v2:
 - drop the kernel_wait addition, as this interacts with a series
   from Luis and should be merged together with that one

Changes since v1:
 - remove a pointless ifdef from get_user_arg_ptr
 - remove the need for a compat syscall handler for x32


Diffstat:
 arch/arm64/include/asm/unistd32.h                  |    4 
 arch/mips/kernel/syscalls/syscall_n32.tbl          |    4 
 arch/mips/kernel/syscalls/syscall_o32.tbl          |    4 
 arch/parisc/kernel/syscalls/syscall.tbl            |    4 
 arch/powerpc/kernel/syscalls/syscall.tbl           |    4 
 arch/s390/kernel/syscalls/syscall.tbl              |    4 
 arch/sparc/kernel/syscalls.S                       |    4 
 arch/x86/entry/syscall_x32.c                       |    7 
 arch/x86/entry/syscalls/syscall_32.tbl             |    4 
 arch/x86/entry/syscalls/syscall_64.tbl             |    4 
 fs/exec.c                                          |  248 ++++++++-------------
 include/linux/binfmts.h                            |   10 
 include/linux/compat.h                             |    7 
 include/uapi/asm-generic/unistd.h                  |    4 
 init/main.c                                        |    5 
 kernel/umh.c                                       |   14 -
 tools/include/uapi/asm-generic/unistd.h            |    4 
 tools/perf/arch/powerpc/entry/syscalls/syscall.tbl |    4 
 tools/perf/arch/s390/entry/syscalls/syscall.tbl    |    4 
 tools/perf/arch/x86/entry/syscalls/syscall_64.tbl  |    4 
 20 files changed, 149 insertions(+), 198 deletions(-)

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-06-27  7:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-27  7:26 properly support exec with kernel pointers v3 Christoph Hellwig
2020-06-27  7:27 ` [PATCH 1/5] exec: cleanup the execve wrappers Christoph Hellwig
2020-06-27  7:27 ` [PATCH 2/5] exec: simplify the compat syscall handling Christoph Hellwig
2020-06-27  7:27 ` [PATCH 3/5] exec: cleanup the count() function Christoph Hellwig
2020-06-27  7:27 ` [PATCH 4/5] exec: split prepare_arg_pages Christoph Hellwig
2020-06-27  7:27 ` [PATCH 5/5] exec: add a kernel_execveat helper Christoph Hellwig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).