Re: [PATCH net-next v2] ch9200: do return USB errors from control_write()
From: Jakub Kicinski
Date: Fri Sep 18 2026 - 21:22:26 EST
On Wed, 16 Sep 2026 19:21:04 +0300 Sergey Shtylyov wrote:
> > There is a second point about the resulting contract. On success
> > usb_control_msg() returns the transferred length, so control_write() now
> > returns a positive value (2 for these register writes) rather than 0:
> >
> > err = usb_control_msg(dev->udev, ...);
> > if (err >= 0 && err < size)
> > err = -EINVAL;
> >
> > Would the obvious caller-side follow-up "if (retval) return retval;" then
> > treat every successful 2-byte register write as a failure? Would it be
> > better to normalize success to 0 in control_write(), or to check
> > "retval < 0" in each caller and update the callers in the same patch so
> > the errors being returned are actually acted upon?
> That's what the patch I linked to does...
Please fix the issues in one series or not at all.
We have too many patches in flight these days to be chasing people's
linked series. Too many LLM-happy "helpers".
Please explain how you discovered the issue and how you tested the fix.