From: Larry Finger Date: Sun, 22 Dec 2013 23:36:40 +0000 (-0600) Subject: staging: r8188eu: Replace wrapper around sema_init X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=efbef10095bf4915a136c10d66ff96a60f2d0df8;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git staging: r8188eu: Replace wrapper around sema_init Signed-off-by: Larry Finger Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8188eu/core/rtw_cmd.c b/drivers/staging/rtl8188eu/core/rtw_cmd.c index f01564ffc6bb..a46aadd5472f 100644 --- a/drivers/staging/rtl8188eu/core/rtw_cmd.c +++ b/drivers/staging/rtl8188eu/core/rtw_cmd.c @@ -38,9 +38,9 @@ int _rtw_init_cmd_priv (struct cmd_priv *pcmdpriv) _func_enter_; - _rtw_init_sema(&(pcmdpriv->cmd_queue_sema), 0); - /* _rtw_init_sema(&(pcmdpriv->cmd_done_sema), 0); */ - _rtw_init_sema(&(pcmdpriv->terminate_cmdthread_sema), 0); + sema_init(&(pcmdpriv->cmd_queue_sema), 0); + /* sema_init(&(pcmdpriv->cmd_done_sema), 0); */ + sema_init(&(pcmdpriv->terminate_cmdthread_sema), 0); _rtw_init_queue(&(pcmdpriv->cmd_queue)); diff --git a/drivers/staging/rtl8188eu/core/rtw_recv.c b/drivers/staging/rtl8188eu/core/rtw_recv.c index 7c5403a3db97..c9c180649c12 100644 --- a/drivers/staging/rtl8188eu/core/rtw_recv.c +++ b/drivers/staging/rtl8188eu/core/rtw_recv.c @@ -102,7 +102,7 @@ _func_enter_; } precvpriv->rx_pending_cnt = 1; - _rtw_init_sema(&precvpriv->allrxreturnevt, 0); + sema_init(&precvpriv->allrxreturnevt, 0); res = rtw_hal_init_recv_priv(padapter); diff --git a/drivers/staging/rtl8188eu/core/rtw_xmit.c b/drivers/staging/rtl8188eu/core/rtw_xmit.c index 0ebcc7aba3fb..b372408028ba 100644 --- a/drivers/staging/rtl8188eu/core/rtw_xmit.c +++ b/drivers/staging/rtl8188eu/core/rtw_xmit.c @@ -68,8 +68,8 @@ _func_enter_; /* We don't need to memset padapter->XXX to zero, because adapter is allocated by rtw_zvmalloc(). */ spin_lock_init(&pxmitpriv->lock); - _rtw_init_sema(&pxmitpriv->xmit_sema, 0); - _rtw_init_sema(&pxmitpriv->terminate_xmitthread_sema, 0); + sema_init(&pxmitpriv->xmit_sema, 0); + sema_init(&pxmitpriv->terminate_xmitthread_sema, 0); /* Please insert all the queue initializaiton using _rtw_init_queue below @@ -210,7 +210,7 @@ _func_enter_; pxmitpriv->txirp_cnt = 1; - _rtw_init_sema(&(pxmitpriv->tx_retevt), 0); + sema_init(&(pxmitpriv->tx_retevt), 0); /* per AC pending irp */ pxmitpriv->beq_cnt = 0; diff --git a/drivers/staging/rtl8188eu/include/osdep_service.h b/drivers/staging/rtl8188eu/include/osdep_service.h index b36fc2000828..77829b950bc0 100644 --- a/drivers/staging/rtl8188eu/include/osdep_service.h +++ b/drivers/staging/rtl8188eu/include/osdep_service.h @@ -256,7 +256,6 @@ void rtw_list_insert_head(struct list_head *plist, struct list_head *phead); void rtw_list_insert_tail(struct list_head *plist, struct list_head *phead); void rtw_list_delete(struct list_head *plist); -void _rtw_init_sema(struct semaphore *sema, int init_val); void _rtw_free_sema(struct semaphore *sema); void _rtw_up_sema(struct semaphore *sema); u32 _rtw_down_sema(struct semaphore *sema); diff --git a/drivers/staging/rtl8188eu/include/rtw_pwrctrl.h b/drivers/staging/rtl8188eu/include/rtw_pwrctrl.h index d4b8acb8025b..3946c0302cec 100644 --- a/drivers/staging/rtl8188eu/include/rtw_pwrctrl.h +++ b/drivers/staging/rtl8188eu/include/rtw_pwrctrl.h @@ -99,7 +99,7 @@ struct reportpwrstate_parm { static inline void _init_pwrlock(struct semaphore *plock) { - _rtw_init_sema(plock, 1); + sema_init(plock, 1); } static inline void _free_pwrlock(struct semaphore *plock) diff --git a/drivers/staging/rtl8188eu/os_dep/osdep_service.c b/drivers/staging/rtl8188eu/os_dep/osdep_service.c index 77f5310ef0a1..f292427011ad 100644 --- a/drivers/staging/rtl8188eu/os_dep/osdep_service.c +++ b/drivers/staging/rtl8188eu/os_dep/osdep_service.c @@ -161,11 +161,6 @@ void rtw_list_insert_tail(struct list_head *plist, struct list_head *phead) Caller must check if the list is empty before calling rtw_list_delete */ -void _rtw_init_sema(struct semaphore *sema, int init_val) -{ - sema_init(sema, init_val); -} - void _rtw_free_sema(struct semaphore *sema) { } diff --git a/drivers/staging/rtl8188eu/os_dep/usb_intf.c b/drivers/staging/rtl8188eu/os_dep/usb_intf.c index 28903aa259a3..8642397f73d1 100644 --- a/drivers/staging/rtl8188eu/os_dep/usb_intf.c +++ b/drivers/staging/rtl8188eu/os_dep/usb_intf.c @@ -240,7 +240,7 @@ _func_enter_; } /* 3 misc */ - _rtw_init_sema(&(pdvobjpriv->usb_suspend_sema), 0); + sema_init(&(pdvobjpriv->usb_suspend_sema), 0); rtw_reset_continual_urb_error(pdvobjpriv); usb_get_dev(pusbd);