]> git.baikalelectronics.ru Git - uboot.git/commit
net: phy: Fix rgmii-id phy reset timeout issue
authorT Karthik Reddy <t.karthik.reddy@xilinx.com>
Tue, 29 Mar 2022 14:05:57 +0000 (16:05 +0200)
committerMichal Simek <michal.simek@xilinx.com>
Tue, 5 Apr 2022 13:10:54 +0000 (15:10 +0200)
commit185f140afad7c51457b189ca22c7efde75931b6b
tree111536364dac4dae489f072b3512f255b476ee6b
parent54875236df305d939388091b02f97d096eee0601
net: phy: Fix rgmii-id phy reset timeout issue

While creating a phy device using phy_device_create(), we need to
provide a valid phyaddr instead of 0 causing phy address being
registered as 0 with mdio bus and shows mdio phy list as below

ZynqMP>  mdio list
eth0:
0 - TI DP83867 <--> ethernet@ff0b0000
eth1:
0 - TI DP83867 <--> ethernet@ff0c0000

Also PHY soft reset is being requested on 0 instead of valid
address causing "PHY reset timed out" error.

So add phyaddr argument to phy_connect_phy_id() and to its prototype
to create phy device with valid phyaddress.

Fixes: 04958075bbbe ("net: phy: Add support for ethernet-phy-id with gpio reset")
Signed-off-by: T Karthik Reddy <t.karthik.reddy@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Link: https://lore.kernel.org/r/fe35fddb9faa5af577ffdfabaec6879c935a30f8.1648562755.git.michal.simek@xilinx.com
drivers/net/phy/ethernet_id.c
drivers/net/phy/phy.c
include/phy.h