From: Paolo Abeni Date: Thu, 6 Jun 2024 10:57:17 +0000 (+0200) Subject: Merge branch 'af_unix-fix-lockless-access-of-sk-sk_state-and-others-fields' X-Git-Tag: v6.10-rc3~27^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=411c0ea696cc4fcd14a32f2093c909e0c59c5dd7;p=thirdparty%2Fkernel%2Flinux.git Merge branch 'af_unix-fix-lockless-access-of-sk-sk_state-and-others-fields' Kuniyuki Iwashima says: ==================== af_unix: Fix lockless access of sk->sk_state and others fields. The patch 1 fixes a bug where SOCK_DGRAM's sk->sk_state is changed to TCP_CLOSE even if the socket is connect()ed to another socket. The rest of this series annotates lockless accesses to the following fields. * sk->sk_state * sk->sk_sndbuf * net->unx.sysctl_max_dgram_qlen * sk->sk_receive_queue.qlen * sk->sk_shutdown Note that with this series there is skb_queue_empty() left in unix_dgram_disconnected() that needs to be changed to lockless version, and unix_peer(other) access there should be protected by unix_state_lock(). This will require some refactoring, so another series will follow. Changes: v2: * Patch 1: Fix wrong double lock v1: https://lore.kernel.org/netdev/20240603143231.62085-1-kuniyu@amazon.com/ ==================== Link: https://lore.kernel.org/r/20240604165241.44758-1-kuniyu@amazon.com Signed-off-by: Paolo Abeni --- 411c0ea696cc4fcd14a32f2093c909e0c59c5dd7