aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tools/perf/scripts/python/task-analyzer.py
diff options
context:
space:
mode:
authorKuniyuki Iwashima <kuniyu@amazon.com>2025-05-19 13:57:57 -0700
committerDavid S. Miller <davem@davemloft.net>2025-05-23 10:24:18 +0100
commit0e81cfd971dc4833c699dcd8924e54a5021bc4e8 (patch)
treeeb5b153ec0f25f1f52b20f818edce78a93154c15 /tools/perf/scripts/python/task-analyzer.py
parentnet: Restrict SO_PASS{CRED,PIDFD,SEC} to AF_{UNIX,NETLINK,BLUETOOTH}. (diff)
downloadwireguard-linux-0e81cfd971dc4833c699dcd8924e54a5021bc4e8.tar.xz
wireguard-linux-0e81cfd971dc4833c699dcd8924e54a5021bc4e8.zip
af_unix: Move SOCK_PASS{CRED,PIDFD,SEC} to struct sock.
As explained in the next patch, SO_PASSRIGHTS would have a problem if we assigned a corresponding bit to socket->flags, so it must be managed in struct sock. Mixing socket->flags and sk->sk_flags for similar options will look confusing, and sk->sk_flags does not have enough space on 32bit system. Also, as mentioned in commit 16e572626961 ("af_unix: dont send SCM_CREDENTIALS by default"), SOCK_PASSCRED and SOCK_PASSPID handling is known to be slow, and managing the flags in struct socket cannot avoid that for embryo sockets. Let's move SOCK_PASS{CRED,PIDFD,SEC} to struct sock. While at it, other SOCK_XXX flags in net.h are grouped as enum. Note that assign_bit() was atomic, so the writer side is moved down after lock_sock() in setsockopt(), but the bit is only read once in sendmsg() and recvmsg(), so lock_sock() is not needed there. Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com> Reviewed-by: Willem de Bruijn <willemb@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/task-analyzer.py')
0 files changed, 0 insertions, 0 deletions