TI工程师你们好:
在自己的板子上
移植的版本:
uboot u-boot ( 使用: DEV.MCSDK-2013-01.11)
linux K2_LINUX_03.10.10_14.07
硬件:直接从dsp中引出万兆接口,采用mac to mac 模式(没PHY),接SFP+模块,通过光纤(1m)与PC连接。在PC显示该网络链路为10Gbps
参考如下网址:processors.wiki.ti.com/…/MCSDK_UG_Chapter_Exploring
linux内核设置如下:
配置文件: arch/arm/configs/keystone2_defconfig
CONFIG_TI_KEYSTONE_XGE=y
CONFIG_TI_KEYSTONE_XGE_MDIO=y
参数设置:arch/arm/boot/dts/k2e-net.dtsi
netcpx: netcp@2f00000 {
- status = "ok";
- slaves {
- slave0 {
- link-interface = <11>;
- phy-handle = <&phyx0>;
- };
- slave1 {
- link-interface = <11>;
- phy-handle = <&phyx1>;
- };
- slave0 {
- };
- };
编译内核,烧写, 启动内核后万兆输出如下:
[ 36.773207] keystone-netcp 2090000.netcp: dma_chan_name nettx2
[ 36.779766] keystone-netcp 2090000.netcp: Created interface "eth3"
[ 36.785971] keystone-netcp 2090000.netcp: dma_chan_name nettx3
[ 36.792000] XGE serdes config:
[ 36.795061] ref_clk=156.25MHz, link_rate=10.3125G, lanes=2
[ 36.800742] c1=2, c2=0, cm=2, tx_att=12, tx_vreg=4
[ 36.805720] eq flags: vreg=1, cdfe=1, offset=1
[ 36.810357] XGE: serdes reset
[ 37.941733] XGE: timeout waiting for serdes link up
[ 37.946970] keystone-netcp 2f00000.netcp: Created interface "eth4"
[ 37.953182] keystone-netcp 2f00000.netcp: dma_chan_name xgetx0
[ 37.959042] XGE: serdes reset
[ 39.191584] XGE: timeout waiting for serdes link up
[ 39.196805] keystone-netcp 2f00000.netcp: Created interface "eth5"
[ 39.203018] keystone-netcp 2f00000.netcp: dma_chan_name xgetx1
[ 39.208879] XGE: serdes reset
[ 40.441386] XGE: timeout waiting for serdes link up
关于万兆serdes 没有link up 我跟踪代码发现是 blk_lock = (pcsr_rx_stat >> 30) & 0x1;为0导致的,也就是参考万兆网卡芯片手册寄存器PCSR Receive Status Register (PCSR_Rx_Status)的地31位RX_BLOCK_LOCK不为1导致的,请问出现次问题的原因。
启动完成后,ifconfig 并没发现ETH4网口,在设置ifconfig eth4 up ;ifconfig eth4 192.168.1.2后发现ETH4出现,但是ping 不通对段的电脑。
不知道设置那里存在问题,请指教。
Shine:
请试试升级一下mcsdk
software-dl.ti.com/…/index_FDS.html