diff mbox series

[net-next,2/2] net: dsa: hellcreek: Don't print error message on defer

Message ID 20201121114455.22422-3-kurt@linutronix.de (mailing list archive)
State Accepted
Commit ed5ef9fb2023cb6e6a85ff6617a30acd8df63075
Delegated to: Netdev Maintainers
Headers show
Series net: dsa: hellcreek: Minor cleanups | expand

Checks

Context Check Description
netdev/cover_letter success Link
netdev/fixes_present success Link
netdev/patch_count success Link
netdev/tree_selection success Clearly marked for net-next
netdev/subject_prefix success Link
netdev/source_inline success Was 0 now: 0
netdev/verify_signedoff success Link
netdev/module_param success Was 0 now: 0
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/verify_fixes success Link
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 8 lines checked
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/header_inline success Link
netdev/stable success Stable not CCed

Commit Message

Kurt Kanzenbach Nov. 21, 2020, 11:44 a.m. UTC
When DSA is not loaded when the driver is probed an error message is
printed. But, that's not really an error, just a defer. Use dev_err_probe()
instead.

Signed-off-by: Kurt Kanzenbach <kurt@linutronix.de>
---
 drivers/net/dsa/hirschmann/hellcreek.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Florian Fainelli Nov. 21, 2020, 3:01 p.m. UTC | #1
On 11/21/2020 3:44 AM, Kurt Kanzenbach wrote:
> When DSA is not loaded when the driver is probed an error message is
> printed. But, that's not really an error, just a defer. Use dev_err_probe()
> instead.
> 
> Signed-off-by: Kurt Kanzenbach <kurt@linutronix.de>

Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Vladimir Oltean Nov. 22, 2020, 11:10 p.m. UTC | #2
On Sat, Nov 21, 2020 at 12:44:55PM +0100, Kurt Kanzenbach wrote:
> When DSA is not loaded when the driver is probed an error message is
> printed. But, that's not really an error, just a defer. Use dev_err_probe()
> instead.
> 
> Signed-off-by: Kurt Kanzenbach <kurt@linutronix.de>
> ---

Reviewed-by: Vladimir Oltean <olteanv@gmail.com>
diff mbox series

Patch

diff --git a/drivers/net/dsa/hirschmann/hellcreek.c b/drivers/net/dsa/hirschmann/hellcreek.c
index d42f40c76ba5..6420b76ea37c 100644
--- a/drivers/net/dsa/hirschmann/hellcreek.c
+++ b/drivers/net/dsa/hirschmann/hellcreek.c
@@ -1266,7 +1266,7 @@  static int hellcreek_probe(struct platform_device *pdev)
 
 	ret = dsa_register_switch(hellcreek->ds);
 	if (ret) {
-		dev_err(dev, "Unable to register switch\n");
+		dev_err_probe(dev, ret, "Unable to register switch\n");
 		return ret;
 	}