syzbot


KCSAN: data-race in detach_if_pending / mod_timer

Status: auto-closed as invalid on 2020/01/16 15:24
Subsystems: net
[Documentation on labels]
First crash: 1624d, last: 1624d

Sample crash report:
==================================================================
BUG: KCSAN: data-race in detach_if_pending / mod_timer

read to 0xffff88812499ad30 of 8 bytes by task 7987 on cpu 0:
 __mod_timer kernel/time/timer.c:963 [inline]
 mod_timer+0x59/0x7a0 kernel/time/timer.c:1100
 sk_reset_timer+0x2d/0x70 net/core/sock.c:2842
 inet_csk_reset_xmit_timer include/net/inet_connection_sock.h:234 [inline]
 tcp_reset_xmit_timer include/net/tcp.h:1279 [inline]
 tcp_schedule_loss_probe net/ipv4/tcp_output.c:2519 [inline]
 tcp_schedule_loss_probe+0x2ef/0x390 net/ipv4/tcp_output.c:2475
 tcp_write_xmit+0xe6f/0x3120 net/ipv4/tcp_output.c:2467
 __tcp_push_pending_frames+0x7b/0x1d0 net/ipv4/tcp_output.c:2616
 tcp_push+0x1e9/0x3d0 net/ipv4/tcp.c:726
 tcp_sendmsg_locked+0x1d2b/0x1fb0 net/ipv4/tcp.c:1405
 tcp_sendmsg+0x39/0x60 net/ipv4/tcp.c:1436
 inet_sendmsg+0x6d/0x90 net/ipv4/af_inet.c:807
 sock_sendmsg_nosec net/socket.c:637 [inline]
 sock_sendmsg+0x9f/0xc0 net/socket.c:657
 sock_write_iter+0x16b/0x210 net/socket.c:989
 call_write_iter include/linux/fs.h:1895 [inline]
 new_sync_write+0x388/0x4a0 fs/read_write.c:483
 __vfs_write+0xb1/0xc0 fs/read_write.c:496
 vfs_write fs/read_write.c:558 [inline]
 vfs_write+0x18a/0x390 fs/read_write.c:542
 ksys_write+0xd5/0x1b0 fs/read_write.c:611
 __do_sys_write fs/read_write.c:623 [inline]
 __se_sys_write fs/read_write.c:620 [inline]
 __x64_sys_write+0x4c/0x60 fs/read_write.c:620
 do_syscall_64+0xcc/0x370 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

write to 0xffff88812499ad30 of 8 bytes by task 8003 on cpu 1:
 __hlist_del include/linux/list.h:764 [inline]
 detach_timer kernel/time/timer.c:815 [inline]
 detach_if_pending+0xcd/0x290 kernel/time/timer.c:832
 __mod_timer kernel/time/timer.c:1012 [inline]
 mod_timer+0x141/0x7a0 kernel/time/timer.c:1100
 sk_reset_timer+0x2d/0x70 net/core/sock.c:2842
 inet_csk_reset_xmit_timer include/net/inet_connection_sock.h:234 [inline]
 tcp_reset_xmit_timer include/net/tcp.h:1279 [inline]
 tcp_schedule_loss_probe net/ipv4/tcp_output.c:2519 [inline]
 tcp_schedule_loss_probe+0x2ef/0x390 net/ipv4/tcp_output.c:2475
 tcp_write_xmit+0xe6f/0x3120 net/ipv4/tcp_output.c:2467
 __tcp_push_pending_frames+0x7b/0x1d0 net/ipv4/tcp_output.c:2616
 tcp_push+0x1e9/0x3d0 net/ipv4/tcp.c:726
 tcp_sendmsg_locked+0x1d2b/0x1fb0 net/ipv4/tcp.c:1405
 tcp_sendmsg+0x39/0x60 net/ipv4/tcp.c:1436
 inet_sendmsg+0x6d/0x90 net/ipv4/af_inet.c:807
 sock_sendmsg_nosec net/socket.c:637 [inline]
 sock_sendmsg+0x9f/0xc0 net/socket.c:657
 sock_write_iter+0x16b/0x210 net/socket.c:989
 call_write_iter include/linux/fs.h:1895 [inline]
 new_sync_write+0x388/0x4a0 fs/read_write.c:483
 __vfs_write+0xb1/0xc0 fs/read_write.c:496
 vfs_write fs/read_write.c:558 [inline]
 vfs_write+0x18a/0x390 fs/read_write.c:542
 ksys_write+0xd5/0x1b0 fs/read_write.c:611
 __do_sys_write fs/read_write.c:623 [inline]
 __se_sys_write fs/read_write.c:620 [inline]
 __x64_sys_write+0x4c/0x60 fs/read_write.c:620
 do_syscall_64+0xcc/0x370 arch/x86/entry/common.c:290
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 8003 Comm: syz-fuzzer Not tainted 5.4.0-rc6+ #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/11/07 15:14 https://github.com/google/ktsan.git kcsan 94c006602e13 d5bc6812 .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.