syzbot


KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets (3)

Status: upstream: reported on 2022/02/08 08:32
Reported-by: syzbot+6ba34f16b98fe40daef1@syzkaller.appspotmail.com
First crash: 273d, last: 7h29m
similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets 15 786d 825d 0/23 closed as invalid on 2020/06/18 14:24
upstream KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets (2) 108 489d 656d 0/23 auto-closed as invalid on 2021/05/13 03:09

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

read to 0xffff888137435ac8 of 4 bytes by interrupt on cpu 1:
 wg_cpumask_next_online drivers/net/wireguard/queueing.h:129 [inline]
 wg_queue_enqueue_per_device_and_peer drivers/net/wireguard/queueing.h:176 [inline]
 wg_packet_create_data drivers/net/wireguard/send.c:320 [inline]
 wg_packet_send_staged_packets+0x68f/0xb50 drivers/net/wireguard/send.c:387
 wg_packet_send_keepalive+0xe4/0x100 drivers/net/wireguard/send.c:239
 wg_expired_send_persistent_keepalive+0x38/0x50 drivers/net/wireguard/timers.c:141
 call_timer_fn+0x2e/0x240 kernel/time/timer.c:1474
 expire_timers+0x116/0x240 kernel/time/timer.c:1519
 __run_timers+0x350/0x400 kernel/time/timer.c:1790
 run_timer_softirq+0x2e/0x60 kernel/time/timer.c:1803
 __do_softirq+0x158/0x2e3 kernel/softirq.c:571
 __irq_exit_rcu kernel/softirq.c:650 [inline]
 irq_exit_rcu+0x41/0x70 kernel/softirq.c:662
 sysvec_apic_timer_interrupt+0x8d/0xb0 arch/x86/kernel/apic/apic.c:1106
 asm_sysvec_apic_timer_interrupt+0x16/0x20
 is_atomic kernel/kcsan/core.c:258 [inline]
 should_watch kernel/kcsan/core.c:275 [inline]
 check_access kernel/kcsan/core.c:741 [inline]
 __tsan_read8+0x132/0x180 kernel/kcsan/core.c:1014
 prepend_path+0x1ed/0x670
 d_path+0x1fb/0x2c0 fs/d_path.c:290
 audit_log_d_path+0xb3/0x260 kernel/audit.c:2141
 audit_log_d_path_exe+0x3e/0x70 kernel/audit.c:2207
 audit_log_task+0x159/0x180 kernel/auditsc.c:2971
 audit_seccomp+0x64/0x120 kernel/auditsc.c:3018
 seccomp_log kernel/seccomp.c:994 [inline]
 __seccomp_filter+0xea6/0xf00 kernel/seccomp.c:1312
 __secure_computing+0x9b/0x1c0 kernel/seccomp.c:1342
 syscall_trace_enter kernel/entry/common.c:70 [inline]
 __syscall_enter_from_user_work kernel/entry/common.c:92 [inline]
 syscall_enter_from_user_mode+0xb6/0x190 kernel/entry/common.c:110
 do_syscall_64+0xc/0x70 arch/x86/entry/common.c:76
 entry_SYSCALL_64_after_hwframe+0x63/0xcd

write to 0xffff888137435ac8 of 4 bytes by interrupt on cpu 0:
 wg_cpumask_next_online drivers/net/wireguard/queueing.h:133 [inline]
 wg_queue_enqueue_per_device_and_peer drivers/net/wireguard/queueing.h:176 [inline]
 wg_packet_create_data drivers/net/wireguard/send.c:320 [inline]
 wg_packet_send_staged_packets+0x7ac/0xb50 drivers/net/wireguard/send.c:387
 wg_packet_send_keepalive+0xe4/0x100 drivers/net/wireguard/send.c:239
 wg_expired_send_persistent_keepalive+0x38/0x50 drivers/net/wireguard/timers.c:141
 call_timer_fn+0x2e/0x240 kernel/time/timer.c:1474
 expire_timers+0x116/0x240 kernel/time/timer.c:1519
 __run_timers+0x350/0x400 kernel/time/timer.c:1790
 run_timer_softirq+0x2e/0x60 kernel/time/timer.c:1803
 __do_softirq+0x158/0x2e3 kernel/softirq.c:571
 __irq_exit_rcu kernel/softirq.c:650 [inline]
 irq_exit_rcu+0x41/0x70 kernel/softirq.c:662
 sysvec_apic_timer_interrupt+0x8d/0xb0 arch/x86/kernel/apic/apic.c:1106
 asm_sysvec_apic_timer_interrupt+0x16/0x20
 get_current arch/x86/include/asm/current.h:15 [inline]
 __syscall_enter_from_user_work kernel/entry/common.c:89 [inline]
 syscall_enter_from_user_mode+0x17/0x190 kernel/entry/common.c:110
 do_syscall_64+0xc/0x70 arch/x86/entry/common.c:76
 entry_SYSCALL_64_after_hwframe+0x63/0xcd

value changed: 0x00000001 -> 0x00000000

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 17804 Comm: syz-executor.3 Not tainted 5.19.0-syzkaller-13322-gd4252071b97d-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/22/2022
==================================================================

Crashes (312):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/08/10 16:45 upstream d4252071b97d aaa9eaa0 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/09 11:12 upstream eb555cb5b794 da700653 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/09 05:21 upstream 3466f49dd0dd da700653 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/08 05:18 upstream 3bc1bc0b59d0 88e3a122 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/07 09:07 upstream 1612c382ffbd 88e3a122 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/06 15:10 upstream 6614a3c3164a 88e3a122 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/05 08:08 upstream c040862bfbd9 a65a7ce9 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/05 07:01 upstream c040862bfbd9 1c9013ac .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/04 19:07 upstream b44f2fd87919 1c9013ac .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/04 06:03 upstream ff89dd08c0f0 1c9013ac .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/03 18:41 upstream e2b542100719 1c9013ac .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/03 02:24 upstream 7d0d3fa7339e 1c9013ac .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/02 16:24 upstream 9de1f9c8ca51 fef302b1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/08/01 18:11 upstream 3d7cb6b04c3f fef302b1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/31 21:48 upstream 334c0ef6429f fef302b1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/31 15:20 upstream 6a010258447d fef302b1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/30 17:33 upstream e65c6a46df94 fef302b1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/29 10:48 upstream 6e2c0490769e fef302b1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/29 00:50 upstream 33ea1340bafe fb95c74d .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/28 05:02 upstream 6e7765cb477a fb95c74d .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/27 17:30 upstream 39c3c396f813 da9d0366 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/27 04:04 upstream 5de64d44968e ae971e66 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/26 18:12 upstream 5de64d44968e 279b89c2 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/25 12:16 upstream e0dccc3b76fb 664c519c .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/25 07:57 upstream e0dccc3b76fb 22343af4 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/23 21:54 upstream 515f71412bb7 22343af4 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/23 15:28 upstream 70664fc10c0d 22343af4 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/23 04:29 upstream 4ba1329cbb94 22343af4 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/21 11:44 upstream 353f7988dd84 6e67af9d .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/19 13:50 upstream ca85855bdcae 72a3cc0c .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/18 14:06 upstream ff6992735ade ff988920 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/18 03:37 upstream ff6992735ade 95cb00d1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/17 09:50 upstream 972a278fe60c 95cb00d1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/16 18:35 upstream c658cabbfd32 95cb00d1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/16 02:37 upstream 9b59ec8d50a1 95cb00d1 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/15 14:02 upstream e5d523f1ae8f 5d921b08 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/15 03:00 upstream 9bd572ec7a66 5d921b08 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/13 22:26 upstream 4a57a8400075 5d921b08 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/13 08:11 upstream b047602d579b 5d921b08 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/12 20:53 upstream 72a8e05d4f66 d91dd8ea .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/11 09:46 upstream 32346491ddf2 f3f217ff .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/10 19:43 upstream d9919d43cbf6 b5765a15 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/07/09 23:40 upstream b1c428b6c368 b5765a15 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/02/08 02:40 upstream 2ade8eef993c a7dab638 .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2022/01/11 04:05 upstream 133d9c53c9dc ddb0ab8c .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets
ci2-upstream-kcsan-gce 2021/11/10 04:03 upstream cb690f5238d7 55fa030c .config log report info KCSAN: data-race in wg_packet_send_staged_packets / wg_packet_send_staged_packets