Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rndis_host: support Novatel Verizon USB730L #730

Closed
wants to merge 2,918 commits into from

Conversation

takenaga
Copy link

This upstream patch made my Android phone usable as tether device for my AC68U.
Other platforms might benefit from same patch.

before patch

cat /proc/bus/usb/devices
T:  Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 27 Spd=480 MxCh= 0
D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=22b8 ProdID=2e24 Rev= 4.19
S:  Manufacturer=motorola
S:  Product=moto g play (2021)
S:  SerialNumber=<<masked>>
C:* #Ifs= 2 Cfg#= 1 Atr=80 MxPwr=500mA
A:  FirstIf#= 0 IfCount= 2 Cls=ef(misc ) Sub=04 Prot=01
I:* If#= 0 Alt= 0 #EPs= 1 Cls=ef(misc ) Sub=04 Prot=01 Driver=(none)
E:  Ad=81(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=(none)
E:  Ad=8e(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=0f(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms

dmesg
usb 2-1: new high speed USB device using ehci_hcd and address 29

after patch

T:  Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 33 Spd=480 MxCh= 0
D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=22b8 ProdID=2e24 Rev= 4.19
S:  Manufacturer=motorola
S:  Product=moto g play (2021)
S:  SerialNumber=<<masked>>
C:* #Ifs= 2 Cfg#= 1 Atr=80 MxPwr=500mA
A:  FirstIf#= 0 IfCount= 2 Cls=ef(misc ) Sub=04 Prot=01
I:* If#= 0 Alt= 0 #EPs= 1 Cls=ef(misc ) Sub=04 Prot=01 Driver=rndis_host
E:  Ad=81(I) Atr=03(Int.) MxPS=   8 Ivl=32ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=rndis_host
E:  Ad=8e(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=0f(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms

dmesg
usb 2-1: new high speed USB device using ehci_hcd and address 33
rndis_host 2-1:1.0: usb0: register 'rndis_host' at usb-0000:00:0b.1-1, RNDIS device, 01:23:45:67:89:ab

Screen Shot 2021-03-28 at 10 39 48 AM

(upstream: torvalds/linux@63ba395)
rndis_host: support Novatel Verizon USB730L

Treat the ef/04/01 interface class/subclass/protocol combination used
by the Novatel Verizon USB730L (1410:9030) as a possible RNDIS
interface.

T: Bus=01 Lev=02 Prnt=02 Port=01 Cnt=02 Dev#= 17 Spd=480 MxCh= 0
D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 3
P: Vendor=1410 ProdID=9030 Rev=03.10
S: Manufacturer=Novatel Wireless
S: Product=MiFi USB730L
S: SerialNumber=0123456789ABCDEF
C: #Ifs= 3 Cfg#= 1 Atr=80 MxPwr=500mA
I: If#= 0 Alt= 0 #EPs= 1 Cls=ef(misc ) Sub=04 Prot=01 Driver=rndis_host
I: If#= 1 Alt= 0 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=rndis_host
I: If#= 2 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=00 Prot=00 Driver=usbhid

Once the network interface is brought up, the user just needs to run a
DHCP client to get IP address and routing setup.

As a side note, other Novatel Verizon USB730L models with the same
vid:pid end up exposing a standard ECM interface which doesn't require
any other kernel update to make it work.

Signed-off-by: Aleksander Morgado aleksander@aleksander.es
Reviewed-by: Bjørn Mork bjorn@mork.no
Signed-off-by: David S. Miller davem@davemloft.net

Latest GPL merge should now be able to fully work with the original,
public RSAv1 key.
When using netlink, the route_net_gateway ENV var may
end up containing the default gateway of another tunnel instead
of the real default gateway from the main table, breaking things
when multiple clients are running.  The issue isn't unique to
2.6.xx and was reproduced on 4.1.52 as well.
…nown status report

fcctl on these older HND models do not report the state of runner.  Look for the
presence of the pktrunner module instead on these two models.

Also encode HTML entities for <unknown> reports to avoid being parsed
as HTML tags.
…, remove option to select sfq as a qsched

There are no reason for anyone to want to use sfq instead of fq_codel.
RMerl and others added 20 commits April 7, 2021 01:23
 - Fix version string formatting for available updates if it's running Asuswrt-Merlin
 - Re-add download button to the release notes page (link to the model redirector
   if it's the same model as the main router, otherwise use the global download
   page on the support site)

   We cannot use the redirector for all nodes since AiMesh does not expose
   the base model (i.e. RT-AC68U), only the model name (i.e. RT-AC66U_B1).
  - Move allowed_icmpv6 and allowed_local_icmpv6 rules into separate chains, for
    firewall optimization
  - Put icmpv6 type 128 (echo) packet through rate limit
  - Also rate limit type 128 traffic in the INPUT chain
  - Use the same rules for both the FORWARD and INPUT chains.  ICMP_V6_LOCAL
    will accept allowed traffic, and return for unhandled types.  ICMP_V6 will
    then handle those additionnal types, and drop any still unhandled type.
AiMesh is unable to detect new AM releases, so rely on the
legacy webs_state_flag for local router updates.
Based on some tests, it does help even if at a lesser
extent than on the newer HND platform.
…re in nvram's errorno

Fixes the server randomly reporting as being stuck initializing
because it was set in an error state when an incoming client would
fail to connect.
@RMerl RMerl force-pushed the master branch 7 times, most recently from d83a812 to a17374a Compare May 13, 2021 05:49
@JackMerlin
Copy link
Contributor

looks great. but I think the firmware supports USB sharing of Android phones.

@zshaozhong
Copy link

This patch looks great and can be really helpful to a lot of devices. Mine is a 2020 Moto G Power, which can really use this patch!

@RMerl RMerl closed this Aug 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet