Having trouble with TP-LINK AC600 Archer T2UH based on Ralink's MT7650
chipset with run driver on OpenBSD 6.0-stable with all the latest source
tree patches installed.
Just after I've added MT7650 by patching files listed below and
recompiled the kernel the USB stick shows its identities as:
run0 at uhub0 port 2 configuration 1 interface 0 "MediaTek WiFi" rev
2.01/1.00 addr 2
run0: MAC/BBP RT7650 (rev 0x2000), RF RT3053 (MIMO 1T1R), address "MAC"
During boot It configured to associate with AP in BSS mode and having IP
address from DHCP.
$ cat hostname.run0
dhcp media autoselect mode 11g nwid NAME wpa wpakey KEY chan 11
while issuing # sh /etc/netstart run0 command I have error message:
run0: timeout waiting for MCU to initialize
run0: could not load 8051 microcode
To test it out I've downloaded win7 driver and extract the firmware
files from it
mt7650.bin , mt7610.bin. Renamed them to run-mt7650 and run-mt7610
respectively and put into /etc/firmware
When I added firmware in the source (as shown below) and rebuild the
kernel afterwards.
While boot when DHCP requests are sent by network adapters I have the
same meessage "run0: could not load 8051 microcode"
--- /usr/src/sys/dev/usb/usbdevs.h.old Thu Mar 23 19:00:27 2017
+++ /usr/src/sys/dev/usb/usbdevs.h Thu Mar 23 16:33:07 2017
@@ -3550,6 +3550,7 @@
#define USB_PRODUCT_RALINK_RT3573 0x3573 /* RT3573 */
#define USB_PRODUCT_RALINK_RT5572 0x5572 /* RT5572 */
#define USB_PRODUCT_RALINK_MT7601 0x7601 /* MT7601 */
+#define USB_PRODUCT_RALINK_MT7650 0x761A /* MT7650 */
#define USB_PRODUCT_RALINK_RT8070 0x8070 /* RT8070 */
#define USB_PRODUCT_RALINK_RT2570_3 0x9020 /* RT2570 */
#define USB_PRODUCT_RALINK_RT2573_2 0x9021 /* RT2573 */
--- /usr/src/sys/dev/usb/if_run.c.old Thu Mar 23 18:59:36 2017
+++ /usr/src/sys/dev/usb/if_run.c Thu Mar 23 19:02:46 2017
@@ -257,6 +257,7 @@
USB_ID(RALINK, RT3573),
USB_ID(RALINK, RT5370),
USB_ID(RALINK, RT5572),
+ USB_ID(RALINK, MT7650),
USB_ID(RALINK, RT8070),
USB_ID(SAMSUNG, WIS09ABGN),
USB_ID(SAMSUNG2, RT2870_1),
@@ -830,7 +831,7 @@
if (sc->mac_ver != 0x2860 &&
sc->mac_ver != 0x2872 &&
sc->mac_ver != 0x3070)
- fwname = "run-rt3071";
+ fwname = "run-mt7610";
else
fwname = "run-rt2870";
@@ -839,13 +840,13 @@
sc->sc_dev.dv_xname, fwname, error);
return error;
}
- if (size != 4096) {
+/* if (size != 4096) {
printf("%s: invalid firmware size (should be 4KB)\n",
sc->sc_dev.dv_xname);
free(ucode, M_DEVBUF, 0);
return EINVAL;
}
-
+*/
run_read(sc, RT2860_ASIC_VER_ID, &tmp);
/* write microcode image */
run_write_region_1(sc, RT2870_FW_BASE, ucode, size);
----------------------------------