mirror of
https://github.com/lwfinger/rtl8188eu.git
synced 2025-06-23 16:44:20 +00:00
rtl8188eu: Updates for timer changes in kernel 4.15
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
parent
e472b5d684
commit
1f08a062ad
13 changed files with 196 additions and 7 deletions
|
@ -208,9 +208,19 @@ exit:
|
|||
return;
|
||||
}
|
||||
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 15, 0)
|
||||
static void pwr_state_check_handler(struct timer_list *t)
|
||||
#else
|
||||
static void pwr_state_check_handler(void *FunctionContext)
|
||||
#endif
|
||||
{
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 15, 0)
|
||||
struct adapter *padapter =
|
||||
from_timer(padapter, t,
|
||||
pwrctrlpriv.pwr_state_check_timer);
|
||||
#else
|
||||
struct adapter *padapter = (struct adapter *)FunctionContext;
|
||||
#endif
|
||||
rtw_ps_cmd(padapter);
|
||||
}
|
||||
|
||||
|
@ -498,8 +508,11 @@ void rtw_init_pwrctrl_priv(struct adapter *padapter)
|
|||
|
||||
pwrctrlpriv->btcoex_rfon = false;
|
||||
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 15, 0)
|
||||
timer_setup(&pwrctrlpriv->pwr_state_check_timer, pwr_state_check_handler, 0);
|
||||
#else
|
||||
_init_timer(&(pwrctrlpriv->pwr_state_check_timer), padapter->pnetdev, pwr_state_check_handler, (u8 *)padapter);
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
void rtw_free_pwrctrl_priv(struct adapter *adapter)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue