Commit d215ab4d authored by Vladimir Oltean's avatar Vladimir Oltean Committed by Jakub Kicinski

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: default avatarVladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20231213152712.320842-2-vladimir.oltean@nxp.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent b3cb7a83
......@@ -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;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment