From aff55a3638a2d13de5cf0b0c45993378282cbe91 Mon Sep 17 00:00:00 2001 From: Geliang Tang Date: Thu, 23 Mar 2017 21:15:57 +0800 Subject: isdn: use setup_timer Use setup_timer() instead of init_timer() to simplify the code. Signed-off-by: Geliang Tang Signed-off-by: David S. Miller --- drivers/isdn/hardware/mISDN/mISDNisar.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'drivers/isdn/hardware/mISDN/mISDNisar.c') diff --git a/drivers/isdn/hardware/mISDN/mISDNisar.c b/drivers/isdn/hardware/mISDN/mISDNisar.c index feafa91c2ed9..5b078591b6ee 100644 --- a/drivers/isdn/hardware/mISDN/mISDNisar.c +++ b/drivers/isdn/hardware/mISDN/mISDNisar.c @@ -1635,13 +1635,11 @@ init_isar(struct isar_hw *isar) } if (isar->version != 1) return -EINVAL; - isar->ch[0].ftimer.function = &ftimer_handler; - isar->ch[0].ftimer.data = (long)&isar->ch[0]; - init_timer(&isar->ch[0].ftimer); + setup_timer(&isar->ch[0].ftimer, &ftimer_handler, + (long)&isar->ch[0]); test_and_set_bit(FLG_INITIALIZED, &isar->ch[0].bch.Flags); - isar->ch[1].ftimer.function = &ftimer_handler; - isar->ch[1].ftimer.data = (long)&isar->ch[1]; - init_timer(&isar->ch[1].ftimer); + setup_timer(&isar->ch[1].ftimer, &ftimer_handler, + (long)&isar->ch[1]); test_and_set_bit(FLG_INITIALIZED, &isar->ch[1].bch.Flags); return 0; } -- cgit v1.2.3