ethernet for ls1046

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ethernet for ls1046

1,958 Views
gie_yang
Contributor I

Hi All:

We have currently designed a motherboard based on LS1046 and I want to connect Ethernet PHY RTL8211FS, which uses RGMII and SGMII MAC interfaces. The PHY RTL8211FS chip cannot be correctly identified by using "mii info" on the uboot terminal, but the device name "fm1-mac*" can be identified by logging in to linux. Log as follows:

=> 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 = 0x0000, Model = 0x00, Rev = 0x00, 10baseT, HDX

root@localhost:~# ifconfig -a
fm1-mac3: flags=4098<BROADCAST,MULTICAST> mtu 1500
ether 4e:49:fb:ec:4a:b2 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device memory 0x1ae4000-1ae4fff

fm1-mac4: flags=4098<BROADCAST,MULTICAST> mtu 1500
ether ba:f3:98:0a:50:18 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device memory 0x1ae6000-1ae6fff


Now, the ping itself is now normal when tested with the fm1-mac* device.

root@ubuntu:/sys/kernel/debug# ifconfig fm1-mac6

fm1-mac6: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 192.168.0.232 netmask 255.255.255.0 broadcast 192.168.0.255
ether 02:7d:2d:b3:c1:47 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device memory 0x1aea000-1aeafff
root@ubuntu:/sys/kernel/debug# ping 192.168.0.232
PING 192.168.0.232 (192.168.0.232) 56(84) bytes of data.
64 bytes from 192.168.0.232: icmp_seq=1 ttl=64 time=0.062 ms
64 bytes from 192.168.0.232: icmp_seq=2 ttl=64 time=0.041 ms
 
However, the ping test between the LS1046 board and the PC fails when the PC is directly connected to the PC using a network cable.

 
=> ping 192.168.0.100
FM1@DTSEC5 Waiting for PHY auto negotiation to complete......... TIMEOUT !
FM1@DTSEC5: Could not initialize
Using FM1@DTSEC6 device

ARP Retry count exceeded; starting again
ping failed; host 192.168.0.100 is not alive

root@ubuntu:~# ping 192.168.0.100
PING 192.168.0.100 (192.168.0.100) 56(84) bytes of data.
From 192.168.0.232 icmp_seq=1 Destination Host Unreachable
From 192.168.0.232 icmp_seq=2 Destination Host Unreachable
From 192.168.0.232 icmp_seq=3 Destination Host Unreachable
From 192.168.0.232 icmp_seq=4 Destination Host Unreachable
From 192.168.0.232 icmp_seq=5 Destination Host Unreachable
From 192.168.0.232 icmp_seq=6 Destination Host Unreachable

The SDK version we are currently using is LSDK1906
Can anyone give me some help about this problem?

 

3 Replies

1,811 Views
June_Lu
NXP TechSupport
NXP TechSupport

Please carefully compare difference between the LS1046ARDB and customer board, and then update the driver and debug according to the customer board. And check if HW works correctly.

0 Kudos
Reply

1,891 Views
June_Lu
NXP TechSupport
NXP TechSupport

Please refer LS1046ARDB  LSDK2108 to merge new PHY as there are both RGMII and SGMII PHYs on board.

From code review, you can modify those files as below:

u-boot:

u-boot\board\freescale\ls1046ardb\eth.c

u-boot\include\configs\ls1046ardb.h

#ifdef CONFIG_NET

#define CONFIG_PHY_REALTEK

#endif

 

#ifdef CONFIG_SYS_DPAA_FMAN

#define RGMII_PHY1_ADDR 0x1

#define RGMII_PHY2_ADDR 0x2

#define SGMII_PHY1_ADDR 0x3

#define SGMII_PHY2_ADDR 0x4

 

Kernel:

dts

kernel menuconfig to enable driver of realtek phy

0 Kudos
Reply

1,883 Views
gie_yang
Contributor I

Hi June_Lu,

I have modified it in these files before, but I got the same result.

u-boot:

u-boot\board\freescale\ls1046afrwy\eth.c

u-boot\include\configs\ls1046afrwy.h

#ifdef CONFIG_SYS_DPAA_FMAN
#define CONFIG_FMAN_ENET

//add gie-ls1046a
#define RGMII_PHY1_ADDR                        0x1
#define RGMII_PHY2_ADDR                        0x2
#define SGMII_PHY1_ADDR                        0x3
#define SGMII_PHY2_ADDR                        0x4
#define SGMII_PHY3_ADDR                        0x5

u-boot/configs/ls1046afrwy_tfa_defconfig
CONFIG_PHY_REALTEK=y

0 Kudos
Reply