linux/drivers/usb/usbip
Shuah Khan 363eaa3a45 usbip: synchronize event handler with sysfs code paths
Fuzzing uncovered race condition between sysfs code paths in usbip
drivers. Device connect/disconnect code paths initiated through
sysfs interface are prone to races if disconnect happens during
connect and vice versa.

Use sysfs_lock to synchronize event handler with sysfs paths
in usbip drivers.

Cc: stable@vger.kernel.org
Reported-and-tested-by: syzbot+a93fba6d384346a761e3@syzkaller.appspotmail.com
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Link: https://lore.kernel.org/r/c5c8723d3f29dfe3d759cfaafa7dd16b0dfe2918.1616807117.git.skhan@linuxfoundation.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-04-05 09:05:42 +02:00
..
Kconfig
Makefile
stub_dev.c usbip: stub-dev synchronize sysfs code paths 2021-04-05 09:05:42 +02:00
stub_main.c usb: usbip: Use DEFINE_SPINLOCK() for spinlock 2021-01-07 14:34:24 +01:00
stub_rx.c usbip: Use fallthrough pseudo-keyword 2020-07-09 18:06:35 +02:00
stub_tx.c
stub.h
usbip_common.c usbip: Remove in_interrupt() check 2020-10-28 13:06:06 +01:00
usbip_common.h usbip: add sysfs_lock to synchronize sysfs code paths 2021-04-05 09:05:42 +02:00
usbip_event.c usbip: synchronize event handler with sysfs code paths 2021-04-05 09:05:42 +02:00
vhci_hcd.c usbip: add sysfs_lock to synchronize sysfs code paths 2021-04-05 09:05:42 +02:00
vhci_rx.c kcov, usbip: collect coverage from vhci_rx_loop 2020-12-28 15:48:36 +01:00
vhci_sysfs.c usbip: add sysfs_lock to synchronize sysfs code paths 2021-04-05 09:05:42 +02:00
vhci_tx.c
vhci.h
vudc_dev.c usbip: vudc synchronize sysfs code paths 2021-04-05 09:05:42 +02:00
vudc_main.c
vudc_rx.c
vudc_sysfs.c usbip: vudc synchronize sysfs code paths 2021-04-05 09:05:42 +02:00
vudc_transfer.c usbip: Use fallthrough pseudo-keyword 2020-07-09 18:06:35 +02:00
vudc_tx.c
vudc.h