Re: [syzbot] [bpf?] [net?] WARNING in sock_map_close (2)

From: Hillf Danton
Date: Fri Aug 23 2024 - 06:48:00 EST


On Thu, 22 Aug 2024 06:19:27 -0700
> syzbot found the following issue on:
>
> HEAD commit: d785ed945de6 net: wwan: t7xx: PCIe reset rescan
> git tree: net-next
> C reproducer: https://syzkaller.appspot.com/x/repro.c?x=12378c33980000

#syz test net-next d785ed945de6

--- x/net/core/skmsg.c
+++ y/net/core/skmsg.c
@@ -728,6 +728,7 @@ struct sk_psock *sk_psock_init(struct so
psock->saved_unhash = prot->unhash;
psock->saved_destroy = prot->destroy;
psock->saved_close = prot->close;
+ BUG_ON(psock->saved_close == sock_map_close);
psock->saved_write_space = sk->sk_write_space;

INIT_LIST_HEAD(&psock->link);
--