各位专家好!
我们自己AM335x的板子上使用了DP83865。
- 请问如何在uboot上修改程序使之能够支持
我知道uboot的driver里有dp83865的支持。
再修改这里就可以了吗?RMII_MODE_ENABLE, MAC_MII_SEL) 和 cpsw_data.gigabit_en =1;
- starterware
需要如何修改支持呢?
先谢谢了!
Yaoming Qin:
您说的是哪个板子,最新的uboot里面有对phy的支持,但是目前是对EVM板上的phy的支持。
如何修改,你可以对照着uboot或者kernel中的driver通过mdio配置phy了
hengbin zhao:
回复 Yaoming Qin:
谢谢您的回答,
我在uboot里修改软件使得能够支持,
"writel(RGMII_MODE_ENABLE,MAC_MII_SEL);
cpsw_data.gigabit =1"
但是还是不能工作。
在U-boot里运行DHCP
打印如下:
“Retry count exceeded; starting again
phyid1 = 0x2000
phyid1 = 0x5c7a
phy name =cpswAuto Negotitation failed for port 0
BOOTP broadcast 1
BOOTP broadcast 2
BOOTP broadcast 3
BOOTP broadcast 4
BOOTP broadcast 5
BOOTP broadcast 6
BOOTP broadcast 7
BOOTP broadcast 8
BOOTP broadcast 9
BOOTP broadcast 10”
看样子phyid是能够找到了,但不知还需要改哪里才能工作!谢谢!
Yaoming Qin:
回复 hengbin zhao:
这个你参考下kernel里面的驱动吧
hengbin zhao:
回复 Yaoming Qin:
我用最新2011.08-PSP.04.06.00.08,
linux kernel也是不能工作
554] PHY: 0:00 – Link is Up – 100/Full[ 4.544769] Sending DHCP requests …… timed out![ 84.366668] IP-Config: Reopening network devices…[ 84.377441] net eth0: CPSW phy found : id is : 0x20005c7a[ 84.386749] PHY 0:01 not found[ 86.375671] PHY: 0:00 – Link is Up – 100/Full[ 86.404754] Sending DHCP requests …… timed out![ 170.946533] IP-Config: Auto-configuration of network failed
在uboot下,运行DHCP命令
Retry count exceeded; starting againMII_BMCR val0000= 0x2300MII_BMCR val22222= 0x2300Auto Negotitation failed for port 0Jacky start to cpsw update linklink up on port 0, speed 100, full duplexBOOTP broadcast 1BOOTP broadcast 2BOOTP broadcast 3BOOTP broadcast 4BOOTP broadcast 5BOOTP broadcast 6BOOTP broadcast 7BOOTP broadcast 8BOOTP broadcast 9BOOTP broadcast 10
我的uboot下的pin mux:
static struct module_pin_mux rgmii1_pin_mux[] = {
{OFFSET(mii1_col ), MODE(2)}, /* RGMII1_COL */ {OFFSET(mii1_crs), MODE(2)}, /* RGMII1_CRS */ {OFFSET(mii1_rxerr), MODE(2)|RXACTIVE}, /* RGMII1_RXERR */
{OFFSET(mii1_txen), MODE(2)}, /* RGMII1_TCTL */ {OFFSET(mii1_rxdv), MODE(2) | RXACTIVE}, /* RGMII1_RCTL */ {OFFSET(mii1_txd3), MODE(2)}, /* RGMII1_TD3 */ {OFFSET(mii1_txd2), MODE(2)}, /* RGMII1_TD2 */ {OFFSET(mii1_txd1), MODE(2)}, /* RGMII1_TD1 */ {OFFSET(mii1_txd0), MODE(2)}, /* RGMII1_TD0 */ {OFFSET(mii1_txclk), MODE(2)}, /* RGMII1_TCLK */ {OFFSET(mii1_rxclk), MODE(2) | RXACTIVE}, /* RGMII1_RCLK */ {OFFSET(mii1_rxd3), MODE(2) | RXACTIVE}, /* RGMII1_RD3 */ {OFFSET(mii1_rxd2), MODE(2) | RXACTIVE}, /* RGMII1_RD2 */ {OFFSET(mii1_rxd1), MODE(2) | RXACTIVE}, /* RGMII1_RD1 */ {OFFSET(mii1_rxd0), MODE(2) | RXACTIVE}, /* RGMII1_RD0 */ //{OFFSET(mii1_refclk), MODE(2)|RXACTIVE}, /* RGMII1_REFERR */ {OFFSET(mdio_data), MODE(0) | RXACTIVE | PULLUP_EN}, /* MDIO_DATA */ {OFFSET(mdio_clk), MODE(0) | PULLUP_EN}, /* MDIO_CLK */ {-1},};
Auto Negotitation failed for port 0 说明什么问题呢?
hengbin zhao:
回复 hengbin zhao:
出现Auto Negotitation failed for port 0,是因为没有使能A/N enable。
但还是ping不通。
-Boot# mii dump 0x00 0x000. (3100) — PHY control register — (8000:0000) 0.15 = 0 reset (4000:0000) 0.14 = 0 loopback (2040:2000) 0. 6,13 = b01 speed selection = 100 Mbps (1000:1000) 0.12 = 1 A/N enable (0800:0000) 0.11 = 0 power-down (0400:0000) 0.10 = 0 isolate (0200:0000) 0. 9 = 0 restart A/N (0100:0100) 0. 8 = 1 duplex = full (0080:0000) 0. 7 = 0 collision test enable (003f:0000) 0. 5- 0 = 0 (reserved)
linux下也是ping不通的。
he kun:
回复 hengbin zhao:
我也遇到和你差不多的问题了哈
Tuff Li:
回复 he kun:
[ 84.386749] PHY 0:01 not found
PHY ADDR配置对不对?
Yalan Han:
回复 Tuff Li:
请问应用DP83865,AM3358实现网口通信,我现在用starterware裸跑例程,需要进行哪些配置的修改啊?如跑enetEcho,谢谢