mirror of
https://github.com/nxp-imx/mwifiex.git
synced 2026-11-20 18:39:49 -05:00
mxm_wifiex: fix build error on L6.15 kernel next tree
When build wifi driver based on L6.15 kernel next tree, will observe the
following build error. This is caused by the upstream patch:
8fa7292fee5c ("treewide: Switch/rename to timer_delete[_sync]()")
Need to change corresponding API here to avoid the build break.
Build error logs:
In file included from mlinux/moal_ioctl.c:28:
mlinux/moal_main.h: In function ‘woal_cancel_timer’:
mlinux/moal_main.h:572:17: error: implicit declaration of function ‘del_timer’; did you mean ‘add_timer’? [-Werror=implicit-function-declaration]
572 | del_timer(&timer->tl);
| ^~~~~~~~~
| add_timer
mlinux/moal_main.h:574:17: error: implicit declaration of function ‘del_timer_sync’; did you mean ‘dev_mc_sync’? [-Werror=implicit-function-declaration]
574 | del_timer_sync(&timer->tl);
| ^~~~~~~~~~~~~~
| dev_mc_sync
Signed-off-by: Sherry Sun <sherry.sun@nxp.com>
This commit is contained in:
parent
2da89e4cad
commit
91d2e896ac
1 changed files with 8 additions and 0 deletions
|
|
@ -569,9 +569,17 @@ static inline void woal_mod_timer(pmoal_drv_timer timer,
|
|||
static inline void woal_cancel_timer(moal_drv_timer *timer)
|
||||
{
|
||||
if (timer->timer_is_periodic || in_atomic() || irqs_disabled())
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 15, 0)
|
||||
timer_delete(&timer->tl);
|
||||
#else
|
||||
del_timer(&timer->tl);
|
||||
#endif
|
||||
else
|
||||
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 15, 0)
|
||||
timer_delete_sync(&timer->tl);
|
||||
#else
|
||||
del_timer_sync(&timer->tl);
|
||||
#endif
|
||||
timer->timer_is_canceled = MTRUE;
|
||||
timer->time_period = 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue