syzbot


KCSAN: data-race in mon_reader_add / usb_hcd_submit_urb (2)

Status: moderation: reported on 2024/11/15 14:33
Subsystems: usb
[Documentation on labels]
Reported-by: syzbot+37dc0d721a7736c61b72@syzkaller.appspotmail.com
First crash: 2d11h, last: 2d11h
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in mon_reader_add / usb_hcd_submit_urb usb 1 247d 247d 0/28 auto-obsoleted due to no activity on 2024/04/19 22:45

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

write to 0xffff8881020e6088 of 4 bytes by task 8854 on cpu 0:
 mon_reader_add+0xc7/0x1f0 drivers/usb/mon/mon_main.c:47
 mon_bin_open+0x32b/0x3b0 drivers/usb/mon/mon_bin.c:720
 chrdev_open+0x2f9/0x370 fs/char_dev.c:414
 do_dentry_open+0x621/0xa20 fs/open.c:958
 vfs_open+0x38/0x1f0 fs/open.c:1088
 do_open fs/namei.c:3774 [inline]
 path_openat+0x1ac2/0x1fa0 fs/namei.c:3933
 do_filp_open+0xf7/0x200 fs/namei.c:3960
 do_sys_openat2+0xab/0x120 fs/open.c:1415
 do_sys_open fs/open.c:1430 [inline]
 __do_sys_openat fs/open.c:1446 [inline]
 __se_sys_openat fs/open.c:1441 [inline]
 __x64_sys_openat+0xf3/0x120 fs/open.c:1441
 x64_sys_call+0x1025/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:258
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff8881020e6088 of 4 bytes by task 3587 on cpu 1:
 usbmon_urb_submit include/linux/usb/hcd.h:723 [inline]
 usb_hcd_submit_urb+0x86/0x1510 drivers/usb/core/hcd.c:1518
 usb_submit_urb+0xa80/0xb70 drivers/usb/core/urb.c:581
 usb_start_wait_urb+0x91/0x190 drivers/usb/core/message.c:59
 usb_internal_control_msg drivers/usb/core/message.c:103 [inline]
 usb_control_msg+0x182/0x240 drivers/usb/core/message.c:154
 get_port_status drivers/usb/core/hub.c:604 [inline]
 hub_ext_port_status+0xbf/0x480 drivers/usb/core/hub.c:621
 usb_hub_port_status drivers/usb/core/hub.c:671 [inline]
 port_event drivers/usb/core/hub.c:5714 [inline]
 hub_event+0x538/0x2910 drivers/usb/core/hub.c:5903
 process_one_work kernel/workqueue.c:3229 [inline]
 process_scheduled_works+0x483/0x9a0 kernel/workqueue.c:3310
 worker_thread+0x51d/0x6f0 kernel/workqueue.c:3391
 kthread+0x1d1/0x210 kernel/kthread.c:389
 ret_from_fork+0x4b/0x60 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244

value changed: 0x00000000 -> 0x00000001

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 3587 Comm: kworker/1:6 Not tainted 6.12.0-rc7-syzkaller-00125-gcfaaa7d010d1 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
Workqueue: usb_hub_wq hub_event
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/11/15 14:33 upstream cfaaa7d010d1 f6ede3a3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in mon_reader_add / usb_hcd_submit_urb
* Struck through repros no longer work on HEAD.