e1000e: resolve checkpatch PREFER_PR_LEVEL warning
authorBruce Allan <bruce.w.allan@intel.com>
Sat, 12 Jan 2013 03:11:25 +0000 (03:11 +0000)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Wed, 16 Jan 2013 08:01:50 +0000 (00:01 -0800)
WARNING: Prefer netdev_info(netdev, ... then dev_info(dev, ...
then pr_info(...  to printk(KERN_INFO ...

v2 - remove unnecessary "e1000e:" prefix as pointed out by Joe Perches
     since that produces a redundant "e1000e:" in the log message

Cc: Joe Perches <joe@perches.com>
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/e1000e/netdev.c

index 7ad8ef639cea4cc79ff3603bbe1b28c88579e21e..b22eb049e27d55e6cc37ed2057f1bc9175df487b 100644 (file)
@@ -4300,9 +4300,8 @@ static void e1000_print_link_info(struct e1000_adapter *adapter)
        u32 ctrl = er32(CTRL);
 
        /* Link status message must follow this format for user tools */
-       printk(KERN_INFO "e1000e: %s NIC Link is Up %d Mbps %s Duplex, Flow Control: %s\n",
-               adapter->netdev->name,
-               adapter->link_speed,
+       pr_info("%s NIC Link is Up %d Mbps %s Duplex, Flow Control: %s\n",
+               adapter->netdev->name, adapter->link_speed,
                adapter->link_duplex == FULL_DUPLEX ? "Full" : "Half",
                (ctrl & E1000_CTRL_TFCE) && (ctrl & E1000_CTRL_RFCE) ? "Rx/Tx" :
                (ctrl & E1000_CTRL_RFCE) ? "Rx" :
@@ -4521,8 +4520,7 @@ static void e1000_watchdog_task(struct work_struct *work)
                        adapter->link_speed = 0;
                        adapter->link_duplex = 0;
                        /* Link status message must follow this format */
-                       printk(KERN_INFO "e1000e: %s NIC Link is Down\n",
-                              adapter->netdev->name);
+                       pr_info("%s NIC Link is Down\n", adapter->netdev->name);
                        netif_carrier_off(netdev);
                        if (!test_bit(__E1000_DOWN, &adapter->state))
                                mod_timer(&adapter->phy_info_timer,