syzbot


KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit (3)

Status: auto-closed as invalid on 2022/03/31 01:27
Subsystems: net
[Documentation on labels]
First crash: 792d, last: 792d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit (2) net 1 869d 869d 0/26 auto-closed as invalid on 2022/01/12 10:33
upstream KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit net 9 1117d 1214d 0/26 auto-closed as invalid on 2021/05/17 09:01
upstream KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit (5) net 3 632d 646d 0/26 auto-closed as invalid on 2022/09/06 23:19
upstream KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit (4) net 2 696d 730d 0/26 auto-closed as invalid on 2022/07/04 07:46

Sample crash report:
batman_adv: batadv0: Interface activated: batadv_slave_1
==================================================================
BUG: KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit

write to 0xffffe8ffffd3ded8 of 8 bytes by task 4558 on cpu 1:
 iptunnel_xmit_stats include/net/ip_tunnels.h:452 [inline]
 iptunnel_xmit+0x3e1/0x4f0 net/ipv4/ip_tunnel_core.c:87
 udp_tunnel_xmit_skb+0x16f/0x180 net/ipv4/udp_tunnel_core.c:171
 send4+0x4d2/0x510 drivers/net/wireguard/socket.c:85
 wg_socket_send_skb_to_peer+0x92/0x130 drivers/net/wireguard/socket.c:174
 wg_socket_send_buffer_to_peer+0xf7/0x120 drivers/net/wireguard/socket.c:199
 wg_packet_send_handshake_initiation drivers/net/wireguard/send.c:40 [inline]
 wg_packet_handshake_send_worker+0x109/0x150 drivers/net/wireguard/send.c:51
 process_one_work+0x3f6/0x960 kernel/workqueue.c:2307
 worker_thread+0x616/0xa70 kernel/workqueue.c:2454
 kthread+0x1bf/0x1e0 kernel/kthread.c:377
 ret_from_fork+0x1f/0x30

read to 0xffffe8ffffd3ded8 of 8 bytes by task 17708 on cpu 0:
 dev_fetch_sw_netstats net/core/dev.c:10059 [inline]
 dev_get_tstats64+0x149/0x1e0 net/core/dev.c:10081
 dev_get_stats+0x65/0x180 net/core/dev.c:10023
 rtnl_fill_stats+0x45/0x320 net/core/rtnetlink.c:1203
 rtnl_fill_ifinfo+0xf1e/0x25c0 net/core/rtnetlink.c:1778
 rtmsg_ifinfo_build_skb+0xa8/0x130 net/core/rtnetlink.c:3837
 rtmsg_ifinfo_event net/core/rtnetlink.c:3869 [inline]
 rtmsg_ifinfo+0x58/0xc0 net/core/rtnetlink.c:3878
 __dev_notify_flags+0x63/0x3b0 net/core/dev.c:8173
 dev_change_flags+0xa2/0xc0 net/core/dev.c:8215
 do_setlink+0x820/0x2500 net/core/rtnetlink.c:2731
 __rtnl_newlink net/core/rtnetlink.c:3416 [inline]
 rtnl_newlink+0xfeb/0x13e0 net/core/rtnetlink.c:3531
 rtnetlink_rcv_msg+0x745/0x7e0 net/core/rtnetlink.c:5596
 netlink_rcv_skb+0x14e/0x250 net/netlink/af_netlink.c:2494
 rtnetlink_rcv+0x18/0x20 net/core/rtnetlink.c:5614
 netlink_unicast_kernel net/netlink/af_netlink.c:1317 [inline]
 netlink_unicast+0x602/0x6d0 net/netlink/af_netlink.c:1343
 netlink_sendmsg+0x728/0x850 net/netlink/af_netlink.c:1919
 sock_sendmsg_nosec net/socket.c:705 [inline]
 sock_sendmsg net/socket.c:725 [inline]
 __sys_sendto+0x21e/0x2c0 net/socket.c:2040
 __do_sys_sendto net/socket.c:2052 [inline]
 __se_sys_sendto net/socket.c:2048 [inline]
 __x64_sys_sendto+0x74/0x90 net/socket.c:2048
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0x0000000000000000 -> 0x0000000000000094

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 17708 Comm: syz-executor.1 Not tainted 5.17.0-rc5-syzkaller-00021-g23d04328444a-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/02/24 01:20 upstream 23d04328444a 6e821dbf .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit
2022/02/23 06:58 upstream 917bbdb107f8 6e821dbf .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in dev_get_tstats64 / iptunnel_xmit
* Struck through repros no longer work on HEAD.