Opened 2 years ago
Last modified 11 months ago
#17979 new bug
usb tethering does not work with the pixel6a (USB NCM network driver)
Reported by: | atomozero | Owned by: | nobody |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | Drivers/Network | Version: | R1/beta3 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
with the pixel 4 I had no problem surfing the internet through usb tethering. with the new mobile phone when I connect it, the network interface does not appear
Attachments (8)
Change History (22)
by , 2 years ago
by , 2 years ago
Attachment: | screenshot2.png added |
---|
by , 2 years ago
Attachment: | screenshot3.png added |
---|
by , 2 years ago
comment:2 by , 2 years ago
Component: | - General → Drivers/USB/XHCI |
---|---|
Owner: | changed from | to
Can you attach the output of listusb -v
for your phone while it is in tethering mode?
I put it under the xhci (USB3) component for now, if Waddlesplash thinks these errors in the syslog are not a cause of worry, hopefully we can find more from the listusb. I see no info from the usb_rndis driver in the syslog so I assume the device doesn't get far enough for the driver to start doing its work?
by , 2 years ago
Attachment: | listusb tethering on added |
---|
comment:3 by , 2 years ago
if there is anything I can do to help find the bug, I am available for testing :) wifi doesn't work so tethering is my only chance to use Haiku
comment:4 by , 2 years ago
I assume this is your phone:
73 [Device /dev/bus/usb/1/2] 74 Class .................. 0x00 (Per-interface classes) 75 Subclass ............... 0x00 76 Protocol ............... 0x00 77 Max Endpoint 0 Packet .. 64 78 USB Version ............ 2.16 79 Vendor ID .............. 0x18d1 (Google Inc.) 80 Product ID ............. 0x4ee1 (Nexus/Pixel Device (MTP)) 81 Product Version ........ 0x0510 82 Manufacturer String .... "" 83 Product String ......... "" 84 Serial Number .......... "" 85 [Configuration 0] 86 Configuration String . "" 87 [Interface 0] 88 [Alternate 0 active] 89 Class .............. 0x06 (Image) 90 Subclass ........... 0x01 91 Protocol ........... 0x01 92 Interface String ... "" 93 [Endpoint 0] 94 MaxPacketSize .... 512 95 Interval ......... 0 96 Type ............. Bulk 97 Direction ........ Input 98 [Endpoint 1] 99 MaxPacketSize .... 512 100 Interval ......... 0 101 Type ............. Bulk 102 Direction ........ Output 103 [Endpoint 2] 104 MaxPacketSize .... 28 105 Interval ......... 6 106 Type ............. Interrupt 107 Direction ........ Input
In this listusb output, it is in MTP (file transfer) mode, not in network tethering mode. As long as it stays that way, the usb_rndis driver cannot make use of it for USB tethering.
On my phone, switching to USB tethering is done from the Android settings in the connexions menu (annoyingly, not from the popup menu that shows when connecting it to an USB port). But this can change for different Android versions.
So, are you sure you have enabled USB tethering on the phone side? Does it actually remain enabled, or does the phone immediately switch it off? It's possible there's an issue while switching between the different modes and the phone reverts to the default MTP mode.
comment:5 by , 2 years ago
I confirm that when I enable the USB tethering function from windows or linux the driver is activated without problems. In Haiku when I select the same function, the message I put in the first comment appears in the syslog
comment:6 by , 2 years ago
Ok, so that means the problem is at a lower level than the usb_rndis driver. The phone needs to switch to a different mode which is similar to a very fast unplug and replug of the USB.
Our XHCI (USB3 low level) driver does not manage to handle things so fast and seems a bit confused. I will let Waddlesplash look into that part, as he knows it much better than I do.
comment:7 by , 2 years ago
XHCI handled switching modes just fine on my devices with my Moto G5. So I don't think that's the problem.
These errors are the likely cause:
KERN: usb xhci 1: transfer error on slot 9 endpoint 3: Length invalid KERN: usb error xhci 1: KERN: TRB 0x267a8220 was not found in the endpoint!
I've seen these before occasionally but I never have managed to get to the bottom of them...
comment:9 by , 11 months ago
This is the only difference that I see activating and deactivating USB tethering. :(
comment:11 by , 11 months ago
Now the phone seems to be properly in tethering mode (the device ID changed to 4eeb instead of 4ee1).
Can you include the output of listusb -v (verbose mode) when it is in that state? (it wasn't in the previous version you shared).
comment:12 by , 11 months ago
Component: | Drivers/USB/XHCI → Drivers/Network |
---|---|
Owner: | changed from | to
by , 11 months ago
Attachment: | listusb hrev57520 added |
---|
by , 11 months ago
Attachment: | syslog hrev57520 added |
---|
comment:13 by , 11 months ago
Ok, so this phone uses USB NCM which we don't have a driver for yet. A new driver will have to be written.
The spec is available here:
I had a quick look at it, if I understand correctly, the idea is that it is similar to USB ECM (for which we already have a driver), but it allows to send and receive multiple ethernet frames in a single USB packet to reduce CPU usage and increase transfer rates.
comment:14 by , 11 months ago
Summary: | usb tethering does not work with the pixel6a → usb tethering does not work with the pixel6a (USB NCM network driver) |
---|