[PATCH] s390: scsi, use setup_timer instead of init_timer
From: Jiri Slaby
Date: Fri Mar 03 2017 - 08:22:47 EST
From: LukÃÅ KorenÄik <xkorenc1@xxxxxxxxxx>
Use inicialization with setup_timer function instead of using
init_timer function and data fields. It improves readability.
Signed-off-by: LukÃÅ KorenÄik <xkorenc1@xxxxxxxxxx>
Signed-off-by: Jiri Slaby <jslaby@xxxxxxx>
Cc: Steffen Maier <maier@xxxxxxxxxxxxxxxxxx>
Cc: Martin Schwidefsky <schwidefsky@xxxxxxxxxx>
Cc: Heiko Carstens <heiko.carstens@xxxxxxxxxx>
Cc: <linux-s390@xxxxxxxxxxxxxxx>
---
drivers/s390/scsi/zfcp_erp.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/s390/scsi/zfcp_erp.c b/drivers/s390/scsi/zfcp_erp.c
index 7ccfce559034..14c0cbe335b3 100644
--- a/drivers/s390/scsi/zfcp_erp.c
+++ b/drivers/s390/scsi/zfcp_erp.c
@@ -572,9 +572,8 @@ static void zfcp_erp_memwait_handler(unsigned long data)
static void zfcp_erp_strategy_memwait(struct zfcp_erp_action *erp_action)
{
- init_timer(&erp_action->timer);
- erp_action->timer.function = zfcp_erp_memwait_handler;
- erp_action->timer.data = (unsigned long) erp_action;
+ setup_timer(&erp_action->timer, zfcp_erp_memwait_handler,
+ (unsigned long) erp_action);
erp_action->timer.expires = jiffies + HZ;
add_timer(&erp_action->timer);
}
--
2.12.0