我们参考MCIMX6DLAICPU1开发板,用imx6dl芯片自己做了一块板子,网卡总是起不来。输入ifconfig -a 可以看到eth0,输入ifconfig eth0 up,提示找不到phy,再输入ifconfig eth0 up,就出错了。出错打印信息见下面。
我们参考开发板,硬件上只更改了两个管脚,在bsp里也对应的做了如下修改。有没有哪位高人能指点一下,为什么网卡总是启动不了?
static iomux_v3_cfg_t mx6dl_sabreauto_pads[] = {
....
//MX6DL_PAD_KEY_COL1__ENET_MDIO, /*delete by zz*/
MX6DL_PAD_ENET_MDIO__ENET_MDIO, /*add by zz*/
//MX6DL_PAD_KEY_COL2__ENET_MDC, /*delete by zz*/
MX6DL_PAD_ENET_MDC__ENET_MDC, /*add by zz*/
}
错误打印如下:
root@freescale ~$ ifconfig -a
can0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
NOARP MTU:16 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:10
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Interrupt:143
eth0 Link encap:Ethernet HWaddr 00:19:B8:00:FF:81
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
lo Link encap:Local Loopback
LOOPBACK MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
root@freescale ~$ ifconfig eth0 up
eth0: no PHY, assuming direct connection to switch
PHY 0:00 not found
eth0: could not attach to PHY
ifconfig: SIOCSIFFLAGS: No such device
root@freescale ~$ ifconfig eth0 up
kernel BUG at include/linux/netdevice.h:520!
Unable to handle kernel NULL pointer dereference at virtual address 00000000
pgd = e4244000
[00000000] *pgd=747a2831, *pte=00000000, *ppte=00000000
Internal error: Oops: 817 [#1] PREEMPT SMP
Modules linked in:
CPU: 0 Not tainted (3.0.35-g7374273-dirty #26)
PC is at __bug+0x1c/0x28
LR is at __bug+0x18/0x28
pc : [<800452c8>] lr : [<800452c4>] psr: 60000013
sp : e485bdf8 ip : ea99a000 fp : 00000001
r10: 00001043 r9 : 00000000 r8 : e408080c
r7 : e401b044 r6 : 00000000 r5 : 8054ff18 r4 : e401b000
r3 : 00000000 r2 : 80ad91bc r1 : 60000093 r0 : 00000033
Flags: nZCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment user
Control: 10c53c7d Table: 7424404a DAC: 00000015
Process ifconfig (pid: 2847, stack limit = 0xe485a2f0)
Stack: (0xe485bdf8 to 0xe485c000)
bde0: 00000000 802fc210
be00: 000000bc 00000000 fffffff8 e4123da0 804aa2cc fffffff8 fffffff6 00000000
be20: 00000000 0000000d e401b000 00000000 00001043 80094d74 e401b000 e401b000
be40: 8054ff18 00000000 e401b044 e408080c 00000000 00001043 00000001 8043967c
be60: 804395dc e401b000 00001043 00001002 00000001 804398a4 00008914 e401b000
be80: 00001002 00008914 e485a000 804399c8 00000000 7e8b0bf8 00008914 8048b720
bea0: e4080800 00000014 e401b000 00000000 30687465 00000000 00000000 00000000
bec0: 00081043 00000000 00016850 2abb3928 e47d3dc0 00008914 7e8b0bf8 e41d00a0
bee0: 00000003 80042144 e485a000 00000000 00000000 804255b4 e20453a0 7e8b0bf8
bf00: e41d00a0 80101614 00000000 8003c420 00000000 800f3a00 00000020 e201bd6c
bf20: e485bf60 00000003 e485bf84 80ac2178 e485a000 800f3b2c 00000000 e2045380
bf40: 00000003 e485bf84 00000000 80425cc4 80ac2180 00000000 00000000 00000003
bf60: e4086a80 e41d00a0 7e8b0bf8 00008914 00000003 80042144 e485a000 00000000
bf80: 00000000 80101b18 00000002 00000000 2abc4000 00092495 7e8b0dfc 000896e4
bfa0: 00000036 80041fc0 00092495 7e8b0dfc 00000003 00008914 7e8b0bf8 00092495
bfc0: 00092495 7e8b0dfc 000896e4 00000036 7e8b0df4 00000000 000001c3 00000000
bfe0: 7e8b0ef5 7e8b0bd8 0001813c 2aca0dfc 20000010 00000003 00000000 00000000
[<800452c8>] (__bug+0x1c/0x28) from [<802fc210>] (fec_enet_open+0x30c/0x354)
[<802fc210>] (fec_enet_open+0x30c/0x354) from [<8043967c>] (__dev_open+0xa0/0xf0)
[<8043967c>] (__dev_open+0xa0/0xf0) from [<804398a4>] (__dev_change_flags+0x7c/0x134)
[<804398a4>] (__dev_change_flags+0x7c/0x134) from [<804399c8>] (dev_change_flags+0x10/0x48)
[<804399c8>] (dev_change_flags+0x10/0x48) from [<8048b720>] (devinet_ioctl+0x66c/0x708)
[<8048b720>] (devinet_ioctl+0x66c/0x708) from [<804255b4>] (sock_ioctl+0x68/0x260)
[<804255b4>] (sock_ioctl+0x68/0x260) from [<80101614>] (do_vfs_ioctl+0x80/0x54c)
[<80101614>] (do_vfs_ioctl+0x80/0x54c) from [<80101b18>] (sys_ioctl+0x38/0x5c)
[<80101b18>] (sys_ioctl+0x38/0x5c) from [<80041fc0>] (ret_fast_syscall+0x0/0x30)
Code: e59f0010 e1a01003 eb135d41 e3a03000 (e5833000)
---[ end trace a5f25a73dbec6e93 ]---
Segmentation fault
root@freescale ~$ |