diff options
author | Guido MartÃnez <guido@vanguardiasur.com.ar> | 2014-04-19 16:45:00 -0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-05-15 13:26:37 -0700 |
commit | bc5cf6563576bb36baa7e93417b9a2e29999a5c6 (patch) | |
tree | da9dc6ca3942286a8ea23ab62e7061df89bc6a78 /drivers/staging/vt6655/wpactl.c | |
parent | 4e8a7e5fc29697f881f5c358f84df52914908703 (diff) |
staging: vt6655: fix checkpatch bracing issues
This patchs fixes tons of warnings such as:
WARNING: braces {} are not necessary for single statement blocks
#354: FILE: drivers/staging/vt6655/wmgr.c:354:
+ for (ii = 0; ii < WLAN_BSSID_LEN; ii++) {
+ pMgmt->abyDesireBSSID[ii] = 0xFF;
+ }
Please note: this patch only fixes bracing issues (and there is still a
lot to do); so if you run checkpatch it _will_ throw a lot of errors.
Use --test-only=braces
Signed-off-by: Guido MartÃnez <guido@vanguardiasur.com.ar>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/vt6655/wpactl.c')
-rw-r--r-- | drivers/staging/vt6655/wpactl.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/drivers/staging/vt6655/wpactl.c b/drivers/staging/vt6655/wpactl.c index 5e0fae0743a5..089e8a7bcfbf 100644 --- a/drivers/staging/vt6655/wpactl.c +++ b/drivers/staging/vt6655/wpactl.c @@ -212,9 +212,9 @@ int wpa_set_keys(PSDevice pDevice, void *ctx, pDevice->byKeyIndex = 0; pDevice->bTransmitKey = false; KeyvRemoveAllWEPKey(&(pDevice->sKey), pDevice->PortOffset); - for (uu = 0; uu < MAX_KEY_TABLE; uu++) { + for (uu = 0; uu < MAX_KEY_TABLE; uu++) MACvDisableKeyEntry(pDevice->PortOffset, uu); - } + return ret; } @@ -283,13 +283,11 @@ int wpa_set_keys(PSDevice pDevice, void *ctx, return -EINVAL; } - if (param->u.wpa_key.alg_name == WPA_ALG_TKIP) { + if (param->u.wpa_key.alg_name == WPA_ALG_TKIP) pDevice->eEncryptionStatus = Ndis802_11Encryption2Enabled; - } - if (param->u.wpa_key.alg_name == WPA_ALG_CCMP) { + if (param->u.wpa_key.alg_name == WPA_ALG_CCMP) pDevice->eEncryptionStatus = Ndis802_11Encryption3Enabled; - } if (param->u.wpa_key.set_tx) dwKeyIndex |= (1 << 31); @@ -639,9 +637,9 @@ static int wpa_get_scan(PSDevice pDevice, if (jj < count) count = jj; - if (copy_to_user(param->u.scan_results.buf, pBuf, sizeof(struct viawget_scan_result) * count)) { + if (copy_to_user(param->u.scan_results.buf, pBuf, sizeof(struct viawget_scan_result) * count)) ret = -EFAULT; - } + param->u.scan_results.scan_count = count; DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO " param->u.scan_results.scan_count = %d\n", count); @@ -703,9 +701,8 @@ static int wpa_set_associate(PSDevice pDevice, // set bssid if (memcmp(param->u.wpa_associate.bssid, &abyNullAddr[0], 6) != 0) memcpy(pMgmt->abyDesireBSSID, param->u.wpa_associate.bssid, 6); - else { + else bScheduleCommand((void *)pDevice, WLAN_CMD_BSSID_SCAN, pItemSSID->abySSID); - } if (param->u.wpa_associate.wpa_ie_len == 0) { if (param->u.wpa_associate.auth_alg & AUTH_ALG_SHARED_KEY) |