OSDN Git Service

net: phy: probe for C45 PHYs that return PHY ID of zero in C22 space
authorWong Vee Khee <vee.khee.wong@linux.intel.com>
Mon, 7 Jun 2021 02:36:45 +0000 (10:36 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 10 Jun 2021 19:52:16 +0000 (12:52 -0700)
commitb040aab763236568e198ea193cb8b3e930fd0a37
treec7899992f4407b9fccf0d2c668fb2d9548812f97
parentd409989b59ad0b8d108706db25e17c320a9664eb
net: phy: probe for C45 PHYs that return PHY ID of zero in C22 space

PHY devices such as the Marvell Alaska 88E2110 does not return a valid
PHY ID when probed using Clause-22. The current implementation treats
PHY ID of zero as a non-error and valid PHY ID, and causing the PHY
device failed to bind to the Marvell driver.

For such devices, we do an additional probe in the Clause-45 space,
if a valid PHY ID is returned, we then proceed to attach the PHY
device to the matching PHY ID driver.

Signed-off-by: Wong Vee Khee <vee.khee.wong@linux.intel.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/phy_device.c