Commit 39c3318c authored by Sergio Paracuellos's avatar Sergio Paracuellos Committed by Greg Kroah-Hartman

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: default avatarSergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 07335253
...@@ -484,16 +484,9 @@ void hostif_mib_get_confirm(struct ks_wlan_private *priv) ...@@ -484,16 +484,9 @@ void hostif_mib_get_confirm(struct ks_wlan_private *priv)
switch (mib_attribute) { switch (mib_attribute) {
case DOT11_MAC_ADDRESS: case DOT11_MAC_ADDRESS:
hostif_sme_enqueue(priv, SME_GET_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; priv->mac_address_valid = true;
dev->dev_addr[0] = priv->eth_addr[0]; ether_addr_copy(dev->dev_addr, priv->eth_addr);
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;
netdev_info(dev, "MAC ADDRESS = %pM\n", priv->eth_addr); netdev_info(dev, "MAC ADDRESS = %pM\n", priv->eth_addr);
break; break;
case DOT11_PRODUCT_VERSION: case DOT11_PRODUCT_VERSION:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment