MT7620 编译 openwrt

今天编译 MT7620 固件后,烧录进去发现进不了系统。报错如下:
[    8.220000] ralink_soc_eth 10100000.ethernet eth0: port 4 link up (1000Mbps/Full duplex)
[    8.220000] CPU 0 Unable to handle kernel paging request at virtual address 0000011c, epc == 801b6e58, ra == 801b0448
[    8.220000] Oops[#1]:
[    8.220000] CPU: 0 PID: 259 Comm: kworker/0:2 Not tainted 3.18.23 #3
[    8.220000] Workqueue: events_power_efficient phy_state_machine
[    8.220000] task: 83998e88 ti: 83af8000 task.ti: 83af8000
[    8.220000] $ 0   : 00000000 0000006e 00000000 00000000
[    8.220000] $ 4   : 80312bdc 80313c38 802fd180 00000014
[    8.220000] $ 8   : 00000001 30312820 624d3030 462f7370
[    8.220000] $12   : 00000000 00000000 00000000 43495645
[    8.220000] $16   : 00000005 839a0000 00000008 839a0420
[    8.220000] $20   : 839a0420 00000001 00000064 000003e8
[    8.220000] $24   : 00000003 8017fcac                  
[    8.220000] $28   : 83af8000 83af9df8 0000000a 801b0448
[    8.220000] Hi    : 00000000
[    8.220000] Lo    : ec4e4000
[    8.220000] epc   : 801b6e58 fe_phy_link_adjust+0x78/0x13c
[    8.220000]     Not tainted
[    8.220000] ra    : 801b0448 phy_state_machine+0x1c4/0x480
[    8.220000] Status: 1100a402 KERNEL EXL 
[    8.220000] Cause : 00808008
[    8.220000] BadVA : 0000011c
[    8.220000] PrId  : 00019650 (MIPS 24KEc)
[    8.220000] Modules linked in: leds_gpio ohci_platform ohci_hcd ehci_platform ehci_hcd gpio_button_hotplug usbcore nls_base usb_common
[    8.220000] Process kworker/0:2 (pid: 259, threadinfo=83af8000, task=83998e88, tls=00000000)
[    8.220000] Stack : 83b29400 839a6a00 0000ffff 839a6b50 839a6b50 00000020 802fd170 00000000
          00000000 839a6a00 839a6b88 802fd170 00000008 801b0448 80300000 80040bb4
          83b23100 83b29500 83b23100 839a6b50 802fd170 8108bb00 00000000 00000000
          802fd180 80035bc4 802b0000 8000a624 802a9e04 00000001 83b23100 83b23118
          83b23100 83b23100 802fd170 83b23118 802a9e04 00000001 80300000 802fd180
          ...
[    8.220000] Call Trace:
[    8.220000] [<801b6e58>] fe_phy_link_adjust+0x78/0x13c
[    8.220000] [<801b0448>] phy_state_machine+0x1c4/0x480
[    8.220000] [<80035bc4>] process_one_work+0x1fc/0x338
[    8.220000] [<80036718>] worker_thread+0x2b0/0x40c
[    8.220000] [<80039e14>] kthread+0xd8/0xe4
[    8.220000] [<80004878>] ret_from_kernel_thread+0x14/0x1c
[    8.220000] 
[    8.220000] 
Code: 10400025  00001021  8c830000 <8c66011c> 10c00008  8c65010c  8c890060  8c680110  15280004 
[    8.640000] ---[ end trace b340c8525740eeed ]---


据说是网卡驱动引起的,需要修改 dts 文件。

vim target/linux/ramips/dts/MT7620a.dts
把 ethernet@10100000 和 gsw@10110000 修改成下面的内容:
ethernet@10100000 {
            status = "okay";
            mtd-mac-address = <&factory 0x4>;

            pinctrl-names = "default";
            pinctrl-0 = <&ephy_pins>;

            ralink,port-map = "llllw";

};

gsw@10110000 {
			ralink,port4 = "ephy_pins";
};



你可能感兴趣的:(OpenWrt)