[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230417192903.590077-1-vinschen@redhat.com>
Date: Mon, 17 Apr 2023 21:29:03 +0200
From: Corinna Vinschen <vinschen@...hat.com>
To: netdev@...r.kernel.org,
Giuseppe Cavallaro <peppe.cavallaro@...com>,
alexandre.torgue@...s.st.com, Jose Abreu <joabreu@...opsys.com>,
Jakub Kicinski <kuba@...nel.org>
Subject: [PATCH net-next] stmmac: fix changing mac address
Without the IFF_LIVE_ADDR_CHANGE flag being set, the network code
disallows changing the mac address while the interface is UP.
Consequences are, for instance, that the interface can't be used
in a failover bond.
Add the missing flag to net_device priv_flags.
Tested on Intel Elkhart Lake with default settings, as well as with
failover and alb mode bonds.
Signed-off-by: Corinna Vinschen <vinschen@...hat.com>
---
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index 8ab67c020a08..02d0bf70c528 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -7279,6 +7279,8 @@ int stmmac_dvr_probe(struct device *device,
if (flow_ctrl)
priv->flow_ctrl = FLOW_AUTO; /* RX/TX pause on */
+ ndev->priv_flags |= IFF_LIVE_ADDR_CHANGE;
+
/* Setup channels NAPI */
stmmac_napi_add(ndev);
--
2.31.1
Powered by blists - more mailing lists