Commit 5c726166 authored by Chaithrika U S's avatar Chaithrika U S Committed by David S. Miller

TI DaVinci EMAC: Remove print_mac, DECLARE_MAC_BUF

Use printk format specifier for MAC address.
Remove DECALRE_MAC_BUF and print_mac() usage in the driver.
Signed-off-by: default avatarChaithrika U S <chaithrika@ti.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c722c625
...@@ -1819,7 +1819,6 @@ static int emac_dev_setmac_addr(struct net_device *ndev, void *addr) ...@@ -1819,7 +1819,6 @@ static int emac_dev_setmac_addr(struct net_device *ndev, void *addr)
struct emac_rxch *rxch = priv->rxch[EMAC_DEF_RX_CH]; struct emac_rxch *rxch = priv->rxch[EMAC_DEF_RX_CH];
struct device *emac_dev = &priv->ndev->dev; struct device *emac_dev = &priv->ndev->dev;
struct sockaddr *sa = addr; struct sockaddr *sa = addr;
DECLARE_MAC_BUF(mac);
/* Store mac addr in priv and rx channel and set it in EMAC hw */ /* Store mac addr in priv and rx channel and set it in EMAC hw */
memcpy(priv->mac_addr, sa->sa_data, ndev->addr_len); memcpy(priv->mac_addr, sa->sa_data, ndev->addr_len);
...@@ -1828,8 +1827,8 @@ static int emac_dev_setmac_addr(struct net_device *ndev, void *addr) ...@@ -1828,8 +1827,8 @@ static int emac_dev_setmac_addr(struct net_device *ndev, void *addr)
emac_setmac(priv, EMAC_DEF_RX_CH, rxch->mac_addr); emac_setmac(priv, EMAC_DEF_RX_CH, rxch->mac_addr);
if (netif_msg_drv(priv)) if (netif_msg_drv(priv))
dev_notice(emac_dev, "DaVinci EMAC: emac_dev_setmac_addr %s\n", dev_notice(emac_dev, "DaVinci EMAC: emac_dev_setmac_addr %pM\n",
print_mac(mac, priv->mac_addr)); priv->mac_addr);
return 0; return 0;
} }
...@@ -2683,11 +2682,10 @@ static int __devinit davinci_emac_probe(struct platform_device *pdev) ...@@ -2683,11 +2682,10 @@ static int __devinit davinci_emac_probe(struct platform_device *pdev)
ndev->irq = res->start; ndev->irq = res->start;
if (!is_valid_ether_addr(priv->mac_addr)) { if (!is_valid_ether_addr(priv->mac_addr)) {
DECLARE_MAC_BUF(buf);
/* Use random MAC if none passed */ /* Use random MAC if none passed */
random_ether_addr(priv->mac_addr); random_ether_addr(priv->mac_addr);
printk(KERN_WARNING "%s: using random MAC addr: %s\n", printk(KERN_WARNING "%s: using random MAC addr: %pM\n",
__func__, print_mac(buf, priv->mac_addr)); __func__, priv->mac_addr);
} }
ndev->netdev_ops = &emac_netdev_ops; ndev->netdev_ops = &emac_netdev_ops;
......
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