Re: [PATCH net-next v2] ch9200: do return USB errors from control_write()
From: Andrew Lunn
Date: Tue Sep 15 2026 - 17:54:39 EST
On Tue, Sep 15, 2026 at 09:58:04PM +0300, Sergey Shtylyov wrote:
> Compared with control_read(), control_write() looks really strange:
> it ignores any errors returned by usb_control_msg(), always returning
> 0 instead, despite overriding a positive result of usb_control_msg()
> (indicating short transfer) to -EINVAL before doing that. Drop that
> dubious *return* and propagate USB errors to the callers...
>
> Signed-off-by: Sergey Shtylyov <s.shtylyov@xxxxxxxxxxxx>
Reviewed-by: Andrew Lunn <andrew@xxxxxxx>
Andrew