|
[Pin-mux問題] RK3128 GPIO2與GMAC設定問題
发表于 2016-9-29 17:44:01
浏览:7071
|
回复:1
打印
只看该作者
[复制链接]
楼主
Hi All,
目前在rk3128的開發上屬於新手, 剛接觸此平台
在設定ethernet發生問題, 希望先進給予建議 (個人判斷Cannot attach to PHY應該是PIN MUX的部分沒處理好)
Ethernet燈號為綠燈及黃燈持續閃爍, 無法連網
Ethernet 是使用10/100M, 設定為rmii,
而GPIO2_B4, B5, B6, B7這些則設定給GMAC_MDIO_d, GMAX_TXEN_d, ..., etc
pinctrl中有開啟gpio2_gmac設定, 但查0x200080cc 卻是0x45
pinctrl debug message如下
cat pinmux-functions
<17:18:30> function: gpio2_gmac, groups = [ gmac-rxdv gmac-txclk gmac-crs gmac-rxclk gmac-mdio gmac-txen gmac-clk gmac-rxer gmac-rxd1 gmac-rxd0 gmac-txd1 gmac-txd0 gmac-rxd3 gmac-rxd2 gmac-txd2 gmac-txd3 gmac-col gmac-col-gpio gmac-mdc ]
<17:18:30> function: gpio2_lcdc0, groups = [ lcdc0-lcdc lcdc0-gpio ]
cat pinmux-pins
<16:55:49> pin 72 (gpio2-8): device (GPIO UNCLAIMED) function gpio2_lcdc0 group lcdc0-lcdc
<16:55:49> pin 73 (gpio2-9): device (GPIO UNCLAIMED) function gpio2_lcdc0 group lcdc0-lcdc
<16:55:49> pin 74 (gpio2-10): device gpio2:74 function gpio2_lcdc0 group lcdc0-lcdc
<16:55:49> pin 75 (gpio2-11): device (GPIO UNCLAIMED) function gpio2_lcdc0 group lcdc0-lcdc
<16:55:49> pin 76 (gpio2-12): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 77 (gpio2-13): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 78 (gpio2-14): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 79 (gpio2-15): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 80 (gpio2-16): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 81 (gpio2-17): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 82 (gpio2-18): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 83 (gpio2-19): (MUX UNCLAIMED) (GPIO UNCLAIMED)
<16:55:49> pin 84 (gpio2-20): 2005a000.i2c gpio2:84 function gpio1_i2c2 group i2c2-sda
<16:55:49> pin 85 (gpio2-21): 2005a000.i2c gpio2:85 function gpio1_i2c2 group i2c2-scl
而在實際的PHY probe log
<17:21:06> [ 13.883660] phy_power_on: enable = 1
<17:21:06> [ 13.923239] Read the Ethernet MAC address from IDB:00:00:00:00:00:00
<17:21:06> [ 13.923434] eth0: device MAC address 42:df:90:78:6b:86
<17:21:07> [ 13.964757] libphy: stmmac: probed
<17:21:07> [ 13.964816] eth0: PHY ID 00000000 at 0 IRQ 0 (stmmac-0:00) active
<17:21:07> [ 13.964845] eth0: PHY ID 00000000 at 1 IRQ 0 (stmmac-0:01) active
<17:21:07> [ 13.964871] eth0: PHY ID 00000000 at 2 IRQ 0 (stmmac-0:02)
.............................
<17:21:07> [ 13.965577] eth0: PHY ID 00000000 at 31 IRQ 0 (stmmac-0:1f)
<17:21:07> [ 13.965732] stmmac_open: Cannot attach to PHY (error: -19)
|
|