Skip to contentSkip to conversation

wlan-ng:prism2sta: Changes reporting format to meet checkpatch.pl

PATCH In review [email protected] 2 participants 2 messages Jul 26, 2014 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 wlan-ng:prism2sta: Changes reporting format to meet checkpatch.pl

From: Santiago Torres <[email protected]>

[linux-next]: Make the format strings for netdev_err shorter so they can fit under the 80 column width requirement.

To achieve this, the "result=" was stripped down to an implicit version (i.e. result=%d to (%d)). This allows the whole string to fit inside the 80 column limit to pass some of the checkpatch.pl requirements.

While the error message is not as explicit as it used to be, it shouldn't affect readability; specially since it is the only formatted value printed to the log.

Signed-off by: Santiago Torres-Arias <[email protected]>

---
 drivers/staging/wlan-ng/prism2sta.c |   12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)
drivers/staging/wlan-ng/prism2sta.c +8 -4
index 799ce8a..f05f142 100644
@@ -453,7 +453,8 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate)
 			result = hfa384x_drvr_start(hw);
 			if (result) {
 				netdev_err(wlandev->netdev,
-				       "hfa384x_drvr_start() failed,result=%d\n", (int)result);
+					"hfa384x_drvr_start() failed (%d)\n",
+					(int)result);
 				result =
 				 P80211ENUM_resultcode_implementation_failure;
 				wlandev->msdstate = WLAN_MSD_HWPRESENT;
@@ -496,7 +497,8 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate)
 			result = hfa384x_drvr_start(hw);
 			if (result) {
 				netdev_err(wlandev->netdev,
-				       "hfa384x_drvr_start() failed,result=%d\n", (int)result);
+				       "hfa384x_drvr_start() failed (%d)\n",
+				       (int)result);
 				result =
 				  P80211ENUM_resultcode_implementation_failure;
 				wlandev->msdstate = WLAN_MSD_HWPRESENT;
@@ -506,7 +508,8 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate)
 			result = prism2sta_getcardinfo(wlandev);
 			if (result) {
 				netdev_err(wlandev->netdev,
-				       "prism2sta_getcardinfo() failed,result=%d\n", (int)result);
+				       "prism2sta_getcardinfo() failed (%d)\n",
+				       (int)result);
 				result =
 				  P80211ENUM_resultcode_implementation_failure;
 				hfa384x_drvr_stop(hw);
@@ -516,7 +519,8 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate)
 			result = prism2sta_globalsetup(wlandev);
 			if (result) {
 				netdev_err(wlandev->netdev,
-				       "prism2sta_globalsetup() failed,result=%d\n", (int)result);
+				       "prism2sta_globalsetup() failed (%d)\n",
+				       (int)result);
 				result =
 				  P80211ENUM_resultcode_implementation_failure;
 				hfa384x_drvr_stop(hw);
Signature · 1 line
1.7.9.5
#1 lore raw
Quoted 4 lines · On Sat, Jul 26, 2014 at 04:09:24PM -0400, [email protected] wrote:

From: Santiago Torres <[email protected]>

[linux-next]: Make the format strings for netdev_err shorter so they can fit under the 80 column width requirement.

We do not have that requirement for strings at all, so no need to make this change.

greg k-h