ASUS RT-N53
стоковая прошивка 374.4561
для запуска 5G на RT-N53 в init-broadcom.c есть код:
Code:
#ifdef RTCONFIG_BRCM_USBAP
/* We have to load USB modules after loading PCI wl driver so
* USB driver can decide its instance number based on PCI wl
* instance numbers (in hotplug_usb())
*/
modprobe("usbcore");
#ifdef LINUX26
mount("usbfs", "/proc/bus/usb", "usbfs", MS_MGC_VAL, NULL);
#else
mount("usbdevfs", "/proc/bus/usb", "usbdevfs", MS_MGC_VAL, NULL);
#endif /* LINUX26 */
{
char insmod_arg[128];
int i = 0, maxwl_eth = 0, maxunit = -1;
char ifname[16] = {0};
int unit = -1;
char arg1[20] = {0};
char arg2[20] = {0};
char arg3[20] = {0};
char arg4[20] = {0};
char arg5[20] = {0};
char arg6[20] = {0};
char arg7[20] = {0};
const int wl_wait = 3; /* max wait time for wl_high to up */
/* Save QTD cache params in nvram */
sprintf(arg1, "log2_irq_thresh=%d", nvram_get_int("ehciirqt"));
sprintf(arg2, "qtdc_pid=%d", nvram_get_int("qtdc_pid"));
sprintf(arg3, "qtdc_vid=%d", nvram_get_int("qtdc_vid"));
sprintf(arg4, "qtdc0_ep=%d", nvram_get_int("qtdc0_ep"));
sprintf(arg5, "qtdc0_sz=%d", nvram_get_int("qtdc0_sz"));
sprintf(arg6, "qtdc1_ep=%d", nvram_get_int("qtdc1_ep"));
sprintf(arg7, "qtdc1_sz=%d", nvram_get_int("qtdc1_sz"));
modprobe("ehci-hcd", arg1, arg2, arg3, arg4, arg5, arg6, arg7);
/* Search for existing PCI wl devices and the max unit number used.
* Note that PCI driver has to be loaded before USB hotplug event.
* This is enforced in rc.c
*/
#define DEV_NUMIFS 8
for (i = 1; i <= DEV_NUMIFS; i++) {
sprintf(ifname, "eth%d", i);
if (!wl_probe(ifname)) {
if (!wl_ioctl(ifname, WLC_GET_INSTANCE, &unit,
sizeof(unit))) {
maxwl_eth = i;
maxunit = (unit > maxunit) ? unit : maxunit;
}
}
}
/* Set instance base (starting unit number) for USB device */
sprintf(insmod_arg, "instance_base=%d", maxunit + 1);
modprobe("wl_high", insmod_arg);
/* Hold until the USB/HSIC interface is up (up to wl_wait sec) */
sprintf(ifname, "eth%d", maxwl_eth + 1);
i = wl_wait;
while (wl_probe(ifname) && i--) {
sleep(1);
}
if (!wl_ioctl(ifname, WLC_GET_INSTANCE, &unit, sizeof(unit)))
cprintf("wl%d is up in %d sec\n", unit, wl_wait - i);
else
cprintf("wl%d not up in %d sec\n", unit, wl_wait);
}
#endif /* __CONFIG_USBAP__ */
в логе после старта wl_high(5G) пояляется следующее:
Code:
Jan 1 02:00:12 kernel: usbcore: registered new interface driver usbfs
Jan 1 02:00:12 kernel: usbcore: registered new interface driver hub
Jan 1 02:00:12 kernel: usbcore: registered new device driver usb
Jan 1 02:00:13 kernel: ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
Jan 1 02:00:13 kernel: ehci_hcd 0000:00:04.1: EHCI Host Controller
Jan 1 02:00:13 kernel: ehci_hcd 0000:00:04.1: new USB bus registered, assigned bus number 1
Jan 1 02:00:13 kernel: ehci_hcd 0000:00:04.1: EHCI Fastpath: New EHCI driver starting
Jan 1 02:00:13 kernel: ehci_hcd 0000:00:04.1: irq 5, io mem 0x18004000
Jan 1 02:00:13 kernel: ehci_hcd 0000:00:04.1: USB 0.0 started, EHCI 1.00
Jan 1 02:00:13 kernel: usb usb1: configuration #1 chosen from 1 choice
Jan 1 02:00:13 kernel: hub 1-0:1.0: USB hub found
Jan 1 02:00:13 kernel: hub 1-0:1.0: 2 ports detected
Jan 1 02:00:13 kernel: usb 1-2: new high speed USB device using ehci_hcd and address 2
Jan 1 02:00:13 kernel: usb 1-2: configuration #1 chosen from 1 choice
Jan 1 02:00:13 kernel: Symbol usb_deregister is being used by a non-GPL module, which will not be allowed in the future
Jan 1 02:00:13 kernel: Please see the file Documentation/feature-removal-schedule.txt in the kernel source tree for more details.
Jan 1 02:00:13 kernel: bcm_rpc_up: waiting to be connected
Jan 1 02:00:13 kernel: bcm_rpc_buf_recv_mgn_high: Reason: 0 Dongle Version: 0x5648a89
Jan 1 02:00:13 kernel: bcm_rpc_buf_recv_mgn_high: Connected!
Jan 1 02:00:13 kernel: eth2: Broadcom BCMa8e4 802.11 Wireless Controller 5.110.27.20012
Jan 1 02:00:13 kernel: usbcore: registered new interface driver dbus_usbdev
т.е.
- грузится wl_high драйвер и регистрирует usb устройство Dongle Version: 0x5648a89
- поднимается интерфейс eth2
- eth2 добавляется в br0
КАК с помощью команд в консоле повторить тоже самое??????
после
modprobe -r wl_high
Code:
Jan 1 02:31:09 kernel: bcm_rpc_down
Jan 1 02:31:09 kernel: DONGLE rpc dump:
Jan 1 02:31:09 kernel: Version: 0x5648a89 State: 4
Jan 1 02:31:09 kernel: session 105 trans 0xda0 oe_trans 0x46dd rtn_trans 0x0
Jan 1 02:31:09 kernel: xactionID out of order 0 reorder ovfl 0 dropped hole 0
Jan 1 02:31:09 kernel: reorder queue depth 0 first ID 0x0 reorder_q_depth_max 0, tossthreshold 40
Jan 1 02:31:09 kernel: rpc_dbus_state_change: DBUS is down
Jan 1 02:31:10 kernel: br0: port 3(eth2) entering disabled state
Jan 1 02:31:10 kernel: device eth2 left promiscuous mode
Jan 1 02:31:10 kernel: br0: port 3(eth2) entering disabled state
Jan 1 02:31:10 kernel: bcm_rpc_down
Jan 1 02:31:10 kernel: usbcore: deregistering interface driver dbus_usbdev
если попробовать:
modprobe wl_high instance_base=2 (или любую другую цифру от 0 до 8) то получаем:
Code:
Jan 1 02:34:36 kernel: Symbol usb_deregister is being used by a non-GPL module, which will not be allowed in the future
Jan 1 02:34:36 kernel: Please see the file Documentation/feature-removal-schedule.txt in the kernel source tree for more details.
Jan 1 02:34:36 kernel: rpc_dbus_state_change: DBUS is down
Jan 1 02:34:36 kernel: bcm_rpc_tp_attach: dbus_attach failed
Jan 1 02:34:36 kernel: usbcore: registered new interface driver dbus_usbdev
драйвер wl_high грузится, но usb устройство не добавляется и не поднимается интерфейс eth2.
как же это все сделать из консоли?
--> http://www.linksysinfo.org/index.php...0/#post-234676