diff options
author | Tony Cho <tony.cho@atmel.com> | 2015-10-20 05:26:53 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-10-25 01:14:35 (GMT) |
commit | 8b8ad7bc90bca63d6bc00b57af1a5f94c1897e12 (patch) | |
tree | 395e474465ae74a218b8b9a2fdaa0dd5001191bf | |
parent | 4875c499dc9b69f64c849677b55f0fc02a461a49 (diff) | |
download | linux-8b8ad7bc90bca63d6bc00b57af1a5f94c1897e12.tar.xz |
staging: wilc1000: rename wilc_firmware in the struct wilc
This patch renames wilc_firmware in the struct wilc to the firmware. In
addition, null assignments to the wl->firmware after release_firmware
are removed because it is not necessary.
Signed-off-by: Tony Cho <tony.cho@atmel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/wilc1000/linux_wlan.c | 15 | ||||
-rw-r--r-- | drivers/staging/wilc1000/wilc_wfi_netdevice.h | 2 |
2 files changed, 8 insertions, 9 deletions
diff --git a/drivers/staging/wilc1000/linux_wlan.c b/drivers/staging/wilc1000/linux_wlan.c index 74b7cc0..16b1d80 100644 --- a/drivers/staging/wilc1000/linux_wlan.c +++ b/drivers/staging/wilc1000/linux_wlan.c @@ -537,7 +537,7 @@ int linux_wlan_get_firmware(perInterface_wlan_t *p_nic) goto _fail_; } #endif - g_linux_wlan->wilc_firmware = wilc_firmware; + g_linux_wlan->firmware = wilc_firmware; _fail_: @@ -594,7 +594,7 @@ static int linux_wlan_firmware_download(struct wilc *p_nic) int ret = 0; - if (g_linux_wlan->wilc_firmware == NULL) { + if (!g_linux_wlan->firmware) { PRINT_ER("Firmware buffer is NULL\n"); ret = -ENOBUFS; goto _FAIL_; @@ -603,16 +603,15 @@ static int linux_wlan_firmware_download(struct wilc *p_nic) * do the firmware download **/ PRINT_D(INIT_DBG, "Downloading Firmware ...\n"); - ret = wilc_wlan_firmware_download(g_linux_wlan->wilc_firmware->data, - g_linux_wlan->wilc_firmware->size); + ret = wilc_wlan_firmware_download(g_linux_wlan->firmware->data, + g_linux_wlan->firmware->size); if (ret < 0) goto _FAIL_; /* Freeing FW buffer */ PRINT_D(INIT_DBG, "Freeing FW buffer ...\n"); PRINT_D(INIT_DBG, "Releasing firmware\n"); - release_firmware(g_linux_wlan->wilc_firmware); - g_linux_wlan->wilc_firmware = NULL; + release_firmware(g_linux_wlan->firmware); PRINT_D(INIT_DBG, "Download Succeeded\n"); @@ -1709,8 +1708,8 @@ void wl_wlan_cleanup(void) nic[i] = netdev_priv(g_linux_wlan->vif[i].ndev); } - if (g_linux_wlan && g_linux_wlan->wilc_firmware) - release_firmware(g_linux_wlan->wilc_firmware); + if (g_linux_wlan && g_linux_wlan->firmware) + release_firmware(g_linux_wlan->firmware); if (g_linux_wlan && (g_linux_wlan->vif[0].ndev || g_linux_wlan->vif[1].ndev)) { diff --git a/drivers/staging/wilc1000/wilc_wfi_netdevice.h b/drivers/staging/wilc1000/wilc_wfi_netdevice.h index b410424..74eb7b6 100644 --- a/drivers/staging/wilc1000/wilc_wfi_netdevice.h +++ b/drivers/staging/wilc1000/wilc_wfi_netdevice.h @@ -182,7 +182,7 @@ struct wilc { unsigned char eth_src_address[NUM_CONCURRENT_IFC][6]; - const struct firmware *wilc_firmware; + const struct firmware *firmware; #ifdef WILC_SDIO struct sdio_func *wilc_sdio_func; |