Modify

Opened 2 years ago

Last modified 2 years ago

#21617 new defect

yota 4G modem hotplug fails

Reported by: bolvan Owned by: developers
Priority: normal Milestone:
Component: base system Version: Trunk
Keywords: usb hotplug yota Cc:

Description

My platform is Netgear WNDR3700 and I want to run Yota 4G modem.
Here is the original thread i posted on the forum : https://forum.openwrt.org/viewtopic.php?id=62168

This device on power on present itself as USB CDROM then after 2 seconds disconnects itself and represent as USB ethernet adapter.
In openwrt after cold boot (power was off) for some reason device has no associated driver and does not work until physically replugged.

When manually replugged - all works fine :

[  245.180262] usb 1-1: new high-speed USB device number 4 using ehci-platform
[  245.320045] usb-storage 1-1:1.0: USB Mass Storage device detected
[  245.336509] scsi host1: usb-storage 1-1:1.0
[  246.345228] scsi 1:0:0:0: CD-ROM            GDM Mass                       PQ: 0 ANSI: 0 CCS
[  246.356242] scsi 1:0:0:0: Attached scsi generic sg0 type 5
[  247.323757] usb 1-1: USB disconnect, device number 4
[  248.112735] usb 1-1: new high-speed USB device number 5 using ehci-platform
[  248.252992] rndis_host 1-1:1.0: dev can't take 1558 byte packets (max 1458), adjusting MTU to 1400
[  248.274540] rndis_host 1-1:1.0 eth2: register 'rndis_host' at usb-ehci-platform-1, RNDIS device, 00:09:3b:f0:1a:40


T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  5 Spd=480  MxCh= 0
D:  Ver= 2.00 Cls=02(comm.) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=1076 ProdID=8002 Rev= 1.00
S:  Manufacturer=GCT SEMICONDUCTOR Inc
S:  Product=Modem Yota
C:* #Ifs= 2 Cfg#= 1 Atr=80 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=e0(wlcon) Sub=01 Prot=03 Driver=rndis_host
E:  Ad=81(I) Atr=03(Int.) MxPS=  64 Ivl=1ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=rndis_host
E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms

After cold boot :

[   11.458595] procd: - early -
[   11.461575] procd: - watchdog -
[   11.553077] usb 1-1: new high-speed USB device number 2 using ehci-platform
[   12.229948] procd: - ubus -
[   13.239815] procd: - init -

T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=480  MxCh= 0
D:  Ver= 2.00 Cls=02(comm.) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=1076 ProdID=8003 Rev= 1.00
S:  Manufacturer=GCT SEMICONDUCTOR Inc
S:  Product=Modem Yota
C:* #Ifs= 2 Cfg#= 1 Atr=c0 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=02(comm.) Sub=06 Prot=00 Driver=(none)
E:  Ad=81(I) Atr=03(Int.) MxPS=  64 Ivl=1ms
I:* If#= 1 Alt= 0 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=(none)
E:  Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms

No action is taken, kernel module not loaded, device does not work

Logs are taken from the system where all modules are on squashfs except kmod-usb2. kmod-usb2 is on overlayfs.
With all modules on squashfs device also does not work.

Attachments (0)

Change History (2)

comment:1 in reply to: ↑ description Changed 2 years ago by bolvan

Seems like this behavior is by design. Solution is to put "rndis-host" to /etc/modules-boot.d on squashfs (not on overlayfs or extroot because hotplug events start before processing overlay or extroot).

1) change package/kernel/linux/modules/usb.mk

define KernelPackage/usb-net-rndis

TITLE:=Support for RNDIS connections
KCONFIG:=CONFIG_USB_NET_RNDIS_HOST
FILES:= $(LINUX_DIR)/drivers/$(USBNET_DIR)/rndis_host.ko

# AUTOLOAD:=$(call AutoProbe,rndis_host)

AUTOLOAD:=$(call AutoLoad,41,rndis_host,1)
$(call AddDepends/usb-net,+kmod-usb-net-cdc-ether)

endef

2)
make package/linux/clean
make

Wish : be able to select boot loaded packages in menuconfig

Last edited 2 years ago by bolvan (previous) (diff)

comment:2 Changed 2 years ago by bolvan

And one more thought..

Any USB device not having boot modules on squashfs will be unusable.
Be it USB printer, USB modem or anything else.
You cant just install kmod from the repo and use the device.
Is it normal ?

Add Comment

Modify Ticket

Action
as new .
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.