WSL2-Linux-Kernel/drivers/usb/gadget
Roy Luo 93e765523b USB: gadget: core: adjust uevent timing on gadget unbind
commit 73ea73affe8622bdf292de898da869d441da6a9d upstream.

The KOBJ_CHANGE uevent is sent before gadget unbind is actually
executed, resulting in inaccurate uevent emitted at incorrect timing
(the uevent would have USB_UDC_DRIVER variable set while it would
soon be removed).
Move the KOBJ_CHANGE uevent to the end of the unbind function so that
uevent is sent only after the change has been made.

Fixes: 2ccea03a8f ("usb: gadget: introduce UDC Class")
Cc: stable@vger.kernel.org
Signed-off-by: Roy Luo <royluo@google.com>
Link: https://lore.kernel.org/r/20231128221756.2591158-1-royluo@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-12-20 15:17:43 +01:00
..
function usb: gadget: f_hid: fix report descriptor allocation 2023-12-13 18:36:48 +01:00
legacy usb: raw-gadget: properly handle interrupted requests 2023-11-08 17:26:50 +01:00
udc USB: gadget: core: adjust uevent timing on gadget unbind 2023-12-20 15:17:43 +01:00
Kconfig
Makefile
composite.c usb: gadget: call usb_gadget_check_config() to verify UDC capability 2023-08-03 10:22:40 +02:00
config.c
configfs.c usb: gadget: Properly configure the device for remote wakeup 2023-05-30 13:55:29 +01:00
configfs.h
epautoconf.c
functions.c
u_f.c
u_f.h
u_os_desc.h
usbstring.c