iwlegacy: Fix -Wcast-function-type

correct usage prototype of callback in tasklet_init().
Report by https://github.com/KSPP/linux/issues/20

Signed-off-by: Phong Tran <tranmanphong@gmail.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
This commit is contained in:
Phong Tran 2019-11-27 00:55:28 +07:00 committed by Kalle Valo
parent ebd77feb27
commit da5e57e8a6
2 changed files with 6 additions and 4 deletions

View File

@ -1376,8 +1376,9 @@ il3945_dump_nic_error_log(struct il_priv *il)
}
static void
il3945_irq_tasklet(struct il_priv *il)
il3945_irq_tasklet(unsigned long data)
{
struct il_priv *il = (struct il_priv *)data;
u32 inta, handled = 0;
u32 inta_fh;
unsigned long flags;
@ -3401,7 +3402,7 @@ il3945_setup_deferred_work(struct il_priv *il)
timer_setup(&il->watchdog, il_bg_watchdog, 0);
tasklet_init(&il->irq_tasklet,
(void (*)(unsigned long))il3945_irq_tasklet,
il3945_irq_tasklet,
(unsigned long)il);
}

View File

@ -4343,8 +4343,9 @@ il4965_synchronize_irq(struct il_priv *il)
}
static void
il4965_irq_tasklet(struct il_priv *il)
il4965_irq_tasklet(unsigned long data)
{
struct il_priv *il = (struct il_priv *)data;
u32 inta, handled = 0;
u32 inta_fh;
unsigned long flags;
@ -6237,7 +6238,7 @@ il4965_setup_deferred_work(struct il_priv *il)
timer_setup(&il->watchdog, il_bg_watchdog, 0);
tasklet_init(&il->irq_tasklet,
(void (*)(unsigned long))il4965_irq_tasklet,
il4965_irq_tasklet,
(unsigned long)il);
}