Re: [PATCH v4 3/3] USB: serial: cp210x: Workaround cp2108 GET_LINE_CTL bug
[ Please avoid top-posting. ] On Thu, Oct 29, 2015 at 08:39:04AM -0500, Konstantin Shkolnyy wrote: > I tested it on cp2102, cp2105 and cp2108. > I'm a little worried about that extra PURGE command, so I did several > manual tests on each with a standard PC serial port on the other end > of the cable. > - run several open/write/close iteration (the test that used to break > cp2108), observe data on the other end; > - open minicom and see that cp210x can still receive data from the other end. Sounds good. If this turns out to cause any problems, we can always enable this based on chip type, right? I saw something about a vendor request for that in your (silabs') vendor driver. > BTW, can you suggest (preferably automated) serial port test s/w? No, sorry. I have a bunch of test code that I intend to organise and clean up at some point, but I never seem to find the time to actually do it. Johan -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v4 3/3] USB: serial: cp210x: Workaround cp2108 GET_LINE_CTL bug
On Sat, Oct 31, 2015 at 7:16 AM, Johan Hovold wrote: > [ Please avoid top-posting. ] > > On Thu, Oct 29, 2015 at 08:39:04AM -0500, Konstantin Shkolnyy wrote: >> I tested it on cp2102, cp2105 and cp2108. >> I'm a little worried about that extra PURGE command, so I did several >> manual tests on each with a standard PC serial port on the other end >> of the cable. >> - run several open/write/close iteration (the test that used to break >> cp2108), observe data on the other end; >> - open minicom and see that cp210x can still receive data from the other end. > > Sounds good. > > If this turns out to cause any problems, we can always enable this based > on chip type, right? I saw something about a vendor request for that in > your (silabs') vendor driver. Yes, there is a register with the chip type. [...] -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: Overly conservative xHCI bandwidth estimation
On Wed, Oct 21, 2015 at 09:49:16AM +0800, Lu, Baolu wrote: > I could spend some time on this issue a week later. > I'd like to check whether there is any bugs in the driver itself. > Otherwise, blacklist this specific device for LPM. I don't know if anything happened here, but if you need information for a blacklist, the two devices I've tested (which both have this issue) are: - 1edb:bd3b (Blackmagic Design Intensity Shuttle) - 1edb:bd4f (Blackmagic Design UltraStudio SDI) /* Steinar */ -- Homepage: http://www.sesse.net/ -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH] USB: qcserial: Fix support for HP lt4112 LTE/HSPA+ Gobi 4G Modem
The DEVICE_HWI type was added under the faulty assumption that Huawei devices based on Qualcomm chipsets and firmware use the static USB interface numbering known from Gobi devices. But this model does not apply to Huawei devices like the HP branded lt4112 (Huawei me906e). Huawei firmwares will dynamically assign interface numbers. Functions are renumbered when the firmware is reconfigured. Fix by changing the DEVICE_HWI type to use a simplified version of Huawei's subclass + protocol scheme: Blacklisting known network interface combinations and assuming the rest are serial. Reported-and-tested-by: Muri Nicanor Tested-by: Martin Hauke Cc: Fixes: e7181d005e84 ("USB: qcserial: Add support for HP lt4112 LTE/HSPA+ Gobi 4G Modem") Signed-off-by: Bjørn Mork --- drivers/usb/serial/qcserial.c | 53 +++ 1 file changed, 33 insertions(+), 20 deletions(-) diff --git a/drivers/usb/serial/qcserial.c b/drivers/usb/serial/qcserial.c index f49d262e926b..1771aac6db76 100644 --- a/drivers/usb/serial/qcserial.c +++ b/drivers/usb/serial/qcserial.c @@ -178,6 +178,10 @@ static int qcprobe(struct usb_serial *serial, const struct usb_device_id *id) __u8 ifnum; int altsetting = -1; + /* we only support vendor specific functions */ + if (intf->desc.bInterfaceClass != USB_CLASS_VENDOR_SPEC) + goto done; + nintf = serial->dev->actconfig->desc.bNumInterfaces; dev_dbg(dev, "Num Interfaces = %d\n", nintf); ifnum = intf->desc.bInterfaceNumber; @@ -297,29 +301,38 @@ static int qcprobe(struct usb_serial *serial, const struct usb_device_id *id) break; case QCSERIAL_HWI: /* -* Huawei layout: -* 0: AT-capable modem port -* 1: DM/DIAG -* 2: AT-capable modem port -* 3: CCID-compatible PCSC interface -* 4: QMI/net -* 5: NMEA +* Huawei devices map functions by subclass + protocol +* instead of interface numbers. The protocol identify +* a specific function, while the subclass indicate a +* specific firmware source +* +* This is a blacklist of functions known to be +* non-serial. The rest are assumed to be serial and +* will be handled by this driver */ - switch (ifnum) { - case 0: - case 2: - dev_dbg(dev, "Modem port found\n"); - break; - case 1: - dev_dbg(dev, "DM/DIAG interface found\n"); - break; - case 5: - dev_dbg(dev, "NMEA GPS interface found\n"); - break; - default: - /* don't claim any unsupported interface */ + switch (intf->desc.bInterfaceProtocol) { + /* QMI combined (qmi_wwan) */ + case 0x07: + case 0x37: + case 0x67: + /* QMI data (qmi_wwan) */ + case 0x08: + case 0x38: + case 0x68: + /* QMI control (qmi_wwan) */ + case 0x09: + case 0x39: + case 0x69: + /* NCM like (huawei_cdc_ncm) */ + case 0x16: + case 0x46: + case 0x76: altsetting = -1; break; + default: + dev_dbg(dev, "Huawei type serial port found (%02x/%02x/%02x)\n", + intf->desc.bInterfaceClass, intf->desc.bInterfaceSubClass, + intf->desc.bInterfaceProtocol); } break; default: -- 2.1.4 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH net,stable] qmi_wwan: fix entry for HP lt4112 LTE/HSPA+ Gobi 4G Module
The lt4112 is a HP branded Huawei me906e modem. Like other Huawei modems, it does not have a fixed interface to function mapping. Instead it uses a Huawei specific scheme: functions are mapped by subclass and protocol. However, the HP vendor ID is used for modems from many different manufacturers using different schemes, so we cannot apply a generic vendor rule like we do for the Huawei vendor ID. Replace the previous lt4112 entry pointing to an arbitrary interface number with a device specific subclass + protocol match. Reported-and-tested-by: Muri Nicanor Tested-by: Martin Hauke Fixes: bb2bdeb83fb1 ("qmi_wwan: Add support for HP lt4112 LTE/HSPA+ Gobi 4G Modem") Signed-off-by: Bjørn Mork --- drivers/net/usb/qmi_wwan.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/usb/qmi_wwan.c b/drivers/net/usb/qmi_wwan.c index c2e7222f2556..434f147e67ac 100644 --- a/drivers/net/usb/qmi_wwan.c +++ b/drivers/net/usb/qmi_wwan.c @@ -487,6 +487,10 @@ static const struct usb_device_id products[] = { USB_CDC_PROTO_NONE), .driver_info= (unsigned long)&qmi_wwan_info, }, + { /* HP lt4112 LTE/HSPA+ Gobi 4G Module (Huawei me906e) */ + USB_DEVICE_AND_INTERFACE_INFO(0x03f0, 0x581d, USB_CLASS_VENDOR_SPEC, 1, 7), + .driver_info = (unsigned long)&qmi_wwan_info, + }, /* 3. Combined interface devices matching on interface number */ {QMI_FIXED_INTF(0x0408, 0xea42, 4)},/* Yota / Megafon M100-1 */ @@ -739,7 +743,6 @@ static const struct usb_device_id products[] = { {QMI_FIXED_INTF(0x413c, 0x81a9, 8)},/* Dell Wireless 5808e Gobi(TM) 4G LTE Mobile Broadband Card */ {QMI_FIXED_INTF(0x413c, 0x81b1, 8)},/* Dell Wireless 5809e Gobi(TM) 4G LTE Mobile Broadband Card */ {QMI_FIXED_INTF(0x03f0, 0x4e1d, 8)},/* HP lt4111 LTE/EV-DO/HSPA+ Gobi 4G Module */ - {QMI_FIXED_INTF(0x03f0, 0x581d, 4)},/* HP lt4112 LTE/HSPA+ Gobi 4G Module (Huawei me906e) */ /* 4. Gobi 1000 devices */ {QMI_GOBI1K_DEVICE(0x05c6, 0x9212)},/* Acer Gobi Modem Device */ -- 2.1.4 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html