Re: [PATCH] USB: serial: option: add Fibocom FM135-GL variants

From: Lars Melin
Date: Wed Mar 06 2024 - 03:30:13 EST


On 2024-03-06 14:41, Bolan Wang(Bolan) wrote:
Hi Bolan,
so you already know that other versions of the card will have the pid
0x01a1 and the serial interfaces will be of class ff but you don't know what those interfaces will be used for?
You shall only add driver support for what you know today and not for something that might or might not be implemented in the future.

For the device with pid 0x0115 you have listed an adb interface and adb interfaces should not be in the option driver.

Hi Lars:

Ok, I will remove 0x01a1 from option serial driver. And the adb listed in pid 0x0115 will also be removed.
Actually adb interface info with pid 0x0115 is: Class_ff&SubClass_42&Prot_01, the option driver will not bind it?
I will resubmit a new patch, please help review and abandon this.

thanks
bolan



The option driver will bind because you have matched only on Class ff "{ USB_DEVICE_INTERFACE_CLASS(0x2cb7, 0x01a1, 0xff) }"
There are other macros that you could possibly use but I can't tell you which since you have not shown an usb-device listing for the device.
You can also blacklist an interface (RSV). The option driver source is full of examples of macro use and combinations.

thanks
Lars