<feed xmlns='http://www.w3.org/2005/Atom'>
<title>wireguard-linux/arch/x86/entry/syscalls, branch jd/unified-crypt-queue</title>
<subtitle>WireGuard for the Linux kernel</subtitle>
<id>https://git.zx2c4.com/wireguard-linux/atom/arch/x86/entry/syscalls?h=jd%2Funified-crypt-queue</id>
<link rel='self' href='https://git.zx2c4.com/wireguard-linux/atom/arch/x86/entry/syscalls?h=jd%2Funified-crypt-queue'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/'/>
<updated>2020-03-21T15:03:24Z</updated>
<entry>
<title>x86/entry/32: Use IA32-specific wrappers for syscalls taking 64-bit arguments</title>
<updated>2020-03-21T15:03:24Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:41Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=121b32a58a3af89a780cf194ce3769fc4120e574'/>
<id>urn:sha1:121b32a58a3af89a780cf194ce3769fc4120e574</id>
<content type='text'>
For the 32-bit syscall interface, 64-bit arguments (loff_t) are passed via
a pair of 32-bit registers.  These register pairs end up in consecutive stack
slots, which matches the C ABI for 64-bit arguments.  But when accessing the
registers directly from pt_regs, the wrapper needs to manually reassemble the
64-bit value.  These wrappers already exist for 32-bit compat, so make them
available to 32-bit native in preparation for enabling pt_regs-based syscalls.

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Dominik Brodowski &lt;linux@dominikbrodowski.net&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-16-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry/32: Rename 32-bit specific syscalls</title>
<updated>2020-03-21T15:03:23Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:40Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=866128a996647097d599c6b91deb340d4da593a8'/>
<id>urn:sha1:866128a996647097d599c6b91deb340d4da593a8</id>
<content type='text'>
Rename the syscalls that only exist for 32-bit from x86_* to ia32_* to make it
clear they are for 32-bit only.  Also rename the functions to match the syscall
name.

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Dominik Brodowski &lt;linux@dominikbrodowski.net&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-15-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry/32: Clean up syscall_32.tbl</title>
<updated>2020-03-21T15:03:23Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:39Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=a845a6cf1dad16fa86007c86702fb27fec89d38b'/>
<id>urn:sha1:a845a6cf1dad16fa86007c86702fb27fec89d38b</id>
<content type='text'>
After removal of the __ia32_ prefix, remove compat entries that are now
identical to the native entry.

Converted with this script and fixing up whitespace:

while read nr abi name entry compat; do
    if [ "${nr:0:1}" = "#" ]; then
        echo $nr $abi $name $entry $compat
        continue
    fi
    if [ "$entry" = "$compat" ]; then
        compat=""
    fi
    echo "$nr	$abi	$name		$entry		$compat"
done

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-14-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry: Remove ABI prefixes from functions in syscall tables</title>
<updated>2020-03-21T15:03:23Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:38Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=cab56d3484d4bb8b21e4d9500392ac1ce99af026'/>
<id>urn:sha1:cab56d3484d4bb8b21e4d9500392ac1ce99af026</id>
<content type='text'>
Move the ABI prefixes to the __SYSCALL_[abi]() macros.  This allows removal
of the need to strip the prefix for UML.

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-13-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry/64: Add __SYSCALL_COMMON()</title>
<updated>2020-03-21T15:03:22Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:37Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=8210efcb153625d2bf4bb79875ddc78eee2aba3e'/>
<id>urn:sha1:8210efcb153625d2bf4bb79875ddc78eee2aba3e</id>
<content type='text'>
Add a __SYSCALL_COMMON() macro to the syscall table, which simplifies syscalltbl.sh.

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-12-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry: Remove syscall qualifier support</title>
<updated>2020-03-21T15:03:22Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:36Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=b5592e5c0d8682e0e82b42c91fd7265c3cce19e1'/>
<id>urn:sha1:b5592e5c0d8682e0e82b42c91fd7265c3cce19e1</id>
<content type='text'>
Syscall qualifier support is no longer needed.

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Dominik Brodowski &lt;linux@dominikbrodowski.net&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-11-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry/64: Remove ptregs qualifier from syscall table</title>
<updated>2020-03-21T15:03:21Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:35Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=d3b1b776eefcc1695d15730f37cdaab201fd8707'/>
<id>urn:sha1:d3b1b776eefcc1695d15730f37cdaab201fd8707</id>
<content type='text'>
Now that the fast syscall path is removed, the ptregs qualifier is unused.

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Dominik Brodowski &lt;linux@dominikbrodowski.net&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-10-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry: Move max syscall number calculation to syscallhdr.sh</title>
<updated>2020-03-21T15:03:21Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:34Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=0872098804b5f44bab91f80b6df55df32894fee3'/>
<id>urn:sha1:0872098804b5f44bab91f80b6df55df32894fee3</id>
<content type='text'>
Instead of using an array in asm-offsets to calculate the max syscall
number, calculate it when writing out the syscall headers.

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-9-brgerst@gmail.com

