mirror-linux/drivers/usb
Roy Luo 69540c108d 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>
2023-12-13 18:39:28 +01:00
..
atm
c67x00
cdns3 usb: cdnsp: Fix deadlock issue during using NCM gadget 2023-12-03 07:32:12 +01:00
chipidea usb: chipidea: Simplify Tegra DMA alignment code 2023-11-20 11:52:10 +01:00
class USB: usbtmc: Fix direction for 0-length ioctl control messages 2023-05-24 17:32:48 +01:00
common usb: common: usb-conn-gpio: Prevent bailing out if initial role is none 2023-08-16 18:27:24 +02:00
core usb: config: fix iteration issue in 'usb_get_bos_descriptor()' 2023-12-08 08:51:17 +01:00
dwc2 USB: dwc2: write HCINT with INTMASK applied 2023-12-03 07:32:12 +01:00
dwc3 USB: dwc3: qcom: fix wakeup after probe deferral 2023-12-03 07:32:13 +01:00
early
gadget USB: gadget: core: adjust uevent timing on gadget unbind 2023-12-13 18:39:28 +01:00
host Revert "xhci: Loosen RPM as default policy to cover for AMD xHC 1.1" 2023-12-13 18:39:27 +01:00
image
isp1760
misc usb: misc: onboard_hub: add support for Microchip USB2412 USB 2.0 hub 2023-10-25 12:03:08 +02:00
mon
mtu3
musb usb: musb: Modify the "HWVers" register address 2023-10-19 23:08:55 +02:00
phy usb: phy: mxs: fix getting wrong state with mxs_phy_is_otg_host() 2023-09-13 09:42:51 +02:00
renesas_usbhs
roles Revert "usb: common: usb-conn-gpio: Set last role to unknown before initial detection" 2023-07-19 16:21:56 +02:00
serial USB: serial: option: don't claim interface 4 for ZTE MF290 2023-12-03 07:32:12 +01:00
storage usb: storage: set 1.50 as the lower bcdDevice for older "Super Top" compatibility 2023-11-08 14:11:03 +01:00
typec usb: typec: class: fix typec_altmode_put_partner to put plugs 2023-12-13 18:39:27 +01:00
usbip USB: usbip: fix stub_dev hub disconnect 2023-11-20 11:52:10 +01:00
Kconfig
Makefile
usb-skeleton.c