diff mbox

[1/2] net: stmmac: Silence PTP init errors on hw without PTP

Message ID 1390747844-25060-1-git-send-email-hdegoede@redhat.com
State Accepted, archived
Delegated to: David Miller
Headers show

Commit Message

Hans de Goede Jan. 26, 2014, 2:50 p.m. UTC
Logging a PTP error on hw which simply does not support PTP is not very
useful. Moreover this message gets logged on every if-up, and if there is
no cable inserted NetworkManager will re-try the ifup every 50 seconds.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

David Miller Jan. 27, 2014, 6:42 a.m. UTC | #1
From: Hans de Goede <hdegoede@redhat.com>
Date: Sun, 26 Jan 2014 15:50:43 +0100

> Logging a PTP error on hw which simply does not support PTP is not very
> useful. Moreover this message gets logged on every if-up, and if there is
> no cable inserted NetworkManager will re-try the ifup every 50 seconds.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

Applied.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index ff514b5..838d0b7 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -1687,7 +1687,7 @@  static int stmmac_open(struct net_device *dev)
 	stmmac_mmc_setup(priv);
 
 	ret = stmmac_init_ptp(priv);
-	if (ret)
+	if (ret && ret != -EOPNOTSUPP)
 		pr_warn("%s: failed PTP initialisation\n", __func__);
 
 #ifdef CONFIG_STMMAC_DEBUG_FS