From: Muhammad Falak R Wani Date: Wed, 11 May 2016 15:23:31 +0000 (+0530) Subject: staging: lustre: use setup_timer(). X-Git-Tag: v4.14-rc1~2869^2~291 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=423b09b8f45c8771bca84d41c3254c3904d78a0a;p=platform%2Fkernel%2Flinux-rpi.git staging: lustre: use setup_timer(). Use setup_timer() for initializing the timer, instead of structure assignments. This is the preferred/standard way. Signed-off-by: Muhammad Falak R Wani Acked-by: James Simmons Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/lustre/lnet/lnet/net_fault.c b/drivers/staging/lustre/lnet/lnet/net_fault.c index 7d76f28..e4aceb7 100644 --- a/drivers/staging/lustre/lnet/lnet/net_fault.c +++ b/drivers/staging/lustre/lnet/lnet/net_fault.c @@ -760,9 +760,7 @@ lnet_delay_rule_add(struct lnet_fault_attr *attr) wait_event(delay_dd.dd_ctl_waitq, delay_dd.dd_running); } - init_timer(&rule->dl_timer); - rule->dl_timer.function = delay_timer_cb; - rule->dl_timer.data = (unsigned long)rule; + setup_timer(&rule->dl_timer, delay_timer_cb, (unsigned long)rule); spin_lock_init(&rule->dl_lock); INIT_LIST_HEAD(&rule->dl_msg_list);