Re: [PATCH v2] USB: serial: qcserial: Support for SDX55 based Sierra Wireless 5G modules

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Stefan Brüns <stefan.bruens@xxxxxxxxxxxxxx> writes:

> On Donnerstag, 24. Juni 2021 13:15:07 CEST Bjørn Mork wrote:
>> Johan Hovold <johan@xxxxxxxxxx> writes:
>> > Could you please also post the output of usb-devices (or lsusb -v) for
>> > this device in MBIM mode?
>> 
>> Yes, this would be nice to have.
>
> See below.
>  
>> I suspect that this device is like other SDX55 devices we've seen, using
>> class/subclass/function to map the vendor specific functions
>> too. Dropping static interface numbers.  If correct, then the patch is
>> bogus and the interface numbers might change based on firmware version
>> and configuration.
>
> Do you really expect Sierra do to something sensible? According to their 
> documentation functions are matched by interface numbers.

Well... I expect them to be as sensible as any other vendor.  And I
expect docs to be intendend as guidance only ;-)

> They still use broken interface descriptors with holes in interface numbering 
> (i.e. interface number 2 does not exist, which violates the USB standard).

Right. Wrt the violation, I think that train left a decade ago.  

>     Interface Descriptor:
>       bLength                 9
>       bDescriptorType         4
>       bInterfaceNumber        3
>       bAlternateSetting       0
>       bNumEndpoints           3
>       bInterfaceClass       255 Vendor Specific Class
>       bInterfaceSubClass      0 
>       bInterfaceProtocol      0 
[..]
>     Interface Descriptor:
>       bLength                 9
>       bDescriptorType         4
>       bInterfaceNumber        4
>       bAlternateSetting       0
>       bNumEndpoints           2
>       bInterfaceClass       255 Vendor Specific Class
>       bInterfaceSubClass    255 Vendor Specific Subclass
>       bInterfaceProtocol     48 


So Sierra do follow the same pattern we've seen on other X55 devices:

ff/00/00 - AT
ff/ff/30 - QCDM

See commits

 accf227de4d2 ("USB: serial: option: Add support for Quectel RM500Q")
 d6c1ddd938d8 ("USB: serial: option: add Quectel EM160R-GL")

for other examples.

This obviously doesn't make any difference if your configuration is the
only one.  But I believe that is unlikely.  There are probably ways the
layout can be changed, even if currenly not documented.  The advantage
of class/subclass/protocol matching to function is that it works
regardless of the number of functions and their interface number.


Bjørn




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux