Re: [PATCH 2/2] usb: misc: onboard_hub: add support for XMOS XVF3500

From: Greg Kroah-Hartman
Date: Tue Jan 30 2024 - 11:36:25 EST


On Tue, Jan 30, 2024 at 04:11:29PM +0000, Matthias Kaehlcke wrote:
> Hi Javier,
>
> I understand your motivation for using the onboard_usb_hub driver
> for powering up a non-hub device, it feels a bit hacky to use it
> as is though. Re-using the driver might be the right thing to do,
> but then it should probably be renamed to onboard_usb_dev (or
> similar) and do the hub specific bits as special case.
>
> Greg, do you have any thoughts on this?

Yeah, this worries me, adding non-hub support to this driver feels odd.
Why can't this all just be done in an individual driver for this device
itself?

Javier, what kernel driver supports this device to communicate with it?
Having 2 different drivers poke the same device is just going to cause
problems in the end, as there is no way to communicate between the two,
right?

thanks,

greg k-h