diff options
author | Vladimir Oltean <vladimir.oltean@nxp.com> | 2023-12-13 16:27:11 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2023-12-15 03:55:38 +0100 |
commit | d215ab4d6ae8bea8f66a50399745791b7de5b7d8 (patch) | |
tree | 5249d4735b918cf821564a7d5c41e563beae7d40 /drivers/net/mdio | |
parent | net: atlantic: eliminate double free in error handling logic (diff) | |
download | linux-d215ab4d6ae8bea8f66a50399745791b7de5b7d8.tar.xz linux-d215ab4d6ae8bea8f66a50399745791b7de5b7d8.zip |
net: mdio-mux: show errors on probe failure
Showing the precise error symbols can help debugging probe issues, such
as the recent -EIO error in of_mdiobus_register() caused by the lack of
bus->read_c45() and bus->write_c45() methods.
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20231213152712.320842-2-vladimir.oltean@nxp.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/mdio')
-rw-r--r-- | drivers/net/mdio/mdio-mux.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/mdio/mdio-mux.c b/drivers/net/mdio/mdio-mux.c index bef4cce71287..e5dee7ad7c09 100644 --- a/drivers/net/mdio/mdio-mux.c +++ b/drivers/net/mdio/mdio-mux.c @@ -190,8 +190,8 @@ int mdio_mux_init(struct device *dev, r = of_property_read_u32(child_bus_node, "reg", &v); if (r) { dev_err(dev, - "Error: Failed to find reg for child %pOF\n", - child_bus_node); + "Error: Failed to find reg for child %pOF: %pe\n", + child_bus_node, ERR_PTR(r)); continue; } @@ -229,8 +229,8 @@ int mdio_mux_init(struct device *dev, } devm_kfree(dev, cb); dev_err(dev, - "Error: Failed to register MDIO bus for child %pOF\n", - child_bus_node); + "Error: Failed to register MDIO bus for child %pOF: %pe\n", + child_bus_node, ERR_PTR(r)); } else { cb->next = pb->children; pb->children = cb; |