Message ID | 20240820004436.224603-1-florian.fainelli@broadcom.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 4d36b2b1dea4ff528bd7d312d9c713a827656d75 |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [net-next] net: dsa: b53: Use dev_err_probe() | expand |
On Mon, Aug 19, 2024 at 05:44:35PM -0700, Florian Fainelli wrote: > Rather than print an error even when we get -EPROBE_DEFER, use > dev_err_probe() to filter out those messages. > > Link: https://github.com/openwrt/openwrt/pull/11680 > Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Andrew
Hello: This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <kuba@kernel.org>: On Mon, 19 Aug 2024 17:44:35 -0700 you wrote: > Rather than print an error even when we get -EPROBE_DEFER, use > dev_err_probe() to filter out those messages. > > Link: https://github.com/openwrt/openwrt/pull/11680 > Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com> > --- > drivers/net/dsa/b53/b53_mdio.c | 7 +++---- > 1 file changed, 3 insertions(+), 4 deletions(-) Here is the summary with links: - [net-next] net: dsa: b53: Use dev_err_probe() https://git.kernel.org/netdev/net-next/c/4d36b2b1dea4 You are awesome, thank you!
diff --git a/drivers/net/dsa/b53/b53_mdio.c b/drivers/net/dsa/b53/b53_mdio.c index 897e5e8b3d69..31d070bf161a 100644 --- a/drivers/net/dsa/b53/b53_mdio.c +++ b/drivers/net/dsa/b53/b53_mdio.c @@ -343,10 +343,9 @@ static int b53_mdio_probe(struct mdio_device *mdiodev) dev_set_drvdata(&mdiodev->dev, dev); ret = b53_switch_register(dev); - if (ret) { - dev_err(&mdiodev->dev, "failed to register switch: %i\n", ret); - return ret; - } + if (ret) + return dev_err_probe(&mdiodev->dev, ret, + "failed to register switch\n"); return ret; }
Rather than print an error even when we get -EPROBE_DEFER, use dev_err_probe() to filter out those messages. Link: https://github.com/openwrt/openwrt/pull/11680 Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com> --- drivers/net/dsa/b53/b53_mdio.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)