staging: rtl8192e: Use netdev_info instead of printk.
PATCH 1/1 staging: rtl8192e: Use netdev_info instead of printk.
This patch uses netdev_info instead of printk(KERN_INFO..) as this is network driver to fix the following checkpatch.pl warning:
WARNING: Prefer netdev_info(netdev, ... then dev_info(dev, ... then pr_info(... to printk(KERN_INFO ...
Signed-off-by Navya Sri Nizamkari <[email protected]>
--- drivers/staging/rtl8192e/rtl8192e/rtl_wx.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-)
drivers/staging/rtl8192e/rtl8192e/rtl_wx.c +9 -9
@@ -254,7 +254,7 @@ static int r8192se_wx_set_radio(struct net_device *dev,down (&priv->wx_sem); -printk (KERN_INFO "%s(): set radio ! extra is %d\n" , __func__, *extra); +netdev_info (dev,"%s(): set radio ! extra is %d\n" , __func__, *extra);if ((*extra !=0 ) && (*extra !=1 )) {RT_TRACE (COMP_ERR ,"%s(): set radio an err value,must 0(radio " "off) or 1(radio on)\n" , __func__);
@@ -277,7 +277,7 @@ static int r8192se_wx_set_lps_awake_interval(struct net_device *dev,down (&priv->wx_sem); -printk (KERN_INFO "%s(): set lps awake interval ! extra is %d\n" , +netdev_info (dev,"%s(): set lps awake interval ! extra is %d\n" , __func__, *extra); pPSC->RegMaxLPSAwakeIntvl = *extra;
@@ -293,7 +293,7 @@ static int r8192se_wx_set_force_lps(struct net_device *dev,down (&priv->wx_sem); -printk (KERN_INFO "%s(): force LPS ! extra is %d (1 is open 0 is " +netdev_info (dev,"%s(): force LPS ! extra is %d (1 is open 0 is " "close)\n" , __func__, *extra); priv->force_lps = *extra;up (&priv->wx_sem);
@@ -311,7 +311,7 @@ static int r8192_wx_set_debugflag(struct net_device *dev,if (priv->bHwRadioOff == true)return 0 ; -printk (KERN_INFO "=====>%s(), *extra:%x, debugflag:%x\n" , __func__, +netdev_info (dev,"=====>%s(), *extra:%x, debugflag:%x\n" , __func__, *extra, rt_global_debug_component);if (c >0 ) rt_global_debug_component |= (1 <<c);
@@ -344,7 +344,7 @@ static int r8192_wx_set_mode(struct net_device *dev, struct iw_request_info *a,up (&priv->wx_sem);return -1 ; }else { -printk (KERN_INFO "=========>%s(): " +netdev_info (dev,"=========>%s(): " "IPSLeave\n" , __func__);down (&priv->rtllib->ips_sem);IPSLeave (dev);
@@ -471,7 +471,7 @@ static int r8192_wx_set_scan(struct net_device *dev, struct iw_request_info *a, }if (priv->bHwRadioOff == true) { -printk (KERN_INFO "================>%s(): hwradio off\n" , +netdev_info (dev,"================>%s(): hwradio off\n" , __func__);return 0 ; }
@@ -573,7 +573,7 @@ static int r8192_wx_set_essid(struct net_device *dev,int ret;if (priv->bHwRadioOff == true) { -printk (KERN_INFO "=========>%s():hw radio off,or Rf state is " +netdev_info (dev,"=========>%s():hw radio off,or Rf state is " "eRfOff, return\n" , __func__);return 0 ; }
@@ -826,7 +826,7 @@ static int r8192_wx_set_enc(struct net_device *dev,set_swcam (dev, key_idx, key_idx,KEY_TYPE_WEP104 , zero_addr[key_idx],0 , hwkey,0 ); }else { -printk (KERN_INFO "wrong type in WEP, not WEP40 and WEP104\n" ); +netdev_info (dev,"wrong type in WEP, not WEP40 and WEP104\n" ); } }
@@ -1148,7 +1148,7 @@ static int r8192_wx_set_PromiscuousMode(struct net_device *dev, (rtllib_EnableIntelPromiscuousMode(dev, false)) : (rtllib_DisableIntelPromiscuousMode (dev, false)); -printk (KERN_INFO "=======>%s(), on = %d, filter src sta = %d\n" , +netdev_info (dev,"=======>%s(), on = %d, filter src sta = %d\n" , __func__, bPromiscuousOn, bFilterSourceStationFrame); }else {return -1 ;
Signature · 1 line
1.9.1
Greg KH
maintainerQuoted 11 lines · Navya Sri Nizamkari
This patch uses
netdev_infoinstead ofprintk(KERN_INFO..)as this is network driver to fix the following checkpatch.pl warning:WARNING: Prefer netdev_info(netdev, ... then dev_info(dev, ... then pr_info(... to printk(KERN_INFO ...
Signed-off-by Navya Sri Nizamkari <[email protected]>--- drivers/staging/rtl8192e/rtl8192e/rtl_wx.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-)
This doesn't apply cleanly to my tree anymore. Can you refresh it against my staging-testing branch of staging.git and resend?
thanks,
greg k-h