diff options
Diffstat (limited to 'drivers/staging/rtl8192e')
-rw-r--r-- | drivers/staging/rtl8192e/dot11d.h | 2 | ||||
-rw-r--r-- | drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 12 | ||||
-rw-r--r-- | drivers/staging/rtl8192e/rtllib_softmac.c | 32 |
3 files changed, 21 insertions, 25 deletions
diff --git a/drivers/staging/rtl8192e/dot11d.h b/drivers/staging/rtl8192e/dot11d.h index aac395f26652..623075cf0c05 100644 --- a/drivers/staging/rtl8192e/dot11d.h +++ b/drivers/staging/rtl8192e/dot11d.h @@ -11,7 +11,7 @@ * * Contact Information: * wlanfae <wlanfae@realtek.com> -******************************************************************************/ + ******************************************************************************/ #ifndef __INC_DOT11D_H #define __INC_DOT11D_H diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c index 8a9172aa8178..4c0caa6701a9 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c @@ -2695,10 +2695,8 @@ static void _rtl92e_pci_disconnect(struct pci_dev *pdev) priv->polling_timer_on = 0; _rtl92e_down(dev, true); rtl92e_dm_deinit(dev); - if (priv->pFirmware) { - vfree(priv->pFirmware); - priv->pFirmware = NULL; - } + vfree(priv->pFirmware); + priv->pFirmware = NULL; _rtl92e_free_rx_ring(dev); for (i = 0; i < MAX_TX_QUEUE_COUNT; i++) _rtl92e_free_tx_ring(dev, i); @@ -2797,9 +2795,9 @@ MODULE_FIRMWARE(RTL8192E_BOOT_IMG_FW); MODULE_FIRMWARE(RTL8192E_MAIN_IMG_FW); MODULE_FIRMWARE(RTL8192E_DATA_IMG_FW); -module_param(ifname, charp, S_IRUGO|S_IWUSR); -module_param(hwwep, int, S_IRUGO|S_IWUSR); -module_param(channels, int, S_IRUGO|S_IWUSR); +module_param(ifname, charp, 0644); +module_param(hwwep, int, 0644); +module_param(channels, int, 0644); MODULE_PARM_DESC(ifname, " Net interface name, wlan%d=default"); MODULE_PARM_DESC(hwwep, " Try to use hardware WEP support(default use hw. set 0 to use software security)"); diff --git a/drivers/staging/rtl8192e/rtllib_softmac.c b/drivers/staging/rtl8192e/rtllib_softmac.c index 1430ba27b049..eeda17d6409b 100644 --- a/drivers/staging/rtl8192e/rtllib_softmac.c +++ b/drivers/staging/rtl8192e/rtllib_softmac.c @@ -3365,23 +3365,21 @@ static int rtllib_wpa_set_encryption(struct rtllib_device *ieee, } else sec.flags &= ~SEC_ACTIVE_KEY; - if (param->u.crypt.alg != NULL) { - memcpy(sec.keys[param->u.crypt.idx], - param->u.crypt.key, - param->u.crypt.key_len); - sec.key_sizes[param->u.crypt.idx] = param->u.crypt.key_len; - sec.flags |= (1 << param->u.crypt.idx); - - if (strcmp(param->u.crypt.alg, "R-WEP") == 0) { - sec.flags |= SEC_LEVEL; - sec.level = SEC_LEVEL_1; - } else if (strcmp(param->u.crypt.alg, "R-TKIP") == 0) { - sec.flags |= SEC_LEVEL; - sec.level = SEC_LEVEL_2; - } else if (strcmp(param->u.crypt.alg, "R-CCMP") == 0) { - sec.flags |= SEC_LEVEL; - sec.level = SEC_LEVEL_3; - } + memcpy(sec.keys[param->u.crypt.idx], + param->u.crypt.key, + param->u.crypt.key_len); + sec.key_sizes[param->u.crypt.idx] = param->u.crypt.key_len; + sec.flags |= (1 << param->u.crypt.idx); + + if (strcmp(param->u.crypt.alg, "R-WEP") == 0) { + sec.flags |= SEC_LEVEL; + sec.level = SEC_LEVEL_1; + } else if (strcmp(param->u.crypt.alg, "R-TKIP") == 0) { + sec.flags |= SEC_LEVEL; + sec.level = SEC_LEVEL_2; + } else if (strcmp(param->u.crypt.alg, "R-CCMP") == 0) { + sec.flags |= SEC_LEVEL; + sec.level = SEC_LEVEL_3; } done: if (ieee->set_security) |