Summary: | urndis(4) Inseego/Novatel Wireless MiFi 8800/8000 as urndis0 4g/LTE RNDIS fails to tether | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | Base System | Reporter: | rootless | ||||||||||
Component: | kern | Assignee: | freebsd-usb (Nobody) <usb> | ||||||||||
Status: | Closed FIXED | ||||||||||||
Severity: | Affects Many People | CC: | eugen, hps, hselasky, lwhsu, net, usb | ||||||||||
Priority: | --- | Keywords: | needs-qa | ||||||||||
Version: | Unspecified | Flags: | koobs:
maintainer-feedback?
(hps) |
||||||||||
Hardware: | Any | ||||||||||||
OS: | Any | ||||||||||||
URL: | https://github.com/freebsd/freebsd/pull/428 | ||||||||||||
See Also: | https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=239495 | ||||||||||||
Attachments: |
|
Description
rootless
2020-03-29 00:23:57 UTC
Can you provide us with information (ideally on FreeBSD) on the relevant Novatel device(s) that do work on FreeBSD, including which versions they work on. Can you also elaborate on: - "tethering on newer devices", as to whether that means you have an older device that works, or worked in the past? - "enabling tethering is not get picked up", whaty does this specifically mean with regard to steps to reproduce, commands, outputs, errors,system configuration to do so, etc (please provide as attachments) Additionally, the following may be helpful - var/run/dmesg.boot (as an attachment) with the device plugged in - pciconf -lv output (as an attachment) Also, include output of "usbconfig" command with device attached. If possible, do that for working and non-working cases. Created attachment 212865 [details]
dmesg.boot
dmesg.boot
Created attachment 212866 [details]
pciconf -lv
with MiFi 8000 attached
--- Comment #1 from Kubilay Kocak <koobs@FreeBSD.org> --- Can you provide us with information (ideally on FreeBSD) on the relevant Novatel device(s) that do work on FreeBSD, including which versions they work on. Good question. It appears that some older devices do. I don't have any other devices nor working devices. Just from searching on the web I found that an MiFi7730, from here: https://forum.netgate.com/topic/143342/unable-to-properly-keep-usb-ethernet-interface-attached-on-verizon-jetpack-7730l/2 I also found the following on the OpenBSD listserv: http://openbsd-archive.7691.n7.nabble.com/patch-for-Inseego-Novatel-MiFi-8800L-as-urndis0-td361099.html Can you also elaborate on: - "tethering on newer devices", as to whether that means you have an older device that works, or worked in the past? Just based on reports from the web. I only have the MiFi 8800/8000 - the differences are the frequencies for the cell modem tied to the carrier. - "enabling tethering is not get picked up", whaty does this specifically mean with regard to steps to reproduce, commands, outputs, errors,system configuration to do so, etc (please provide as attachments) 1) Plug in the device via USB. 2) It should be picked up as an rndis device and assigned to ue0 (assuming no other ue devices). [even using usbconfig -d ugen1.2 set_config 1 doesn't result in an RNDIS ethernet interface being created] Additionally, the following may be helpful dmesg at plugin: ugen1.2: <Novatel Wireless MiFi 8000> at usbus1 uhid2 on uhub0 uhid2: <HID Interface> on usbus1 usbconfig with the device attached: # usbconfig ugen1.1: <0x15ad EHCI root HUB> at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA) ugen0.1: <0x15ad UHCI root HUB> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=SAVE (0mA) ugen0.2: <VMware VMware Virtual USB Mouse> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (0mA) ugen0.3: <VMware, Inc. VMware Virtual USB Hub> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=SAVE (0mA) ugen1.2: <Novatel Wireless MiFi 8000> at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON (224mA) also # usbconfig -d 1.2 dump_device_desc ugen1.2: <Novatel Wireless MiFi 8000> at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON (224mA) bLength = 0x0012 bDescriptorType = 0x0001 bcdUSB = 0x0310 bDeviceClass = 0x0000 <Probed by interface class> bDeviceSubClass = 0x0000 bDeviceProtocol = 0x0000 bMaxPacketSize0 = 0x0009 idVendor = 0x1410 idProduct = 0xb022 bcdDevice = 0x0318 iManufacturer = 0x0001 <Novatel Wireless> iProduct = 0x0002 <MiFi 8000> iSerialNumber = 0x0003 <0123456789ABCDEF> bNumConfigurations = 0x0001 Created attachment 212919 [details]
dmesg of new kernel boot
Created attachment 212920 [details]
modified for RNDIS ethernet adapter support to Novatel 8800/8000
Ok. So I finished my kernel compile and rebooted with the new kernel. I didn't configure loader.local.conf to automatically load if_urndis.ko more as something else keep consistent between kernels, OSes, etc. Prior to loading if_urndis, as expected, no ue0 and the same usbconfig as always. After "kldload if_urndis" and "ifconfig" ue0 was there! Imagine my surprise. No changes with usbconfig: ugen1.1: <(0x15ad) EHCI root HUB> at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA) ugen0.1: <(0x15ad) UHCI root HUB> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=SAVE (0mA) ugen0.2: <VMware VMware Virtual USB Mouse> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (0mA) ugen0.3: <VMware, Inc. VMware Virtual USB Hub> at usbus0, cfg=0 md=HOST spd=FULL (12Mbps) pwr=SAVE (0mA) ugen1.2: <Novatel Wireless MiFi 8000> at usbus1, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON (224mA) The only modification I made was to sys/dev/usb/net/if_urnids.c: static const STRUCT_USB_HOST_ID urndis_host_devs[] = { /* Generic RNDIS class match */ {USB_IFACE_CLASS(UICLASS_CDC), USB_IFACE_SUBCLASS(UISUBCLASS_ABSTRACT_CONTROL_MODEL), USB_IFACE_PROTOCOL(0xff)}, {USB_IFACE_CLASS(UICLASS_WIRELESS), USB_IFACE_SUBCLASS(UISUBCLASS_RF), USB_IFACE_PROTOCOL(UIPROTO_RNDIS)}, {USB_IFACE_CLASS(UICLASS_IAD), USB_IFACE_SUBCLASS(UISUBCLASS_SYNC), USB_IFACE_PROTOCOL(UIPROTO_ACTIVESYNC)}, /* HP-WebOS */ {USB_VENDOR(USB_VENDOR_PALM), USB_IFACE_CLASS(UICLASS_CDC), USB_IFACE_SUBCLASS(UISUBCLASS_ABSTRACT_CONTROL_MODEL), USB_IFACE_PROTOCOL(0xff)}, /* Nokia 7 plus */ {USB_IFACE_CLASS(UICLASS_IAD), USB_IFACE_SUBCLASS(0x4), USB_IFACE_PROTOCOL(UIPROTO_ACTIVESYNC)}, /* Novatel Wireless 8800/8000/etc */ {USB_IFACE_CLASS(UICLASS_IAD), USB_IFACE_SUBCLASS(0xef), USB_IFACE_PROTOCOL(UIPROTO_RNDIS)}, }; The modified if_urndis.c is attached here. I haven't generated a patch in FreeBSD in too long or else I would submit this as a possible patch. Thank you. I created a pull-request on Github for the snippet. Please forgive my ignorance of the most appropriate way to submit the change. Thank you for writing and maintaining this driver! (In reply to rootless from comment #9) hi, the patch looks fine, and can you confirm that the ue0 is working? (In reply to Li-Wen Hsu from comment #10) I can confirm that it works when this patch is applied. It has been working with my device without a problem since I submitted the patch. I know others are using it successfully in OpnSense too. Go ahead. Don't forget to MFC to 11 and 12. A commit references this bug: Author: lwhsu Date: Thu Sep 10 18:27:52 UTC 2020 New revision: 365606 URL: https://svnweb.freebsd.org/changeset/base/365606 Log: urndis(4): Add support of Inseego/Novatel Wireless MiFi 8800/8000 PR: 245152 Submitted by: rootless@gmail.com Reviewed by: hselasky MFC after: 3 days Changes: head/sys/dev/usb/net/if_urndis.c A commit references this bug: Author: lwhsu Date: Tue Sep 15 06:12:31 UTC 2020 New revision: 365743 URL: https://svnweb.freebsd.org/changeset/base/365743 Log: MFC r365606: urndis(4): Add support of Inseego/Novatel Wireless MiFi 8800/8000 PR: 245152 Submitted by: rootless@gmail.com Reviewed by: hselasky Changes: _U stable/11/ stable/11/sys/dev/usb/net/if_urndis.c A commit references this bug: Author: lwhsu Date: Tue Sep 15 06:14:00 UTC 2020 New revision: 365744 URL: https://svnweb.freebsd.org/changeset/base/365744 Log: MFC r365606: urndis(4): Add support of Inseego/Novatel Wireless MiFi 8800/8000 PR: 245152 Submitted by: rootless@gmail.com Reviewed by: hselasky Changes: _U stable/12/ stable/12/sys/dev/usb/net/if_urndis.c A commit references this bug: Author: lwhsu Date: Tue Sep 15 12:34:02 UTC 2020 New revision: 365748 URL: https://svnweb.freebsd.org/changeset/base/365748 Log: MFC r365606 and MF12 r365744: urndis(4): Add support of Inseego/Novatel Wireless MiFi 8800/8000 PR: 245152 Submitted by: rootless@gmail.com Reviewed by: hselasky Approved by: re (gjb) Changes: _U releng/12.2/ releng/12.2/sys/dev/usb/net/if_urndis.c |