Re: [PATCH] gpio: mpsse: drop redundant device reference

From: Linus Walleij

Date: Sun Mar 08 2026 - 19:41:28 EST


On Thu, Mar 5, 2026 at 1:49 PM Johan Hovold <johan@xxxxxxxxxx> wrote:

> Driver core holds a reference to the USB interface and its parent USB
> device while the interface is bound to a driver and there is no need to
> take additional references unless the structures are needed after
> disconnect.
>
> Drop the redundant device reference to reduce cargo culting, make it
> easier to spot drivers where an extra reference is needed, and reduce
> the risk of memory leaks when drivers fail to release it.
>
> Signed-off-by: Johan Hovold <johan@xxxxxxxxxx>

Looks right to me.
Reviewed-by: Linus Walleij <linusw@xxxxxxxxxx>

Yours,
Linus Walleij