]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commitdiff
staging: rtl8723bs: os_dep: remove cast to void pointer
authorHimanshu Jha <himanshujha199640@gmail.com>
Mon, 28 Aug 2017 13:27:36 +0000 (18:57 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 29 Aug 2017 06:24:04 +0000 (08:24 +0200)
casting to void pointer from any pointer type and vice-versa is done
implicitly and therefore casting is not needed in such a case.

Signed-off-by: Himanshu Jha <himanshujha199640@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8723bs/os_dep/mlme_linux.c
drivers/staging/rtl8723bs/os_dep/osdep_service.c
drivers/staging/rtl8723bs/os_dep/sdio_intf.c
drivers/staging/rtl8723bs/os_dep/sdio_ops_linux.c

index 3e29df075c847bc2ea945b361f92323a6584c074..80ca2d781c5d238719a3032e9df385c131ced4f7 100644 (file)
@@ -21,7 +21,7 @@
 
 static void _dynamic_check_timer_handlder (void *FunctionContext)
 {
-       struct adapter *adapter = (struct adapter *)FunctionContext;
+       struct adapter *adapter = FunctionContext;
 
        rtw_dynamic_check_timer_handlder(adapter);
 
@@ -30,7 +30,7 @@ static void _dynamic_check_timer_handlder (void *FunctionContext)
 
 static void _rtw_set_scan_deny_timer_hdl(void *FunctionContext)
 {
-       struct adapter *adapter = (struct adapter *)FunctionContext;
+       struct adapter *adapter = FunctionContext;
        rtw_set_scan_deny_timer_hdl(adapter);
 }
 
index aa16d1ab955b43ae57c1a317beb365b2cfd2d476..a05daf06a870a92ae1b575937149c3edd9a97f2e 100644 (file)
@@ -73,7 +73,7 @@ inline int _rtw_netif_rx(_nic_hdl ndev, struct sk_buff *skb)
 
 void rtw_init_timer(_timer *ptimer, void *padapter, void *pfunc)
 {
-       struct adapter *adapter = (struct adapter *)padapter;
+       struct adapter *adapter = padapter;
 
        _init_timer(ptimer, adapter->pnetdev, pfunc, adapter);
 }
index d2fb489d2e8327a68461ccf4333f9bdaca0415c5..943324877707f474cc7129fc45cef3a5fc4a3f66 100644 (file)
@@ -138,7 +138,7 @@ static void sdio_free_irq(struct dvobj_priv *dvobj)
 extern unsigned int oob_irq;
 static irqreturn_t gpio_hostwakeup_irq_thread(int irq, void *data)
 {
-       struct adapter *padapter = (struct adapter *)data;
+       struct adapter *padapter = data;
        DBG_871X_LEVEL(_drv_always_, "gpio_hostwakeup_irq_thread\n");
        /* Disable interrupt before calling handler */
        /* disable_irq_nosync(oob_irq); */
index 3aa3e6548fd548c287ad0a17201d13e87f07a7f0..3108a625ada333465f9298c54e5eef007e2ac7be 100644 (file)
@@ -431,7 +431,7 @@ s32 _sd_read(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, void *pdata)
        if (unlikely((cnt == 1) || (cnt == 2)))
        {
                int i;
-               u8 *pbuf = (u8 *)pdata;
+               u8 *pbuf = pdata;
 
                for (i = 0; i < cnt; i++)
                {
@@ -534,7 +534,7 @@ s32 _sd_write(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, void *pdata)
        if (unlikely((cnt == 1) || (cnt == 2)))
        {
                int i;
-               u8 *pbuf = (u8 *)pdata;
+               u8 *pbuf = pdata;
 
                for (i = 0; i < cnt; i++)
                {