使用相同的环境,目前稍好点,mii info能看到东西了:
U-Boot 2018.01 (Jun 04 2020 – 02:02:40 +0000) Xilinx ZynqMP ZCU102 rev1.0
I2C: ready
DRAM: 2 GiB
EL Level:EL2
Chip ID:zu2eg
MMC: mmc@ff160000: 0 (eMMC), mmc@ff170000: 1 (SD)
** Unable to use mmc 0:0 for loading the env **
Using default environment
In: serial@ff000000
Out: serial@ff000000
Err: serial@ff000000
Board: Xilinx ZynqMP
Bootmode: SD_MODE1
Net: ZYNQ GEM: ff0d0000, phyaddr 0, interface sgmii
eth0: ethernet@ff0d0000
U-BOOT for hb_demo_2018
ethernet@ff0d0000: No link.
Hit any key to stop autoboot: 0
ZynqMP>
ZynqMP> mii info
PHY 0x03: OUI = 0x3FFFC0, Model = 0x00, Rev = 0x00, 100baseX, FDX
ZynqMP> mii info
PHY 0x01: OUI = 0x3FFFC0, Model = 0x00, Rev = 0x00, 1000baseX, FDX
ZynqMP> mii info
ZynqMP> mii info
ZynqMP> mii info
就是mii info 只显示一两下就又没东西了, 你那儿是这样么, 设备树我用的如下:
&gem2 {
phy-mode = “sgmii”;
phy-handle = ;
//phy-reset-gpio = ;
//phy-reset-active-low;
phy0:ethernet-phy@0x0{
reg = <0x0>;
compatible = “athros,ar8031”;
device_type = “ethernet-phy”;
xlnx,phy-type = <0x4>;
};
};
ZynqMP> mii info
PHY 0x00: OUI = 0x0000, Model = 0x00, Rev = 0x00, 10baseT, HDX
PHY 0x01: OUI = 0x0000, Model = 0x00, Rev = 0x00, 10baseT, HDX
PHY 0x02: OUI = 0x3FFFC0, Model = 0x00, Rev = 0x00, 10baseT, HDX
PHY 0x03: OUI = 0x0000, Model = 0x00, Rev = 0x00, 10baseT, HDX
ZynqMP> ping 192.168.10.20
ethernet@ff0d0000 Waiting for PHY auto negotiation to complete. done
Using ethernet@ff0d0000 device
ARP Retry count exceeded; starting again
ping failed; host 192.168.10.20 is not alive
ping 不通的。
进入linux系统也没找到eth0
应该还是phy的原因吧?千兆网支持好像看到有帖子将速率降下来就可以,设备树可以参考:
&gem2 {
local-mac-address = [00 0a 35 00 1e 53];
xlnx,eth-mode = <0x1>;
phy-handle = ;
phy0: phy0@7 {
#address-cells = <1>;
#size-cells = <0>;
device_type = “ethernet-phy”;
reg = <7>;
};
fixed-link {
speed = <1000>;
full-duplex;
};
};