Re: [PATCH v2] kernel: Implement selective syscall userspace redirection

2020-07-09 Thread Gabriel Krisman Bertazi
Kees Cook writes: > On Thu, Jul 09, 2020 at 12:38:40AM -0400, Gabriel Krisman Bertazi wrote: >> [...] >> +config SYSCALL_USER_DISPATCH >> +bool "Support rejecting syscalls not coming from a dispatcher" > > bike shed: this doesn't really describe why it's useful. Maybe: > > bool "Support

Re: [PATCH v2] kernel: Implement selective syscall userspace redirection

2020-07-09 Thread Kees Cook
On Thu, Jul 09, 2020 at 12:38:40AM -0400, Gabriel Krisman Bertazi wrote: > [...] > +config SYSCALL_USER_DISPATCH > + bool "Support rejecting syscalls not coming from a dispatcher" bike shed: this doesn't really describe why it's useful. Maybe: bool "Support syscall redirection to user

Re: [PATCH v2] kernel: Implement selective syscall userspace redirection

2020-07-09 Thread Gabriel Krisman Bertazi
Matthew Wilcox writes: > On Thu, Jul 09, 2020 at 12:38:40AM -0400, Gabriel Krisman Bertazi wrote: >> The proposed interface looks like this: >> >> prctl(PR_SET_SYSCALL_USER_DISPATCH, , , [selector]) >> >> Dispatcher is the address of a syscall instruction that is allowed to >> by-pass the blo

Re: [PATCH v2] kernel: Implement selective syscall userspace redirection

2020-07-09 Thread Matthew Wilcox
On Thu, Jul 09, 2020 at 12:38:40AM -0400, Gabriel Krisman Bertazi wrote: > The proposed interface looks like this: > > prctl(PR_SET_SYSCALL_USER_DISPATCH, , , [selector]) > > Dispatcher is the address of a syscall instruction that is allowed to > by-pass the blockage, such that in fast paths yo