summaryrefslogtreecommitdiffstats
path: root/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
diff options
context:
space:
mode:
authorAlison Schofield <amsfield22@gmail.com>2016-02-12 22:54:08 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-02-14 16:31:44 -0800
commit4375cad941ee9cc8f7c2a467464cd29ec3d9abd1 (patch)
tree521f9ae7b8a7f14b11be8bb599c0a760a7620433 /drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
parentd5c89442d431afa2d5c35a5141b259c4ff5d8c03 (diff)
downloadlinux-4375cad941ee9cc8f7c2a467464cd29ec3d9abd1.tar.gz
linux-4375cad941ee9cc8f7c2a467464cd29ec3d9abd1.tar.xz
staging: wilc1000: wilc_wfi_cfgoperations: remove cast on void pointers
Remove cast on void pointers. C programming language guarantees the conversion from void pointer to any other pointer type. Coccinelle patch: @r@ expression x; void* e; type T; identifier f; @@ ( *((T *)e) | ((T *)x)[...] | ((T *)x)->f | - (T *) e ) Signed-off-by: Alison Schofield <amsfield22@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/wilc1000/wilc_wfi_cfgoperations.c')
-rw-r--r--drivers/staging/wilc1000/wilc_wfi_cfgoperations.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
index 97d1b802a75e..81a2ee9d7c32 100644
--- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
+++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c
@@ -228,7 +228,7 @@ static void refresh_scan(void *user_void, u8 all, bool direct_scan)
int i;
int rssi = 0;
- priv = (struct wilc_priv *)user_void;
+ priv = user_void;
wiphy = priv->dev->ieee80211_ptr->wiphy;
for (i = 0; i < last_scanned_cnt; i++) {
@@ -404,7 +404,7 @@ static void CfgScanResult(enum scan_event scan_event,
struct ieee80211_channel *channel;
struct cfg80211_bss *bss = NULL;
- priv = (struct wilc_priv *)user_void;
+ priv = user_void;
if (priv->bCfgScanning) {
if (scan_event == SCAN_EVENT_NETWORK_FOUND) {
wiphy = priv->dev->ieee80211_ptr->wiphy;
@@ -525,7 +525,7 @@ static void CfgConnectResult(enum conn_event enuConnDisconnEvent,
wilc_connecting = 0;
- priv = (struct wilc_priv *)pUserVoid;
+ priv = pUserVoid;
dev = priv->dev;
vif = netdev_priv(dev);
wl = vif->wilc;
@@ -1713,7 +1713,7 @@ void WILC_WFI_p2p_rx (struct net_device *dev, u8 *buff, u32 size)
static void WILC_WFI_mgmt_tx_complete(void *priv, int status)
{
- struct p2p_mgmt_data *pv_data = (struct p2p_mgmt_data *)priv;
+ struct p2p_mgmt_data *pv_data = priv;
kfree(pv_data->buff);
@@ -1724,7 +1724,7 @@ static void WILC_WFI_RemainOnChannelReady(void *pUserVoid)
{
struct wilc_priv *priv;
- priv = (struct wilc_priv *)pUserVoid;
+ priv = pUserVoid;
priv->bInP2PlistenState = true;
@@ -1739,7 +1739,7 @@ static void WILC_WFI_RemainOnChannelExpired(void *pUserVoid, u32 u32SessionID)
{
struct wilc_priv *priv;
- priv = (struct wilc_priv *)pUserVoid;
+ priv = pUserVoid;
if (u32SessionID == priv->strRemainOnChanParams.u32ListenSessionID) {
priv->bInP2PlistenState = false;