</content>
</entry>
<entry>
<title>x86/entry/64: Use syscall wrappers for x32_rt_sigreturn</title>
<updated>2020-03-21T15:03:20Z</updated>
<author>
<name>Brian Gerst</name>
<email>brgerst@gmail.com</email>
</author>
<published>2020-03-13T19:51:31Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=27dd84fafcd5e3c565164bb303fe8ec8ef59e147'/>
<id>urn:sha1:27dd84fafcd5e3c565164bb303fe8ec8ef59e147</id>
<content type='text'>
Add missing syscall wrapper for x32_rt_sigreturn().

Signed-off-by: Brian Gerst &lt;brgerst@gmail.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Dominik Brodowski &lt;linux@dominikbrodowski.net&gt;
Reviewed-by: Andy Lutomirski &lt;luto@kernel.org&gt;
Link: https://lkml.kernel.org/r/20200313195144.164260-6-brgerst@gmail.com

</content>
</entry>
<entry>
<title>Merge tag 'threads-v5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/brauner/linux</title>
<updated>2020-01-30T03:38:34Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2020-01-30T03:38:34Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=83fa805bcbfc53ae82eedd65132794ae324798e5'/>
<id>urn:sha1:83fa805bcbfc53ae82eedd65132794ae324798e5</id>
<content type='text'>
Pull thread management updates from Christian Brauner:
 "Sargun Dhillon over the last cycle has worked on the pidfd_getfd()
  syscall.

  This syscall allows for the retrieval of file descriptors of a process
  based on its pidfd. A task needs to have ptrace_may_access()
  permissions with PTRACE_MODE_ATTACH_REALCREDS (suggested by Oleg and
  Andy) on the target.

  One of the main use-cases is in combination with seccomp's user
  notification feature. As a reminder, seccomp's user notification
  feature was made available in v5.0. It allows a task to retrieve a
  file descriptor for its seccomp filter. The file descriptor is usually
  handed of to a more privileged supervising process. The supervisor can
  then listen for syscall events caught by the seccomp filter of the
  supervisee and perform actions in lieu of the supervisee, usually
  emulating syscalls. pidfd_getfd() is needed to expand its uses.

  There are currently two major users that wait on pidfd_getfd() and one
  future user:

   - Netflix, Sargun said, is working on a service mesh where users
     should be able to connect to a dns-based VIP. When a user connects
     to e.g. 1.2.3.4:80 that runs e.g. service "foo" they will be
     redirected to an envoy process. This service mesh uses seccomp user
     notifications and pidfd to intercept all connect calls and instead
     of connecting them to 1.2.3.4:80 connects them to e.g.
     127.0.0.1:8080.

   - LXD uses the seccomp notifier heavily to intercept and emulate
     mknod() and mount() syscalls for unprivileged containers/processes.
     With pidfd_getfd() more uses-cases e.g. bridging socket connections
     will be possible.

   - The patchset has also seen some interest from the browser corner.
     Right now, Firefox is using a SECCOMP_RET_TRAP sandbox managed by a
     broker process. In the future glibc will start blocking all signals
     during dlopen() rendering this type of sandbox impossible. Hence,
     in the future Firefox will switch to a seccomp-user-nofication
     based sandbox which also makes use of file descriptor retrieval.
     The thread for this can be found at
     https://sourceware.org/ml/libc-alpha/2019-12/msg00079.html

  With pidfd_getfd() it is e.g. possible to bridge socket connections
  for the supervisee (binding to a privileged port) and taking actions
  on file descriptors on behalf of the supervisee in general.

  Sargun's first version was using an ioctl on pidfds but various people
  pushed for it to be a proper syscall which he duely implemented as
  well over various review cycles. Selftests are of course included.
  I've also added instructions how to deal with merge conflicts below.

  There's also a small fix coming from the kernel mentee project to
  correctly annotate struct sighand_struct with __rcu to fix various
  sparse warnings. We've received a few more such fixes and even though
  they are mostly trivial I've decided to postpone them until after -rc1
  since they came in rather late and I don't want to risk introducing
  build warnings.

  Finally, there's a new prctl() command PR_{G,S}ET_IO_FLUSHER which is
  needed to avoid allocation recursions triggerable by storage drivers
  that have userspace parts that run in the IO path (e.g. dm-multipath,
  iscsi, etc). These allocation recursions deadlock the device.

  The new prctl() allows such privileged userspace components to avoid
  allocation recursions by setting the PF_MEMALLOC_NOIO and
  PF_LESS_THROTTLE flags. The patch carries the necessary acks from the
  relevant maintainers and is routed here as part of prctl()
  thread-management."

* tag 'threads-v5.6' of git://git.kernel.org/pub/scm/linux/kernel/git/brauner/linux:
  prctl: PR_{G,S}ET_IO_FLUSHER to support controlling memory reclaim
  sched.h: Annotate sighand_struct with __rcu
  test: Add test for pidfd getfd
  arch: wire up pidfd_getfd syscall
  pid: Implement pidfd_getfd syscall
  vfs, fdtable: Add fget_task helper
</content>
</entry>
</feed>
