[PATCH] net: tun: unlink NAPI from device on destruction

0 views
Skip to first unread message

Tadeusz Struk

unread,
Jul 11, 2022, 5:21:49 PM7/11/22
to syzbot+e559f1...@syzkaller.appspotmail.com, syzkaller-a...@googlegroups.com, tadeus...@linaro.org
#syz test: https://android.googlesource.com/kernel/common android12-5.10-lts

diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index 55ce141c93c7..aa8ee7542c3c 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -733,6 +733,7 @@ static void tun_detach_all(struct net_device *dev)
sock_put(&tfile->sk);
}
list_for_each_entry_safe(tfile, tmp, &tun->disabled, next) {
+ tun_napi_del(tfile);
tun_enable_queue(tfile);
tun_queue_purge(tfile);
xdp_rxq_info_unreg(&tfile->xdp_rxq);
--
2.36.1

syzbot

unread,
Jul 11, 2022, 5:38:13 PM7/11/22
to syzkaller-a...@googlegroups.com, tadeus...@linaro.org
Hello,

syzbot has tested the proposed patch and the reproducer did not trigger any issue:

Reported-and-tested-by: syzbot+e559f1...@syzkaller.appspotmail.com

Tested on:

commit: fa7f6a5f Merge branch 'android12-5.10' into branch 'an..
git tree: android12-5.10-lts
console output: https://syzkaller.appspot.com/x/log.txt?x=11216f14080000
kernel config: https://syzkaller.appspot.com/x/.config?x=70868d9099c5eaf8
dashboard link: https://syzkaller.appspot.com/bug?extid=e559f12bb7b41ef21d10
compiler: Debian clang version 13.0.1-++20220126092033+75e33f71c2da-1~exp1~20220126212112.63, GNU ld (GNU Binutils for Debian) 2.35.2
patch: https://syzkaller.appspot.com/x/patch.diff?x=14f59a2c080000

Note: testing is done by a robot and is best-effort only.
Reply all
Reply to author
Forward
0 new messages