Re: [PATCH] usb: atm: ueagle-atm: use synchronous request_firmware()
From: Mauricio Faria de Oliveira
Date: Fri May 22 2026 - 13:05:26 EST
On 2026-05-18 12:54, Mauricio Faria de Oliveira wrote:
> On 2026-05-16 06:19, Stanislaw Gruszka wrote:
>> I prefer not to change this. If synchronization with disconnect
>> is required, I would rather keep request_firmware_nowait() and add
>> explicit completion handling. Andrey some time ago posted a patch
>> for this:
>> https://lore.kernel.org/lkml/20250410093146.3776801-1-aitsygunka@xxxxxxxxx/
>>
>> I refused the patch because it appears to only avoid pr_debug, but if
>> it fixes actual problem, we can take it.
>
> Ok, I found it earlier, but opted otherwise as I missed the rationale.
>
> I'll be happy to check it for resending; I had a slightly different
> implementation in mind when I considered a similar approach (using a
> struct completion in the existing data structure), but I'll double check
> it whether it's doable, and get back to you.
v2:
https://lore.kernel.org/all/20260522-ueagle-atm_req-fw-sync-v2-1-eee7f6b823a7@xxxxxxxxxx/
This uses just struct usb_interface instead of a new structure, with
intfdata for struct completion and interface_to_usbdev() for struct
usb_device.
Also, use a condition check for pre-firmware devices in .disconnect(),
as IIUIC just 'else' could match interfaces != 0 on non pre-firmware
devices (i.e., bNumInterfaces != 1 && ifnum != 0).
Kind regards,
--
Mauricio