This patch series fix some style issues in several source and header files.
Sergio Paracuellos (5):
staging: wlan-ng: add spaces around or operator :
HOSTWEP_DEFAULTKEY_MASK
staging: wlan-ng: remove two unnecessary blank lines
staging: wlan-ng: change comparison to NULL to preferred style.
staging: wlan-ng: remove unnecessary parentheses
staging: wlan-ng: remove unnecessary blank line
drivers/staging/wlan-ng/p80211netdev.c | 2 --
drivers/staging/wlan-ng/p80211netdev.h | 2 +-
drivers/staging/wlan-ng/p80211req.c | 7 +++----
3 files changed, 4 insertions(+), 7 deletions(-)
--
1.9.1
Add spaces around or operator to comply with the standard
kernel coding style.
Signed-off-by: Sergio Paracuellos <[email protected]>
---
drivers/staging/wlan-ng/p80211netdev.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/wlan-ng/p80211netdev.h b/drivers/staging/wlan-ng/p80211netdev.h
index 972e076..8066ac4 100644
--- a/drivers/staging/wlan-ng/p80211netdev.h
+++ b/drivers/staging/wlan-ng/p80211netdev.h
@@ -143,7 +143,7 @@ struct p80211_frmrx {
#define NUM_WEPKEYS 4
#define MAX_KEYLEN 32
-#define HOSTWEP_DEFAULTKEY_MASK (BIT(1)|BIT(0))
+#define HOSTWEP_DEFAULTKEY_MASK (BIT(1) | BIT(0))
#define HOSTWEP_SHAREDKEY BIT(3)
#define HOSTWEP_DECRYPT BIT(4)
#define HOSTWEP_ENCRYPT BIT(5)
--
1.9.1
Comparison to NULL could be written in preferred form.
Change it to comply with the standard kernel coding style.
Signed-off-by: Sergio Paracuellos <[email protected]>
---
drivers/staging/wlan-ng/p80211req.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/wlan-ng/p80211req.c b/drivers/staging/wlan-ng/p80211req.c
index b3b33d2e..3414fd8 100644
--- a/drivers/staging/wlan-ng/p80211req.c
+++ b/drivers/staging/wlan-ng/p80211req.c
@@ -141,7 +141,7 @@ int p80211req_dorequest(struct wlandevice *wlandev, u8 *msgbuf)
p80211req_handlemsg(wlandev, msg);
/* Pass it down to wlandev via wlandev->mlmerequest */
- if (wlandev->mlmerequest != NULL)
+ if (wlandev->mlmerequest)
wlandev->mlmerequest(wlandev, msg);
clear_bit(1, &(wlandev->request_pending));
--
1.9.1
Blank lines aren't necessary after an open brace '{'.
Clean them in p80211req.c source file to comply with
the standard kernel coding style.
Signed-off-by: Sergio Paracuellos <[email protected]>
---
drivers/staging/wlan-ng/p80211req.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/staging/wlan-ng/p80211req.c b/drivers/staging/wlan-ng/p80211req.c
index e9fbe18..c4d8e1b 100644
--- a/drivers/staging/wlan-ng/p80211req.c
+++ b/drivers/staging/wlan-ng/p80211req.c
@@ -171,7 +171,6 @@ static void p80211req_handlemsg(struct wlandevice *wlandev,
struct p80211msg *msg)
{
switch (msg->msgcode) {
-
case DIDmsg_lnxreq_hostwep:{
struct p80211msg_lnxreq_hostwep *req =
(struct p80211msg_lnxreq_hostwep *)msg;
--
1.9.1
Avoid no necessary parentheses to comply with the standard kernel
coding style.
Signed-off-by: Sergio Paracuellos <[email protected]>
---
drivers/staging/wlan-ng/p80211req.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/wlan-ng/p80211req.c b/drivers/staging/wlan-ng/p80211req.c
index 3414fd8..e9fbe18 100644
--- a/drivers/staging/wlan-ng/p80211req.c
+++ b/drivers/staging/wlan-ng/p80211req.c
@@ -132,7 +132,7 @@ int p80211req_dorequest(struct wlandevice *wlandev, u8 *msgbuf)
}
/* Check for busy status */
- if (test_and_set_bit(1, &(wlandev->request_pending)))
+ if (test_and_set_bit(1, &wlandev->request_pending))
return -EBUSY;
/* Allow p80211 to look at msg and handle if desired. */
@@ -144,7 +144,7 @@ int p80211req_dorequest(struct wlandevice *wlandev, u8 *msgbuf)
if (wlandev->mlmerequest)
wlandev->mlmerequest(wlandev, msg);
- clear_bit(1, &(wlandev->request_pending));
+ clear_bit(1, &wlandev->request_pending);
return 0; /* if result==0, msg->status still may contain an err */
}
--
1.9.1
After open brace or before close brace blank lines are not really
necessary. Remove them.
Signed-off-by: Sergio Paracuellos <[email protected]>
---
drivers/staging/wlan-ng/p80211netdev.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/wlan-ng/p80211netdev.c b/drivers/staging/wlan-ng/p80211netdev.c
index 10dacf8..ae6e635 100644
--- a/drivers/staging/wlan-ng/p80211netdev.c
+++ b/drivers/staging/wlan-ng/p80211netdev.c
@@ -277,7 +277,6 @@ static void p80211netdev_rx_bh(unsigned long arg)
/* Let's empty our our queue */
while ((skb = skb_dequeue(&wlandev->nsd_rxq))) {
if (wlandev->state == WLAN_DEVICE_OPEN) {
-
if (dev->type != ARPHRD_ETHER) {
/* RAW frame; we shouldn't convert it */
/* XXX Append the Prism Header here instead. */
@@ -461,7 +460,6 @@ static void p80211knetdev_set_multicast_list(struct net_device *dev)
if (wlandev->set_multicast_list)
wlandev->set_multicast_list(wlandev, dev);
-
}
#ifdef SIOCETHTOOL
--
1.9.1