linux/Documentation/driver-api/usb
Michal Pecio 9f2a3933be USB: document some API requirements on disconnection
A call to usb_set_interface() crashes if the device is deallocated
concurrently, such as due to physical removal or a serious IO error.
It could also interfere with other drivers using the device if the
current driver is unbound before the call is finished.

Document the need to delay driver unbinding until this call returns,
which solves both issues.

Document the same regarding usb_clear_halt(), which is equally known
to be routinely called by drivers.

Explicitly mention finishing pending operations in the documentation
of the driver disconnect callback.

Signed-off-by: Michal Pecio <michal.pecio@gmail.com>
Link: https://lore.kernel.org/r/20240218092515.7635ff8c@foxbook
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-03-02 20:37:14 +01:00
..
anchors.rst
bulk-streams.rst
callbacks.rst USB: document some API requirements on disconnection 2024-03-02 20:37:14 +01:00
dma.rst docs: driver-api: usb: update dma info 2023-10-05 09:35:12 +02:00
dwc3.rst Documentation: driver-api: correct spelling 2023-02-02 11:05:16 -07:00
error-codes.rst
gadget.rst
hotplug.rst
index.rst
persist.rst
power-management.rst
typec.rst
typec_bus.rst
URB.rst
usb.rst USB: Remove Wireless USB and UWB documentation 2023-08-09 14:17:32 +02:00
usb3-debug-port.rst Documentation: driver-api: correct spelling 2023-02-02 11:05:16 -07:00
writing_musb_glue_layer.rst
writing_usb_driver.rst Docs: usb: update writesize, copy_from_user, usb_fill_bulk_urb, usb_submit_urb 2021-11-17 14:54:58 +01:00