Skip to contentSkip to conversation

net: wireless: rt2x00: statics code style

PATCH In review Paul McQuade 2 participants 2 messages Oct 17, 2015 – Oct 18, 2015

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: wireless: rt2x00: statics code style

Do not initialise statics to 0 or NULL
Also use tabs where possible

---
 drivers/net/wireless/rt2x00/rt61pci.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/wireless/rt2x00/rt61pci.c +2 -2
index c0e730e..53bd23d 100644
@@ -39,7 +39,7 @@
 /*
  * Allow hardware encryption to be disabled.
  */
-static bool modparam_nohwcrypt = false;
+static bool modparam_nohwcrypt;
 module_param_named(nohwcrypt, modparam_nohwcrypt, bool, S_IRUGO);
 MODULE_PARM_DESC(nohwcrypt, "Disable hardware encryption.");
 
@@ -1388,7 +1388,7 @@ static bool rt61pci_get_entry_state(struct queue_entry *entry)
 		rt2x00_desc_read(entry_priv->desc, 0, &word);
 
 		return (rt2x00_get_field32(word, TXD_W0_OWNER_NIC) ||
-		        rt2x00_get_field32(word, TXD_W0_VALID));
+		rt2x00_get_field32(word, TXD_W0_VALID));
 	}
 }
 
Signature · 1 line
2.6.1
#1 lore raw

Hello.

Quoted 22 lines · Paul McQuade

Do not initialise statics to 0 or NULL
Also use tabs where possible

---
  drivers/net/wireless/rt2x00/rt61pci.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/wireless/rt2x00/rt61pci.c +1 -1
index c0e730e..53bd23d 100644
@@ -39,7 +39,7 @@
  /*
   * Allow hardware encryption to be disabled.
   */
-static bool modparam_nohwcrypt = false;
+static bool modparam_nohwcrypt;
  module_param_named(nohwcrypt, modparam_nohwcrypt, bool, S_IRUGO);
  MODULE_PARM_DESC(nohwcrypt, "Disable hardware encryption.");
 

drivers/net/wireless/rt2x00/rt61pci.c static bool rt61pci_get_entry_state(struct queue_entry *entry) · line 1391

Quoted 5 lines
drivers/net/wireless/rt2x00/rt61pci.c +1 -1
@@ -1388,7 +1388,7 @@ static bool rt61pci_get_entry_state(struct queue_entry *entry)
  		rt2x00_desc_read(entry_priv->desc, 0, &word);
 
  		return (rt2x00_get_field32(word, TXD_W0_OWNER_NIC) ||
-		        rt2x00_get_field32(word, TXD_W0_VALID));
+		rt2x00_get_field32(word, TXD_W0_VALID));

This line should indented more, like it was before. And the outer parens
aren't needed.

MBR, Sergei