Commit b2ba08e6 authored by Joe Perches's avatar Joe Perches Committed by David S. Miller

forcedeth: Convert dev_printk(<level> to dev_<level>(

Use vsprintf extension %pM for a mac address in one instance.
Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent cd66328b
...@@ -5442,8 +5442,7 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i ...@@ -5442,8 +5442,7 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i
} }
} }
if (i == DEVICE_COUNT_RESOURCE) { if (i == DEVICE_COUNT_RESOURCE) {
dev_printk(KERN_INFO, &pci_dev->dev, dev_info(&pci_dev->dev, "Couldn't find register window\n");
"Couldn't find register window\n");
goto out_relreg; goto out_relreg;
} }
...@@ -5459,12 +5458,12 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i ...@@ -5459,12 +5458,12 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i
np->txrxctl_bits = NVREG_TXRXCTL_DESC_3; np->txrxctl_bits = NVREG_TXRXCTL_DESC_3;
if (dma_64bit) { if (dma_64bit) {
if (pci_set_dma_mask(pci_dev, DMA_BIT_MASK(39))) if (pci_set_dma_mask(pci_dev, DMA_BIT_MASK(39)))
dev_printk(KERN_INFO, &pci_dev->dev, dev_info(&pci_dev->dev,
"64-bit DMA failed, using 32-bit addressing\n"); "64-bit DMA failed, using 32-bit addressing\n");
else else
dev->features |= NETIF_F_HIGHDMA; dev->features |= NETIF_F_HIGHDMA;
if (pci_set_consistent_dma_mask(pci_dev, DMA_BIT_MASK(39))) { if (pci_set_consistent_dma_mask(pci_dev, DMA_BIT_MASK(39))) {
dev_printk(KERN_INFO, &pci_dev->dev, dev_info(&pci_dev->dev,
"64-bit DMA (consistent) failed, using 32-bit ring buffers\n"); "64-bit DMA (consistent) failed, using 32-bit ring buffers\n");
} }
} }
...@@ -5595,11 +5594,11 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i ...@@ -5595,11 +5594,11 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i
* Bad mac address. At least one bios sets the mac address * Bad mac address. At least one bios sets the mac address
* to 01:23:45:67:89:ab * to 01:23:45:67:89:ab
*/ */
dev_printk(KERN_ERR, &pci_dev->dev, dev_err(&pci_dev->dev,
"Invalid Mac address detected: %pM\n", "Invalid MAC address detected: %pM\n",
dev->dev_addr); dev->dev_addr);
dev_printk(KERN_ERR, &pci_dev->dev, dev_err(&pci_dev->dev,
"Please complain to your hardware vendor. Switching to a random MAC.\n"); "Please complain to your hardware vendor. Switched to a random MAC address.\n");
random_ether_addr(dev->dev_addr); random_ether_addr(dev->dev_addr);
} }
...@@ -5752,8 +5751,7 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i ...@@ -5752,8 +5751,7 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i
break; break;
} }
if (i == 33) { if (i == 33) {
dev_printk(KERN_INFO, &pci_dev->dev, dev_info(&pci_dev->dev, "open: Could not find a valid PHY\n");
"open: Could not find a valid PHY.\n");
goto out_error; goto out_error;
} }
...@@ -5774,24 +5772,14 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i ...@@ -5774,24 +5772,14 @@ static int __devinit nv_probe(struct pci_dev *pci_dev, const struct pci_device_i
err = register_netdev(dev); err = register_netdev(dev);
if (err) { if (err) {
dev_printk(KERN_INFO, &pci_dev->dev, dev_info(&pci_dev->dev, "unable to register netdev: %d\n", err);
"unable to register netdev: %d\n", err);
goto out_error; goto out_error;
} }
dev_printk(KERN_INFO, &pci_dev->dev, "ifname %s, PHY OUI 0x%x @ %d, " dev_info(&pci_dev->dev, "ifname %s, PHY OUI 0x%x @ %d, addr %pM\n",
"addr %2.2x:%2.2x:%2.2x:%2.2x:%2.2x:%2.2x\n", dev->name, np->phy_oui, np->phyaddr, dev->dev_addr);
dev->name,
np->phy_oui,
np->phyaddr,
dev->dev_addr[0],
dev->dev_addr[1],
dev->dev_addr[2],
dev->dev_addr[3],
dev->dev_addr[4],
dev->dev_addr[5]);
dev_printk(KERN_INFO, &pci_dev->dev, "%s%s%s%s%s%s%s%s%s%sdesc-v%u\n", dev_info(&pci_dev->dev, "%s%s%s%s%s%s%s%s%s%sdesc-v%u\n",
dev->features & NETIF_F_HIGHDMA ? "highdma " : "", dev->features & NETIF_F_HIGHDMA ? "highdma " : "",
dev->features & (NETIF_F_IP_CSUM | NETIF_F_SG) ? dev->features & (NETIF_F_IP_CSUM | NETIF_F_SG) ?
"csum " : "", "csum " : "",
......
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