Skip to content

Commit 6cef2b8

Browse files
JoePerchesdavem330
authored andcommitted
s2io.c: convert printks to pr_<level>
Fixed trivial typo as well Signed-off-by: Joe Perches <[email protected]> Acked-by: Sreenivasa Honnur <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent d44570e commit 6cef2b8

File tree

1 file changed

+7
-10
lines changed

1 file changed

+7
-10
lines changed

drivers/net/s2io.c

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@
5454
* Possible values '1' for enable and '0' for disable. Default is '0'
5555
************************************************************************/
5656

57+
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
58+
5759
#include <linux/module.h>
5860
#include <linux/types.h>
5961
#include <linux/errno.h>
@@ -5547,8 +5549,7 @@ static int s2io_ethtool_idnic(struct net_device *dev, u32 data)
55475549
if ((sp->device_type == XFRAME_I_DEVICE) && ((subid & 0xFF) < 0x07)) {
55485550
val64 = readq(&bar0->adapter_control);
55495551
if (!(val64 & ADAPTER_CNTL_EN)) {
5550-
printk(KERN_ERR
5551-
"Adapter Link down, cannot blink LED\n");
5552+
pr_err("Adapter Link down, cannot blink LED\n");
55525553
return -EFAULT;
55535554
}
55545555
}
@@ -7130,8 +7131,7 @@ static int s2io_add_isr(struct s2io_nic *sp)
71307131
}
71317132
}
71327133
if (!err) {
7133-
printk(KERN_INFO "MSI-X-RX %d entries enabled\n",
7134-
--msix_rx_cnt);
7134+
pr_info("MSI-X-RX %d entries enabled\n", --msix_rx_cnt);
71357135
DBG_PRINT(INFO_DBG, "MSI-X-TX entries enabled"
71367136
" through alarm vector\n");
71377137
}
@@ -8724,8 +8724,7 @@ static pci_ers_result_t s2io_io_slot_reset(struct pci_dev *pdev)
87248724
struct s2io_nic *sp = netdev_priv(netdev);
87258725

87268726
if (pci_enable_device(pdev)) {
8727-
printk(KERN_ERR "s2io: "
8728-
"Cannot re-enable PCI device after reset.\n");
8727+
pr_err("Cannot re-enable PCI device after reset.\n");
87298728
return PCI_ERS_RESULT_DISCONNECT;
87308729
}
87318730

@@ -8749,15 +8748,13 @@ static void s2io_io_resume(struct pci_dev *pdev)
87498748

87508749
if (netif_running(netdev)) {
87518750
if (s2io_card_up(sp)) {
8752-
printk(KERN_ERR "s2io: "
8753-
"Can't bring device back up after reset.\n");
8751+
pr_err("Can't bring device back up after reset.\n");
87548752
return;
87558753
}
87568754

87578755
if (s2io_set_mac_addr(netdev, netdev->dev_addr) == FAILURE) {
87588756
s2io_card_down(sp);
8759-
printk(KERN_ERR "s2io: "
8760-
"Can't resetore mac addr after reset.\n");
8757+
pr_err("Can't restore mac addr after reset.\n");
87618758
return;
87628759
}
87638760
}

0 commit comments

Comments
 (0)