Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

USB: correct the usb_disconnect() comment about usb_bus_list_lock

usb_disconnect() no longer acquires usb_bus_list_lock, so update its
comment to that effect.

Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Bjorn Helgaas and committed by
Greg Kroah-Hartman
db8f2aa3 232275a0

+2 -2
+2 -2
drivers/usb/core/hub.c
··· 2023 2023 * Something got disconnected. Get rid of it and all of its children. 2024 2024 * 2025 2025 * If *pdev is a normal device then the parent hub must already be locked. 2026 - * If *pdev is a root hub then this routine will acquire the 2027 - * usb_bus_list_lock on behalf of the caller. 2026 + * If *pdev is a root hub then the caller must hold the usb_bus_list_lock, 2027 + * which protects the set of root hubs as well as the list of buses. 2028 2028 * 2029 2029 * Only hub drivers (including virtual root hub drivers for host 2030 2030 * controllers) should ever call this.