Re: [PATCH] media: imon: make send_packet() more robust

From: Sean Young
Date: Wed Jul 16 2025 - 08:47:41 EST


On Wed, Jul 16, 2025 at 07:09:51PM +0900, Tetsuo Handa wrote:
> On 2025/07/16 18:38, Sean Young wrote:
> > On Tue, Jul 15, 2025 at 09:30:02PM -0400, Alan Stern wrote:
> >> On Tue, Jul 15, 2025 at 09:19:18PM +0100, Sean Young wrote:
> >>> I think that is why this driver code is so awkward.
> >>
> >> That's what usb_driver_claim_interface() is for. IIRC, the cdc-acm
> >> driver uses it in exactly this way.
> >
> > Very interesting, we should look at re-writing this driver. Note this
> > function is not documented in Documentation/driver-api/usb/
>
> OK. Then, what do you want to do for this syzbot report?
> If you want to apply this patch, I'll send an updated patch with Alan's comment.
> If you want to directly rewrite this module, this patch will be discarded.

Let's apply your updated patch. It looks good. I've started looking at
re-writing the driver to use usb_driver_claim_interface(), but I don't
know when that will be ready (or if it'll work).

Thanks,

Sean