[PATCH] atm: lanai: use setup_timer instead of init_timer
From: Colin King
Date: Fri Nov 24 2017 - 08:27:18 EST
From: Colin Ian King <colin.king@xxxxxxxxxxxxx>
Use setup_timer function instead of initializing timer with the
function and data fields.
Signed-off-by: Colin Ian King <colin.king@xxxxxxxxxxxxx>
---
drivers/atm/lanai.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/atm/lanai.c b/drivers/atm/lanai.c
index 2351dad78ff5..87e8b5dfac39 100644
--- a/drivers/atm/lanai.c
+++ b/drivers/atm/lanai.c
@@ -1790,10 +1790,8 @@ static void lanai_timed_poll(unsigned long arg)
static inline void lanai_timed_poll_start(struct lanai_dev *lanai)
{
- init_timer(&lanai->timer);
+ setup_timer(&lanai->timer, lanai_timed_poll, (unsigned long)lanai);
lanai->timer.expires = jiffies + LANAI_POLL_PERIOD;
- lanai->timer.data = (unsigned long) lanai;
- lanai->timer.function = lanai_timed_poll;
add_timer(&lanai->timer);
}
--
2.14.1