mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-13 23:29:10 -04:00
staging: ks7010: use ether_addr_copy in hostif_mib_get_confirm
This commit improves readability changing custom ethernet addresses copies in favour of using ether_addr_copy() function. Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
07335253e1
commit
39c3318c67
@@ -484,16 +484,9 @@ void hostif_mib_get_confirm(struct ks_wlan_private *priv)
|
||||
switch (mib_attribute) {
|
||||
case DOT11_MAC_ADDRESS:
|
||||
hostif_sme_enqueue(priv, SME_GET_MAC_ADDRESS);
|
||||
memcpy(priv->eth_addr, priv->rxp, ETH_ALEN);
|
||||
ether_addr_copy(priv->eth_addr, priv->rxp);
|
||||
priv->mac_address_valid = true;
|
||||
dev->dev_addr[0] = priv->eth_addr[0];
|
||||
dev->dev_addr[1] = priv->eth_addr[1];
|
||||
dev->dev_addr[2] = priv->eth_addr[2];
|
||||
dev->dev_addr[3] = priv->eth_addr[3];
|
||||
dev->dev_addr[4] = priv->eth_addr[4];
|
||||
dev->dev_addr[5] = priv->eth_addr[5];
|
||||
dev->dev_addr[6] = 0x00;
|
||||
dev->dev_addr[7] = 0x00;
|
||||
ether_addr_copy(dev->dev_addr, priv->eth_addr);
|
||||
netdev_info(dev, "MAC ADDRESS = %pM\n", priv->eth_addr);
|
||||
break;
|
||||
case DOT11_PRODUCT_VERSION:
|
||||
|
||||
Reference in New Issue
Block a user