Other Parts Discussed in Thread: DP83TC811
Tool/software: Linux
hi I'm porting dp83tc811 on mdm9607 (linux3.18),but it can not work when ping pc and mdm9607,
my step:
1:
root@mdm9607:/usr/lib/modules# insmod dp83tc811.ko
root@mdm9607:/usr/lib/modules# insmod qcom_emac.ko
console log:
[ 39.559747] start emac_probe
[ 39.580760] stephen go to msm_emac_request_pinctrl_on
[ 39.628262] stephen go to get_phy_id===1=MII_PHYSID1=is:2000
[ 39.633741] stephen go to get_phy_id===1=MII_PHYSID2=is:a253
2:
ifconfig eth0
3:
ifconfig eth0 down
4:
ifconfig eth0 hw ether 00:80:48:BA:d1:30
console log:
[ 173.966215] stephen dev_set_mac_address start
[ 173.969574] stephen go to emac_set_mac_address start
[ 173.975564] stephen go to emac_pm_runtime_resume
[ 173.981020] stephen go to msm_emac_request_pinctrl_on
[ 173.985824] stephen yes phy is external
[ 173.989185] stephen set mdio active
[ 174.643766] stephen go to emac_hw_set_mac_addr
[ 174.648226] stephen go to emac_set_mac_address end
[ 174.653609] stephen dev_set_mac_address end
[ 174.685750] stephen dev_set_rx_mode start
[ 174.689409] stephen dev_set_rx_mode end
[ 174.693452] stephen dev_set_rx_mode over
[ 174.697478] stephen go to emac_open
[ 174.700560] qcom-emac 7c40000.qcom,emac eth0: TX queues 1, TX descriptors 512
[ 174.708127] qcom-emac 7c40000.qcom,emac eth0: RX queues 1, Rx descriptors 256
[ 174.781102] stephen go to emac_sgmii_up
[ 174.785704] stephen go to emac_mac_up phy_connect_direct
[ 174.790190] stephen go to phy_connect_direct
[ 174.899099] stephen go to phy_attach_direct
[ 175.015991] stephen phy_attach_direct111
[ 175.019847] stephen go to phy_init_hw
[ 175.143805] stephen phy_init_hw===2
[ 175.147294] stephen start dp83811_phy_reset
[ 176.757439] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[ 177.587165] stephen phy_state_machine PHY_UP
[ 177.591491] stephen go to phy_start_aneg
[ 179.289282] stephen go to phy_state_machine = 8
[ 179.292998] stephen phy_state_machine PHY_FORCING and read status
[ 179.299600] stephen go to genphy_read_status
[ 179.382409] stephen go to genphy_update_link get link is=:1
[ 179.387515] stephen go to genphy_read_status 1
[ 179.391763] EMAC PHY ADDR 0 PHY RD 0x00 -> 0x2100
[ 179.396532] stephen go to genphy_read_status 3
[ 179.400787] stephen go to genphy_read_status end phydev->speed is:100,phydev->duplex is:1,phydev->pause=0
[ 179.411073] EMAC PHY ADDR 0 PHY RD 0x01 -> 0x0065
[ 179.415084] EMAC PHY ADDR 0 PHY RD 0x01 -> 0x0065
[ 179.460696] qcom-emac 7c40000.qcom,emac eth0: Link is Up - 100Mbps/Full - flow control off
[ 179.473093] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
5:
/ # ifconfig
ifconfig
bridge0 Link encap:Ethernet HWaddr D6:E8:CD:88:DA:2E
inet addr:192.168.225.1 Bcast:192.168.225.255 Mask:255.255.255.0
inet6 addr: fe80::d4e8:cdff:fe85:d72b/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:85 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:6304 (6.1 KiB)
eth0 Link encap:Ethernet HWaddr 00:80:48:BA:D1:30
inet addr:169.254.4.1 Bcast:169.254.4.255 Mask:255.255.255.0
inet6 addr: fe80::280:48ff:feba:d130/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:794 (794.0 B)
Interrupt:108
6:ifconfig eth0 192.168.2.0
7:ping to pc:
ping 192.168.2.37
/ # ifconfig eth0 192.168.2.0
ifconfig eth0 192.168.2.0
/ # ping 192.168.2.37
ping 192.168.2.37
PING 192.168.2.37 (192.168.2.37) 56(84) bytes of data.
From 192.168.2.0 icmp_seq=1 Destination Host Unreachable
From 192.168.2.0 icmp_seq=2 Destination Host Unreachable
From 192.168.2.0 icmp_seq=3 Destination Host Unreachable
From 192.168.2.0 icmp_seq=4 Destination Host Unreachable
From 192.168.2.0 icmp_seq=5 Destination Host Unreachable
From 192.168.2.0 icmp_seq=6 Destination Host Unreachable
From 192.168.2.0 icmp_seq=7 Destination Host Unreachable
From 192.168.2.0 icmp_seq=8 Destination Host Unreachable
From 192.168.2.0 icmp_seq=9 Destination Host Unreachable
get register value:
stephen dp83811_config_aneg c45 test reg[0x000]=2100
[ 177.629815] EMAC PHY ADDR 0 PHY RD 0x09 -> 0x1000
[ 177.634377] stephen dp83811_config_aneg c45 test reg[0x009]=1000
[ 177.640336] EMAC PHY ADDR 0 PHY RD 0x12 -> 0x0000
[ 177.644978] stephen dp83811_config_aneg c45 test reg[0x12]=0
[ 177.650656] EMAC PHY ADDR 0 PHY RD 0x13 -> 0x4000
[ 177.655337] stephen dp83811_config_aneg c45 test reg[0x13]=4000
[ 177.661240] EMAC PHY ADDR 0 PHY RD 0x18 -> 0x0010
[ 177.665886] stephen dp83811_config_aneg c45 test reg[0x18]=10
[ 177.671898] EMAC PHY ADDR 0 PHY RD 0x1f -> 0x0000
[ 177.677087] stephen dp83811_config_aneg c45 test reg[0x1f]=0
[ 177.700964] stephen dp83811_config_aneg c45 test reg[0x198]=34b
[ 177.725785] stephen dp83811_config_aneg c45 test reg[0x432]=0
[ 177.750092] stephen dp83811_config_aneg c45 test reg[0x459]=0
[ 177.774888] stephen dp83811_config_aneg c45 test reg[0x4a0]=a1
[ 177.801529] stephen dp83811_config_aneg c45 test reg[0x4a1]=0
[ 177.852280] stephen dp83811_config_aneg c45 test reg[0x4a2]=0
[ 177.913210] stephen dp83811_config_aneg c45 test reg[0x4a3]=0
[ 177.942802] stephen dp83811_config_aneg c45 test reg[0x4a4]=0
[ 177.953218] stephen dp83811_config_aneg c45 test reg[0x001]=65
[ 177.963717] stephen dp83811_config_aneg c45 test reg[0x000]=2100
[ 177.974734] stephen dp83811_config_aneg c45 test reg[0x012]=0
[ 177.985167] stephen dp83811_config_aneg c45 test reg[0x01f]=0
[ 178.009407] stephen dp83811_config_aneg c45 test reg[0x133]=75ff
[ 178.034294] stephen dp83811_config_aneg c45 test reg[0x18b]=1a
[ 178.058710] stephen dp83811_config_aneg c45 test reg[0x18c]=0
[ 178.083189] stephen dp83811_config_aneg c45 test reg[0x432]=0
[ 178.107894] stephen dp83811_config_aneg c45 test reg[0x467]=300
[ 178.132323] stephen dp83811_config_aneg c45 test reg[0x485]=1078
[ 178.157207] stephen dp83811_config_aneg c45 test reg[ex-0x7]=3d
[ 178.182327] stephen dp83811_config_aneg c45 test reg[ex-0xb]=800
[ 178.188080] EMAC PHY Addr 0 PHY WR 0x0d <- 0x0001
[ 178.206647] stephen dp83811_config_aneg c45 test reg[ex-0x12]=1
[ 178.231105] stephen dp83811_config_aneg c45 test reg[ex-0x834]=c000
[ 178.256256] stephen dp83811_config_aneg c45 test reg[ex-0x836]=0
can not ping pc and mdm9607 ,how to solve the problem?
ifconfig eth0 192.168.2.0
/ # ping 192.168.2.37
ping 192.168.2.37
PING 192.168.2.37 (192.168.2.37) 56(84) bytes of data.
From 192.168.2.0 icmp_seq=1 Destination Host Unreachable
From 192.168.2.0 icmp_seq=2 Destination Host Unreachable
From 192.168.2.0 icmp_seq=3 Destination Host Unreachable
From 192.168.2.0 icmp_seq=4 Destination Host Unreachable
From 192.168.2.0 icmp_seq=5 Destination Host Unreachable
From 192.168.2.0 icmp_seq=6 Destination Host Unreachable
From 192.168.2.0 icmp_seq=7 Destination Host Unreachable
From 192.168.2.0 icmp_seq=8 Destination Host Unreachable
From 192.168.2.0 icmp_seq=9 Destination Host Unreachable
From 192.168.2.0 icmp_seq=10 Destination Host Unreachable