If an external PHY uses the CL45 protocol, then phydev->phy_id will be zero. Update the debug message that prints the PHY ID to check the PHY mode and print the PMAPMD MMD PHY ID value for a CL45 PHY.
Also, removing the TODO note, as the CL45 support has been updated to do this. Signed-off-by: Shyam Sundar S K <shyam-sundar....@amd.com> --- drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c b/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c index 46c3c1ca38d6..5b14fc758c2f 100644 --- a/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c +++ b/drivers/net/ethernet/amd/xgbe/xgbe-phy-v2.c @@ -1024,9 +1024,9 @@ static int xgbe_phy_find_phy_device(struct xgbe_prv_data *pdata) return -ENODEV; } netif_dbg(pdata, drv, pdata->netdev, "external PHY id is %#010x\n", - phydev->phy_id); - - /*TODO: If c45, add request_module based on one of the MMD ids? */ + (phy_data->phydev_mode == XGBE_MDIO_MODE_CL45) + ? phydev->c45_ids.device_ids[MDIO_MMD_PMAPMD] + : phydev->phy_id); ret = phy_device_register(phydev); if (ret) { -- 2.25.1