linux/drivers/usb
Roy Luo 93e765523b USB: gadget: core: adjust uevent timing on gadget unbind
commit 73ea73affe 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
..
atm
c67x00
cdns3 usb: cdnsp: Fix deadlock issue during using NCM gadget 2023-12-03 07:31:25 +01:00
chipidea usb: chipidea: Simplify Tegra DMA alignment code 2023-11-20 11:08:25 +01:00
class USB: usbtmc: Fix direction for 0-length ioctl control messages 2023-05-24 17:36:52 +01:00
common usb: common: usb-conn-gpio: Prevent bailing out if initial role is none 2023-08-16 18:21:59 +02:00
core usb: config: fix iteration issue in 'usb_get_bos_descriptor()' 2023-12-08 08:48:02 +01:00
dwc2 USB: dwc2: write HCINT with INTMASK applied 2023-12-03 07:31:25 +01:00
dwc3 USB: dwc3: qcom: fix wakeup after probe deferral 2023-12-03 07:31:26 +01:00
early usb: early: xhci-dbc: Fix a potential out-of-bound memory access 2023-03-10 09:39:39 +01:00
gadget USB: gadget: core: adjust uevent timing on gadget unbind 2023-12-20 15:17:43 +01:00
host Revert "xhci: Loosen RPM as default policy to cover for AMD xHC 1.1" 2023-12-13 18:36:48 +01:00
image
isp1760
misc USB: sisusbvga: Add endpoint checks 2023-05-30 13:55:31 +01:00
mon usb: mon: make mmapped memory read only 2022-10-12 09:53:28 +02:00
mtu3 usb: mtu3: fix kernel panic at qmu transfer done irq handler 2023-05-11 23:00:33 +09:00
musb usb: musb: Modify the "HWVers" register address 2023-10-19 23:05:35 +02:00
phy usb: phy: mxs: fix getting wrong state with mxs_phy_is_otg_host() 2023-09-19 12:22:44 +02:00
renesas_usbhs usb: renesas: Fix refcount leak bug 2022-08-25 11:40:33 +02:00
roles Revert "usb: common: usb-conn-gpio: Set last role to unknown before initial detection" 2023-07-23 13:47:25 +02:00
serial USB: serial: option: don't claim interface 4 for ZTE MF290 2023-12-03 07:31:25 +01:00
storage usb: storage: set 1.50 as the lower bcdDevice for older "Super Top" compatibility 2023-11-08 17:26:49 +01:00
typec usb: typec: class: fix typec_altmode_put_partner to put plugs 2023-12-13 18:36:48 +01:00
usbip USB: usbip: fix stub_dev hub disconnect 2023-11-20 11:08:26 +01:00
Kconfig
Makefile
usb-skeleton.c