本身板子有两个网口,其中一个没有变压器转换器,另外一个在Uboot中使用是没有问题的,可以正常的tftp下载kernel与dtb,但是在Linux,OpenWRT启动后,如果配置网络IP地址就会出现不停的up与down的情况
udhcpc (v1.20.2) started
fec 2188000.ethernet eth0: Freescale FEC PHY driver [Generic PHY] (mii_bus:phy_addr=2188000.ethernet:00, irq=-1)
IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
Sending discover...
Sending discover...
libphy: 2188000.ethernet:00 - Link is Up - 100/Full
IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
libphy: 2188000.ethernet:00 - Link is Down
Sending discover...
libphy: 2188000.ethernet:00 - Link is Up - 100/Full
libphy: 2188000.ethernet:00 - Link is Down
libphy: 2188000.ethernet:00 - Link is Up - 100/Full
后面的ipaddr其实是不会起作用的。
根据OpenWRT的Wiki页面的信息,我们知道这个dhcpc使用的是busybox里面的udhcpc,因此如果无法获取地址那么需要确定busybox里面是否配置上了这个util:
Protocol Description Program
static Static configuration with fixed address and netmask ip/ifconfig
dhcp Address and netmask are assigned by DHCP udhcpc (Busybox)