syzbot


KCSAN: data-race in hcd_bus_suspend / vhci_hub_status

Status: auto-obsoleted due to no activity on 2023/09/24 21:12
Subsystems: usb
[Documentation on labels]
First crash: 734d, last: 734d

Sample crash report:
vhci_hcd vhci_hcd.0: pdev(2) rhport(1) sockfd(8)
vhci_hcd vhci_hcd.0: devid(0) speed(1) speed_str(low-speed)
==================================================================
BUG: KCSAN: data-race in hcd_bus_suspend / vhci_hub_status

write to 0xffff888103317250 of 4 bytes by task 2528 on cpu 0:
 hcd_bus_suspend+0xc1/0x2c0 drivers/usb/core/hcd.c:2283
 usb_generic_driver_suspend+0x55/0xd0 drivers/usb/core/generic.c:275
 usb_suspend_device drivers/usb/core/driver.c:1252 [inline]
 usb_suspend_both+0x2a8/0x980 drivers/usb/core/driver.c:1423
 usb_runtime_suspend+0x4a/0xd0 drivers/usb/core/driver.c:1952
 __rpm_callback+0x296/0x720 drivers/base/power/runtime.c:392
 rpm_callback drivers/base/power/runtime.c:446 [inline]
 rpm_suspend+0x79f/0x1260 drivers/base/power/runtime.c:670
 __pm_runtime_suspend+0xf1/0x200 drivers/base/power/runtime.c:1140
 pm_runtime_put_sync_autosuspend include/linux/pm_runtime.h:526 [inline]
 usb_autosuspend_device+0x40/0x50 drivers/usb/core/driver.c:1677
 usb_remote_wakeup+0x79/0x90 drivers/usb/core/hub.c:3802
 hcd_resume_work+0x25/0x30 drivers/usb/core/hcd.c:2393
 process_one_work+0x434/0x860 kernel/workqueue.c:2600
 worker_thread+0x5f2/0xa10 kernel/workqueue.c:2751
 kthread+0x1d7/0x210 kernel/kthread.c:389
 ret_from_fork+0x2e/0x40 arch/x86/kernel/process.c:145
 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:304

read to 0xffff888103317250 of 4 bytes by task 4145 on cpu 1:
 vhci_hub_status+0x312/0x3f0 drivers/usb/usbip/vhci_hcd.c:256
 usb_hcd_poll_rh_status+0xca/0x360 drivers/usb/core/hcd.c:765
 rh_port_connect+0xdd/0xf0 drivers/usb/usbip/vhci_hcd.c:184
 attach_store+0x609/0x6c0 drivers/usb/usbip/vhci_sysfs.c:436
 dev_attr_store+0x44/0x60 drivers/base/core.c:2365
 sysfs_kf_write+0xaa/0xc0 fs/sysfs/file.c:136
 kernfs_fop_write_iter+0x1ca/0x2b0 fs/kernfs/file.c:334
 call_write_iter include/linux/fs.h:1877 [inline]
 new_sync_write fs/read_write.c:491 [inline]
 vfs_write+0x4ab/0x7d0 fs/read_write.c:584
 ksys_write+0xeb/0x1a0 fs/read_write.c:637
 __do_sys_write fs/read_write.c:649 [inline]
 __se_sys_write fs/read_write.c:646 [inline]
 __x64_sys_write+0x42/0x50 fs/read_write.c:646
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd

value changed: 0x00000001 -> 0x00000085

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 4145 Comm: syz-executor.2 Not tainted 6.5.0-rc7-syzkaller-g706a74159504 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
==================================================================
vhci_hcd vhci_hcd.0: Device attached

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/08/20 21:10 upstream 706a74159504 d216d8a0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in hcd_bus_suspend / vhci_hub_status
* Struck through repros no longer work on HEAD.