BTW, since the patch doesn't touch the xHCI driver, the Subject: shouldn't say "usb: xhci: ...". It would be better to put "usb: hub: ..."
On Thu, Feb 27, 2025 at 07:05:17AM +0000, Pawel Laszczak wrote:
Doing it this way, you will call hcd->driver->reset_device() multiple times for the same device: once for the hub(s) above the device and then once for the device itself. But since this isn't a hot path, maybe that doesn't matter.
Yes, it true but the function xhci_discover_or_reset_device which is associated with hcd->driver->reset_device() include the checking whether device is in SLOT_STATE_DISABLED. It allows to detect whether device has been already reset and do not repeat the reset procedure.
Okay. Please resubmit the patch with the changes we discussed (and fix the kerneldoc problem pointed out by the kernel build checker).
Alan Stern