Actually it seems like I have got something strange with a firmware as well on my MDX. I’ve just powered on my MDX, but got no wifi connection. I’ve re-plugged wifi dongle and got connection raised in seconds after. dmesg
output is in the end of the post.
Seems like first (on-boot) attempt failed with mt7601u 1-1.4:1.0: Direct firmware load for mt7601u.bin failed with error -2
during MDX startup. But after replugging the dongle it worked well. I’ve tried to replug the dongle for 10 more times, and seems to work fine every time.
After that I’ve removed the firmware file from the /data/firmware/mt7601u.bin, and got the same error message when reconnecting the dongle:
[ 480.940288] usb 1-1.4: reset high-speed USB device number 13 using ehci-platform
[ 481.028296] mt7601u 1-1.4:1.0: ASIC revision: 76010001 MAC revision: 76010500
[ 481.029833] mt7601u 1-1.4:1.0: Direct firmware load for mt7601u.bin failed with error -2
[ 481.030592] mt7601u: probe of 1-1.4:1.0 failed with error -2
It feels like a race condition of some sort is here. (reminds me of audiogadget issues, by the way) Error “-2” is the same for firmware being in place during startup as for firmware being absent at all. Therefore it looks like MDX is not able to find the firmware that is placed properly, and only during startup.
Is usb dongle processed earlier in some cases than partition is mounted? It explains the observations quite well, and could be related to audiogadget stuff as well.
dmesg for failed booting with usb dongle and successful replug after:
[ 0.550256] systemd[1]: Started Remount Root and Kernel File Systems.
[ 0.550483] systemd[1]: Started Create System Users.
[ 0.551920] systemd[1]: Starting Create Static Device Nodes in /dev...
[ 0.552738] systemd[1]: Started Journal Service.
[ 0.608031] systemd-journald[135]: Received request to flush runtime journal from PID 1
[ 0.766043] vendor storage:20160801 ret = 0
[ 0.821289] usb 1-1.4: new high-speed USB device number 3 using ehci-platform
[ 0.917762] usb 1-1.4: New USB device found, idVendor=148f, idProduct=7601
[ 0.917775] usb 1-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 0.917783] usb 1-1.4: Product: 802.11 n WLAN
[ 0.917790] usb 1-1.4: Manufacturer: MediaTek
[ 0.917796] usb 1-1.4: SerialNumber: 1.0
[ 1.011296] usb 1-1.4: reset high-speed USB device number 3 using ehci-platform
[ 1.100645] mt7601u 1-1.4:1.0: ASIC revision: 76010001 MAC revision: 76010500
[ 1.102402] mt7601u 1-1.4:1.0: Direct firmware load for mt7601u.bin failed with error -2
[ 1.103392] mt7601u: probe of 1-1.4:1.0 failed with error -2
[ 1.103470] usbcore: registered new interface driver mt7601u
[ 1.112245] EXT4-fs (mmcblk0p5): mounted filesystem with ordered data mode. Opts: nodelalloc,errors=remount-ro
[ 1.665605] using random self ethernet address
[ 1.665613] using random host ethernet address
[ 1.666674] usb0: HOST MAC c6:d8:a5:3a:86:9b
[ 1.666714] usb0: MAC e2:ec:a9:db:de:b6
[ 1.666730] using random self ethernet address
[ 1.666734] using random host ethernet address
[ 1.666772] g_ether gadget: DuoX Ethernet, version: DuoX
[ 1.666775] g_ether gadget: g_ether ready
[ 2.760598] random: nonblocking pool is initialized
[ 36.472746] usb 1-1.4: USB disconnect, device number 3
[ 39.128277] usb 1-1.4: new high-speed USB device number 4 using ehci-platform
[ 39.224764] usb 1-1.4: New USB device found, idVendor=148f, idProduct=7601
[ 39.224772] usb 1-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 39.224776] usb 1-1.4: Product: 802.11 n WLAN
[ 39.224779] usb 1-1.4: Manufacturer: MediaTek
[ 39.224782] usb 1-1.4: SerialNumber: 1.0
[ 39.299277] usb 1-1.4: reset high-speed USB device number 4 using ehci-platform
[ 39.387251] mt7601u 1-1.4:1.0: ASIC revision: 76010001 MAC revision: 76010500
[ 39.389853] mt7601u 1-1.4:1.0: Firmware Version: 0.1.00 Build: 7640 Build time: 201302052146____
[ 39.744003] mt7601u 1-1.4:1.0: EEPROM ver:0d fae:00
[ 39.974716] ieee80211 phy1: Selected rate control algorithm 'minstrel_ht'
[ 41.259091] wlan0: authenticate with e8:65:d4:4f:af:31
[ 41.276014] wlan0: send auth to e8:65:d4:4f:af:31 (try 1/3)
[ 41.277656] wlan0: authenticated
[ 41.278276] wlan0: associate with e8:65:d4:4f:af:31 (try 1/3)
[ 41.298657] wlan0: RX AssocResp from e8:65:d4:4f:af:31 (capab=0x411 status=0 aid=2)
[ 41.331150] wlan0: associated
UPD:
just noticed, mount message comes after firmware loading failure, so looks like my assumption is correct, firmware is not loaded because partition with firmware is not mounted yet:
[ 1.100645] mt7601u 1-1.4:1.0: ASIC revision: 76010001 MAC revision: 76010500
[ 1.102402] mt7601u 1-1.4:1.0: Direct firmware load for mt7601u.bin failed with error -2
[ 1.103392] mt7601u: probe of 1-1.4:1.0 failed with error -2
[ 1.103470] usbcore: registered new interface driver mt7601u
[ 1.112245] EXT4-fs (mmcblk0p5): mounted filesystem with ordered data mode. Opts: nodelalloc,errors=remount-ro