diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 67b798b7115d..dab550cf29c1 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h @@ -1613,7 +1613,7 @@ static inline void __skb_insert(struct sk_buff *newsk, newsk->next = next; newsk->prev = prev; next->prev = prev->next = newsk; - list->qlen++; + WRITE_ONCE(list->qlen, list->qlen + 1); } static inline void __skb_queue_splice(const struct sk_buff_head *list, diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c index bfdfb958a37d..2c643e1919aa 100644 --- a/net/unix/af_unix.c +++ b/net/unix/af_unix.c @@ -2694,7 +2694,7 @@ static unsigned int unix_dgram_poll(struct file *file, struct socket *sock, other = unix_peer(sk); if (other && unix_peer(other) != sk && - unix_recvq_full(other) && + unix_recvq_full_lockless(other) && unix_dgram_peer_wake_me(sk, other)) writable = 0;