[PATCH 1/1] wilc1000: wilc_wfi_cfgoperations.c: fixed brace coding style issues

2015-08-04 Thread Daniel Machon
Fixed brace coding styles issues

Signed-off-by: Daniel Machon 
---
 drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 11 +--
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c 
b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
index 92064db..23097ee 100644
--- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
+++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
@@ -1216,8 +1216,8 @@ static int WILC_WFI_add_key(struct wiphy *wiphy, struct 
net_device *netdev, u8 k
 
 
 
-   if (!pairwise)
-   {
+   if (!pairwise) {
+
if (params->cipher == WLAN_CIPHER_SUITE_TKIP)
u8gmode = ENCRYPT_ENABLED | WPA | TKIP;
else
@@ -1315,8 +1315,8 @@ static int WILC_WFI_add_key(struct wiphy *wiphy, struct 
net_device *netdev, u8 k
 
{
u8mode = 0;
-   if (!pairwise)
-   {
+   if (!pairwise) {
+
if (params->key_len > 16 && params->cipher == 
WLAN_CIPHER_SUITE_TKIP) {
/* swap the tx mic by rx mic */
pu8RxMic = params->key + 24;
@@ -1542,8 +1542,7 @@ static int WILC_WFI_get_key(struct wiphy *wiphy, struct 
net_device *netdev, u8 k
priv = wiphy_priv(wiphy);
 
 
-   if (!pairwise)
-   {
+   if (!pairwise) {
PRINT_D(CFG80211_DBG, "Getting group key idx: %x\n", key_index);
 
key_params.key = priv->wilc_gtk[key_index]->key;
-- 
2.1.4

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH 1/1] wilc1000: wilc_wfi_cfgoperations.c: Fixed initialization of global boolean.

2015-08-04 Thread Daniel Machon
Globals are initialized to zero or NULL by GCC. No need to explicitly 
initialize them.

Signed-off-by: Daniel Machon 
---
 drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c 
b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
index 23097ee..5f233e1 100644
--- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
+++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
@@ -112,7 +112,7 @@ u8 u8P2P_oui[] = {0x50, 0x6f, 0x9A, 0x09};
 u8 u8P2Plocalrandom = 0x01;
 u8 u8P2Precvrandom = 0x00;
 u8 u8P2P_vendorspec[] = {0xdd, 0x05, 0x00, 0x08, 0x40, 0x03};
-bool bWilc_ie = false;
+bool bWilc_ie;
 #endif
 
 static struct ieee80211_supported_band WILC_WFI_band_2ghz = {
@@ -135,9 +135,9 @@ struct add_key_params g_add_ptk_key_params;
 struct wilc_wfi_key g_key_ptk_params;
 struct wilc_wfi_wep_key g_key_wep_params;
 u8 g_flushing_in_progress;
-bool g_ptk_keys_saved = false;
-bool g_gtk_keys_saved = false;
-bool g_wep_keys_saved = false;
+bool g_ptk_keys_saved;
+bool g_gtk_keys_saved;
+bool g_wep_keys_saved;
 
 #define AGING_TIME (9 * 1000)
 #define duringIP_TIME 15000
-- 
2.1.4

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH] staging: wilc1000: wilc_cfgoperations.c: Fixed coding styles issues.

2015-08-04 Thread Daniel Machon
Fixed coding styles issues with braces.

Signed-off-by: Daniel Machon 
---
 drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 6 ++
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c 
b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
index 92064db..bc289ca 100644
--- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
+++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
@@ -1216,8 +1216,7 @@ static int WILC_WFI_add_key(struct wiphy *wiphy, struct 
net_device *netdev, u8 k
 
 
 
-   if (!pairwise)
-   {
+   if (!pairwise) {
if (params->cipher == WLAN_CIPHER_SUITE_TKIP)
u8gmode = ENCRYPT_ENABLED | WPA | TKIP;
else
@@ -1315,8 +1314,7 @@ static int WILC_WFI_add_key(struct wiphy *wiphy, struct 
net_device *netdev, u8 k
 
{
u8mode = 0;
-   if (!pairwise)
-   {
+   if (!pairwise) {
if (params->key_len > 16 && params->cipher == 
WLAN_CIPHER_SUITE_TKIP) {
/* swap the tx mic by rx mic */
pu8RxMic = params->key + 24;
-- 
2.1.4

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH] Staging: lustre/lnet/selftest: framework.c: Fixed coding style issues

2015-08-08 Thread Daniel Machon
Fixed coding style issues where statement should be on the next line

Signed-off-by: Daniel Machon 
---
 drivers/staging/lustre/lnet/selftest/framework.c | 12 
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/lustre/lnet/selftest/framework.c 
b/drivers/staging/lustre/lnet/selftest/framework.c
index 7c5185a..257de35 100644
--- a/drivers/staging/lustre/lnet/selftest/framework.c
+++ b/drivers/staging/lustre/lnet/selftest/framework.c
@@ -203,7 +203,8 @@ sfw_deactivate_session(void)
sfw_batch_t *tsb;
sfw_test_case_t *tsc;
 
-   if (sn == NULL) return;
+   if (sn == NULL)
+   return;
 
LASSERT(!sn->sn_timer_active);
 
@@ -613,7 +614,8 @@ sfw_destroy_test_instance(sfw_test_instance_t *tsi)
srpc_client_rpc_t *rpc;
sfw_test_unit_t *tsu;
 
-   if (!tsi->tsi_is_client) goto clean;
+   if (!tsi->tsi_is_client)
+   goto clean;
 
tsi->tsi_ops->tso_fini(tsi);
 
@@ -1700,7 +1702,8 @@ sfw_startup(void)
 
for (i = 0; ; i++) {
sv = &sfw_services[i];
-   if (sv->sv_name == NULL) break;
+   if (sv->sv_name == NULL)
+   break;
 
sv->sv_bulk_ready = NULL;
sv->sv_handler= sfw_handle_server_rpc;
@@ -1717,7 +1720,8 @@ sfw_startup(void)
}
 
/* about to sfw_shutdown, no need to add buffer */
-   if (error) continue;
+   if (error)
+   continue;
 
rc = srpc_service_add_buffers(sv, sv->sv_wi_total);
if (rc != 0) {
-- 
2.1.4

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH 2/2] Staging: lustre/lustre/ptlrpc: service.c: Fixed issue with global integer being initialized to 0

2015-08-08 Thread Daniel Machon
Fixed global integer initialization issue.
Global variables should not be explicitly initialized to 0 or NULL.

Signed-off-by: Daniel Machon 
---
 drivers/staging/lustre/lustre/ptlrpc/service.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/lustre/lustre/ptlrpc/service.c 
b/drivers/staging/lustre/lustre/ptlrpc/service.c
index 9117f1c..11e1ada 100644
--- a/drivers/staging/lustre/lustre/ptlrpc/service.c
+++ b/drivers/staging/lustre/lustre/ptlrpc/service.c
@@ -43,7 +43,7 @@
 #include "ptlrpc_internal.h"
 
 /* The following are visible and mutable through /sys/module/ptlrpc */
-int test_req_buffer_pressure = 0;
+int test_req_buffer_pressure;
 module_param(test_req_buffer_pressure, int, 0444);
 MODULE_PARM_DESC(test_req_buffer_pressure, "set non-zero to put pressure on 
request buffer pools");
 module_param(at_min, int, 0644);
-- 
2.1.4

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel