Thread (19 messages) read the whole thread 19 messages, 6 authors, 2021-10-18

Re: [PATCH net-next 10/11] fddi: use eth_hw_addr_set()

From: "Maciej W. Rozycki" <macro@orcam.me.uk>
Date: 2021-10-18 02:34:34

On Fri, 1 Oct 2021, Jakub Kicinski wrote:
quoted hunk ↗ jump to hunk
diff --git a/drivers/net/fddi/skfp/skfddi.c b/drivers/net/fddi/skfp/skfddi.c
index cc5126ea7ef5..652cb174302e 100644
--- a/drivers/net/fddi/skfp/skfddi.c
+++ b/drivers/net/fddi/skfp/skfddi.c
@@ -433,7 +434,7 @@ static  int skfp_driver_init(struct net_device *dev)
 	}
 	read_address(smc, NULL);
 	pr_debug("HW-Addr: %pMF\n", smc->hw.fddi_canon_addr.a);
-	memcpy(dev->dev_addr, smc->hw.fddi_canon_addr.a, ETH_ALEN);
+	eth_hw_addr_set(dev, smc->hw.fddi_canon_addr.a);
 Hmm, it looks to me like this ought to be abstracted somehow even if it 
ultimately expanded to exactly the same code; note that FDDI_K_ALEN should 
have been used in original code.  Not functionally incorrect however, so I 
guess no need to rush cleaning up.

  Maciej
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help