All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/13] use setup_timer() helper function.
@ 2017-09-22  9:51 Allen Pais
  2017-09-22  9:51 ` [PATCH 01/13] scsi: sym53c8xx: use setup_timer() helper Allen Pais
                   ` (13 more replies)
  0 siblings, 14 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

This series uses setup_timer() helper function. The series
addresses the files under drivers/scsi/*.

Allen Pais (13):
  scsi: sym53c8xx: use setup_timer() helper.
  scsi: qla2xxx: use setup_timer() helper.
  scsi: esas2r: use setup_timer() helper.
  scsi: bnx2i: use setup_timer() helper.
  scsi: arcmsr: use setup_timer() helper.
  scsi: be2iscsi: use setup_timer() helper.
  scsi: qla4xxx: use setup_timer() helper.
  scsi: ncr53c8xx: use setup_timer() helper.
  scsi: arm: fas216: use setup_timer() helper.
  scsi: libiscsi: use setup_timer() helper.
  scsi: dc395x: use setup_timer() helper.
  scsi: qla2xxx: use setup_timer() helper.
  scsi: bfa: use setup_timer() helper.

 drivers/scsi/arcmsr/arcmsr_hba.c    | 10 ++++------
 drivers/scsi/arm/fas216.c           |  4 +---
 drivers/scsi/be2iscsi/be_main.c     |  5 ++---
 drivers/scsi/bfa/bfad.c             |  4 +---
 drivers/scsi/bnx2i/bnx2i_iscsi.c    | 14 +++++---------
 drivers/scsi/dc395x.c               |  4 +---
 drivers/scsi/esas2r/esas2r_main.c   |  4 +---
 drivers/scsi/libiscsi.c             |  5 ++---
 drivers/scsi/ncr53c8xx.c            |  4 +---
 drivers/scsi/qla2xxx/qla_inline.h   |  5 ++---
 drivers/scsi/qla2xxx/qla_os.c       |  5 ++---
 drivers/scsi/qla4xxx/ql4_os.c       |  5 ++---
 drivers/scsi/sym53c8xx_2/sym_glue.c |  4 +---
 13 files changed, 25 insertions(+), 48 deletions(-)

-- 
2.7.4

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [PATCH 01/13] scsi: sym53c8xx: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 02/13] scsi: qla2xxx: " Allen Pais
                   ` (12 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/sym53c8xx_2/sym_glue.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/sym53c8xx_2/sym_glue.c b/drivers/scsi/sym53c8xx_2/sym_glue.c
index d32e3ba..285397d 100644
--- a/drivers/scsi/sym53c8xx_2/sym_glue.c
+++ b/drivers/scsi/sym53c8xx_2/sym_glue.c
@@ -1351,9 +1351,7 @@ static struct Scsi_Host *sym_attach(struct scsi_host_template *tpnt, int unit,
 	/*
 	 *  Start the timer daemon
 	 */
-	init_timer(&np->s.timer);
-	np->s.timer.data     = (unsigned long) np;
-	np->s.timer.function = sym53c8xx_timer;
+	setup_timer(&np->s.timer, sym53c8xx_timer, (unsigned long)np);
 	np->s.lasttime=0;
 	sym_timer (np);
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 02/13] scsi: qla2xxx: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
  2017-09-22  9:51 ` [PATCH 01/13] scsi: sym53c8xx: use setup_timer() helper Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 03/13] scsi: esas2r: " Allen Pais
                   ` (11 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/qla2xxx/qla_inline.h | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/qla2xxx/qla_inline.h b/drivers/scsi/qla2xxx/qla_inline.h
index 9a2c86e..34cdb5d 100644
--- a/drivers/scsi/qla2xxx/qla_inline.h
+++ b/drivers/scsi/qla2xxx/qla_inline.h
@@ -269,10 +269,9 @@ qla2x00_rel_sp(srb_t *sp)
 static inline void
 qla2x00_init_timer(srb_t *sp, unsigned long tmo)
 {
-	init_timer(&sp->u.iocb_cmd.timer);
+	setup_timer(&sp->u.iocb_cmd.timer, qla2x00_sp_timeout,
+		    (unsigned long)sp);
 	sp->u.iocb_cmd.timer.expires = jiffies + tmo * HZ;
-	sp->u.iocb_cmd.timer.data = (unsigned long)sp;
-	sp->u.iocb_cmd.timer.function = qla2x00_sp_timeout;
 	add_timer(&sp->u.iocb_cmd.timer);
 	sp->free = qla2x00_sp_free;
 	if (IS_QLAFX00(sp->vha->hw) && (sp->type == SRB_FXIOCB_DCMD))
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 03/13] scsi: esas2r: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
  2017-09-22  9:51 ` [PATCH 01/13] scsi: sym53c8xx: use setup_timer() helper Allen Pais
  2017-09-22  9:51 ` [PATCH 02/13] scsi: qla2xxx: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 04/13] scsi: bnx2i: " Allen Pais
                   ` (10 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/esas2r/esas2r_main.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/esas2r/esas2r_main.c b/drivers/scsi/esas2r/esas2r_main.c
index 81f226b..590db6d 100644
--- a/drivers/scsi/esas2r/esas2r_main.c
+++ b/drivers/scsi/esas2r/esas2r_main.c
@@ -1635,10 +1635,8 @@ static void esas2r_timer_callback(unsigned long context);
 
 void esas2r_kickoff_timer(struct esas2r_adapter *a)
 {
-	init_timer(&a->timer);
 
-	a->timer.function = esas2r_timer_callback;
-	a->timer.data = (unsigned long)a;
+	setup_timer(&a->timer, esas2r_timer_callback, (unsigned long)a);
 	a->timer.expires = jiffies +
 			   msecs_to_jiffies(100);
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 04/13] scsi: bnx2i: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (2 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 03/13] scsi: esas2r: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 05/13] scsi: arcmsr: " Allen Pais
                   ` (9 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/bnx2i/bnx2i_iscsi.c | 14 +++++---------
 1 file changed, 5 insertions(+), 9 deletions(-)

diff --git a/drivers/scsi/bnx2i/bnx2i_iscsi.c b/drivers/scsi/bnx2i/bnx2i_iscsi.c
index 03c104b..bffc7e9 100644
--- a/drivers/scsi/bnx2i/bnx2i_iscsi.c
+++ b/drivers/scsi/bnx2i/bnx2i_iscsi.c
@@ -1729,10 +1729,8 @@ static int bnx2i_tear_down_conn(struct bnx2i_hba *hba,
 	}
 
 	ep->state = EP_STATE_CLEANUP_START;
-	init_timer(&ep->ofld_timer);
+	setup_timer(&ep->ofld_timer, bnx2i_ep_ofld_timer, (unsigned long)ep);
 	ep->ofld_timer.expires = hba->conn_ctx_destroy_tmo + jiffies;
-	ep->ofld_timer.function = bnx2i_ep_ofld_timer;
-	ep->ofld_timer.data = (unsigned long) ep;
 	add_timer(&ep->ofld_timer);
 
 	bnx2i_ep_destroy_list_add(hba, ep);
@@ -1835,10 +1833,9 @@ static struct iscsi_endpoint *bnx2i_ep_connect(struct Scsi_Host *shost,
 	bnx2i_ep->state = EP_STATE_OFLD_START;
 	bnx2i_ep_ofld_list_add(hba, bnx2i_ep);
 
-	init_timer(&bnx2i_ep->ofld_timer);
+	setup_timer(&bnx2i_ep->ofld_timer, bnx2i_ep_ofld_timer,
+		    (unsigned long)bnx2i_ep);
 	bnx2i_ep->ofld_timer.expires = 2 * HZ + jiffies;
-	bnx2i_ep->ofld_timer.function = bnx2i_ep_ofld_timer;
-	bnx2i_ep->ofld_timer.data = (unsigned long) bnx2i_ep;
 	add_timer(&bnx2i_ep->ofld_timer);
 
 	if (bnx2i_send_conn_ofld_req(hba, bnx2i_ep)) {
@@ -2054,10 +2051,9 @@ int bnx2i_hw_ep_disconnect(struct bnx2i_endpoint *bnx2i_ep)
 		session = conn->session;
 	}
 
-	init_timer(&bnx2i_ep->ofld_timer);
+	setup_timer(&bnx2i_ep->ofld_timer, bnx2i_ep_ofld_timer,
+		    (unsigned long)bnx2i_ep);
 	bnx2i_ep->ofld_timer.expires = hba->conn_teardown_tmo + jiffies;
-	bnx2i_ep->ofld_timer.function = bnx2i_ep_ofld_timer;
-	bnx2i_ep->ofld_timer.data = (unsigned long) bnx2i_ep;
 	add_timer(&bnx2i_ep->ofld_timer);
 
 	if (!test_bit(BNX2I_CNIC_REGISTERED, &hba->reg_with_cnic))
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 05/13] scsi: arcmsr: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (3 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 04/13] scsi: bnx2i: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 06/13] scsi: be2iscsi: " Allen Pais
                   ` (8 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/arcmsr/arcmsr_hba.c | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/drivers/scsi/arcmsr/arcmsr_hba.c b/drivers/scsi/arcmsr/arcmsr_hba.c
index af032c4..a54b6c1 100644
--- a/drivers/scsi/arcmsr/arcmsr_hba.c
+++ b/drivers/scsi/arcmsr/arcmsr_hba.c
@@ -837,10 +837,9 @@ static int arcmsr_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 	atomic_set(&acb->rq_map_token, 16);
 	atomic_set(&acb->ante_token_value, 16);
 	acb->fw_flag = FW_NORMAL;
-	init_timer(&acb->eternal_timer);
+	setup_timer(&acb->eternal_timer, &arcmsr_request_device_map,
+		    (unsigned long)acb);
 	acb->eternal_timer.expires = jiffies + msecs_to_jiffies(6 * HZ);
-	acb->eternal_timer.data = (unsigned long) acb;
-	acb->eternal_timer.function = &arcmsr_request_device_map;
 	add_timer(&acb->eternal_timer);
 	if(arcmsr_alloc_sysfs_attr(acb))
 		goto out_free_sysfs;
@@ -930,10 +929,9 @@ static int arcmsr_resume(struct pci_dev *pdev)
 	atomic_set(&acb->rq_map_token, 16);
 	atomic_set(&acb->ante_token_value, 16);
 	acb->fw_flag = FW_NORMAL;
-	init_timer(&acb->eternal_timer);
+	setup_timer(&acb->eternal_timer, &arcmsr_request_device_map,
+		    (unsigned long)acb);
 	acb->eternal_timer.expires = jiffies + msecs_to_jiffies(6 * HZ);
-	acb->eternal_timer.data = (unsigned long) acb;
-	acb->eternal_timer.function = &arcmsr_request_device_map;
 	add_timer(&acb->eternal_timer);
 	return 0;
 controller_stop:
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 06/13] scsi: be2iscsi: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (4 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 05/13] scsi: arcmsr: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 07/13] scsi: qla4xxx: " Allen Pais
                   ` (7 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/be2iscsi/be_main.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/be2iscsi/be_main.c b/drivers/scsi/be2iscsi/be_main.c
index b4542e7..5579454 100644
--- a/drivers/scsi/be2iscsi/be_main.c
+++ b/drivers/scsi/be2iscsi/be_main.c
@@ -5708,9 +5708,8 @@ static int beiscsi_dev_probe(struct pci_dev *pcidev,
 	 * Start UE detection here. UE before this will cause stall in probe
 	 * and eventually fail the probe.
 	 */
-	init_timer(&phba->hw_check);
-	phba->hw_check.function = beiscsi_hw_health_check;
-	phba->hw_check.data = (unsigned long)phba;
+	setup_timer(&phba->hw_check, beiscsi_hw_health_check,
+		    (unsigned long)phba);
 	mod_timer(&phba->hw_check,
 		  jiffies + msecs_to_jiffies(BEISCSI_UE_DETECT_INTERVAL));
 	beiscsi_log(phba, KERN_INFO, BEISCSI_LOG_INIT,
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 07/13] scsi: qla4xxx: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (5 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 06/13] scsi: be2iscsi: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 08/13] scsi: ncr53c8xx: " Allen Pais
                   ` (6 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/qla4xxx/ql4_os.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
index 64c6fa5..32b3e0e 100644
--- a/drivers/scsi/qla4xxx/ql4_os.c
+++ b/drivers/scsi/qla4xxx/ql4_os.c
@@ -3961,10 +3961,9 @@ static void qla4xxx_start_timer(struct scsi_qla_host *ha, void *func,
 {
 	DEBUG(printk("scsi: %s: Starting timer thread for adapter %d\n",
 		     __func__, ha->host->host_no));
-	init_timer(&ha->timer);
+	setup_timer(&ha->timer, (void(*)(unsigned long))func,
+		    (unsigned long)ha);
 	ha->timer.expires = jiffies + interval * HZ;
-	ha->timer.data = (unsigned long)ha;
-	ha->timer.function = (void (*)(unsigned long))func;
 	add_timer(&ha->timer);
 	ha->timer_active = 1;
 }
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 08/13] scsi: ncr53c8xx: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (6 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 07/13] scsi: qla4xxx: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 09/13] scsi: arm: fas216: " Allen Pais
                   ` (5 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/ncr53c8xx.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/ncr53c8xx.c b/drivers/scsi/ncr53c8xx.c
index 5b93ed8..017216f 100644
--- a/drivers/scsi/ncr53c8xx.c
+++ b/drivers/scsi/ncr53c8xx.c
@@ -8357,9 +8357,7 @@ struct Scsi_Host * __init ncr_attach(struct scsi_host_template *tpnt,
 	if (!np->scripth0)
 		goto attach_error;
 
-	init_timer(&np->timer);
-	np->timer.data     = (unsigned long) np;
-	np->timer.function = ncr53c8xx_timeout;
+	setup_timer(&np->timer, ncr53c8xx_timeout, (unsigned long)np);
 
 	/* Try to map the controller chip to virtual and physical memory. */
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 09/13] scsi: arm: fas216: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (7 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 08/13] scsi: ncr53c8xx: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 10/13] scsi: libiscsi: " Allen Pais
                   ` (4 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/arm/fas216.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/arm/fas216.c b/drivers/scsi/arm/fas216.c
index 2438879..7304d5a 100644
--- a/drivers/scsi/arm/fas216.c
+++ b/drivers/scsi/arm/fas216.c
@@ -2849,9 +2849,7 @@ int fas216_init(struct Scsi_Host *host)
 	info->rst_dev_status = -1;
 	info->rst_bus_status = -1;
 	init_waitqueue_head(&info->eh_wait);
-	init_timer(&info->eh_timer);
-	info->eh_timer.data  = (unsigned long)info;
-	info->eh_timer.function = fas216_eh_timer;
+	setup_timer(&info->eh_timer, fas216_eh_timer, (unsigned long)info);
 	
 	spin_lock_init(&info->host_lock);
 
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 10/13] scsi: libiscsi: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (8 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 09/13] scsi: arm: fas216: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 11/13] scsi: dc395x: " Allen Pais
                   ` (3 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/libiscsi.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/libiscsi.c b/drivers/scsi/libiscsi.c
index bd4605a..f485280 100644
--- a/drivers/scsi/libiscsi.c
+++ b/drivers/scsi/libiscsi.c
@@ -2913,9 +2913,8 @@ iscsi_conn_setup(struct iscsi_cls_session *cls_session, int dd_size,
 	conn->exp_statsn = 0;
 	conn->tmf_state = TMF_INITIAL;
 
-	init_timer(&conn->transport_timer);
-	conn->transport_timer.data = (unsigned long)conn;
-	conn->transport_timer.function = iscsi_check_transport_timeouts;
+	setup_timer(&conn->transport_timer, iscsi_check_transport_timeouts,
+		    (unsigned long)conn);
 
 	INIT_LIST_HEAD(&conn->mgmtqueue);
 	INIT_LIST_HEAD(&conn->cmdqueue);
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 11/13] scsi: dc395x: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (9 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 10/13] scsi: libiscsi: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 12/13] scsi: qla2xxx: " Allen Pais
                   ` (2 subsequent siblings)
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/dc395x.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/dc395x.c b/drivers/scsi/dc395x.c
index 5ee7f44..f9aaa8b 100644
--- a/drivers/scsi/dc395x.c
+++ b/drivers/scsi/dc395x.c
@@ -857,9 +857,7 @@ static void waiting_set_timer(struct AdapterCtlBlk *acb, unsigned long to)
 {
 	if (timer_pending(&acb->waiting_timer))
 		return;
-	init_timer(&acb->waiting_timer);
-	acb->waiting_timer.function = waiting_timeout;
-	acb->waiting_timer.data = (unsigned long) acb;
+	setup_timer(&acb->waiting_timer, waiting_timeout, (unsigned long)acb);
 	if (time_before(jiffies + to, acb->last_reset - HZ / 2))
 		acb->waiting_timer.expires =
 		    acb->last_reset - HZ / 2 + 1;
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 12/13] scsi: qla2xxx: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (10 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 11/13] scsi: dc395x: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22  9:51 ` [PATCH 13/13] scsi: bfa: " Allen Pais
  2017-09-22 19:25 ` [PATCH 00/13] use setup_timer() helper function Lee Duncan
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/qla2xxx/qla_os.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 5b2437a..8058eeb 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -332,10 +332,9 @@ struct scsi_transport_template *qla2xxx_transport_vport_template = NULL;
 __inline__ void
 qla2x00_start_timer(scsi_qla_host_t *vha, void *func, unsigned long interval)
 {
-	init_timer(&vha->timer);
+	setup_timer(&vha->timer, (void(*)(unsigned long))func,
+		    (unsigned long)vha);
 	vha->timer.expires = jiffies + interval * HZ;
-	vha->timer.data = (unsigned long)vha;
-	vha->timer.function = (void (*)(unsigned long))func;
 	add_timer(&vha->timer);
 	vha->timer_active = 1;
 }
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH 13/13] scsi: bfa: use setup_timer() helper.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (11 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 12/13] scsi: qla2xxx: " Allen Pais
@ 2017-09-22  9:51 ` Allen Pais
  2017-09-22 19:25 ` [PATCH 00/13] use setup_timer() helper function Lee Duncan
  13 siblings, 0 replies; 15+ messages in thread
From: Allen Pais @ 2017-09-22  9:51 UTC (permalink / raw)
  To: linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, lduncan,
	cleech, matthew, Allen Pais

   Use setup_timer function instead of initializing timer with the
   function and data fields.

Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
 drivers/scsi/bfa/bfad.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/bfa/bfad.c b/drivers/scsi/bfa/bfad.c
index 5caf5f3..d10826a 100644
--- a/drivers/scsi/bfa/bfad.c
+++ b/drivers/scsi/bfa/bfad.c
@@ -719,9 +719,7 @@ bfad_bfa_tmo(unsigned long data)
 void
 bfad_init_timer(struct bfad_s *bfad)
 {
-	init_timer(&bfad->hal_tmo);
-	bfad->hal_tmo.function = bfad_bfa_tmo;
-	bfad->hal_tmo.data = (unsigned long)bfad;
+	setup_timer(&bfad->hal_tmo, bfad_bfa_tmo, (unsigned long)bfad);
 
 	mod_timer(&bfad->hal_tmo,
 		  jiffies + msecs_to_jiffies(BFA_TIMER_FREQ));
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [PATCH 00/13] use setup_timer() helper function.
  2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
                   ` (12 preceding siblings ...)
  2017-09-22  9:51 ` [PATCH 13/13] scsi: bfa: " Allen Pais
@ 2017-09-22 19:25 ` Lee Duncan
  13 siblings, 0 replies; 15+ messages in thread
From: Lee Duncan @ 2017-09-22 19:25 UTC (permalink / raw)
  To: Allen Pais, linux-scsi
  Cc: jejb, martin.petersen, linux, oliver, aliakc, lenehan, cleech, matthew

On 09/22/2017 02:51 AM, Allen Pais wrote:
> This series uses setup_timer() helper function. The series
> addresses the files under drivers/scsi/*.
> 
> Allen Pais (13):
>   scsi: sym53c8xx: use setup_timer() helper.
>   scsi: qla2xxx: use setup_timer() helper.
>   scsi: esas2r: use setup_timer() helper.
>   scsi: bnx2i: use setup_timer() helper.
>   scsi: arcmsr: use setup_timer() helper.
>   scsi: be2iscsi: use setup_timer() helper.
>   scsi: qla4xxx: use setup_timer() helper.
>   scsi: ncr53c8xx: use setup_timer() helper.
>   scsi: arm: fas216: use setup_timer() helper.
>   scsi: libiscsi: use setup_timer() helper.
>   scsi: dc395x: use setup_timer() helper.
>   scsi: qla2xxx: use setup_timer() helper.
>   scsi: bfa: use setup_timer() helper.
> 
>  drivers/scsi/arcmsr/arcmsr_hba.c    | 10 ++++------
>  drivers/scsi/arm/fas216.c           |  4 +---
>  drivers/scsi/be2iscsi/be_main.c     |  5 ++---
>  drivers/scsi/bfa/bfad.c             |  4 +---
>  drivers/scsi/bnx2i/bnx2i_iscsi.c    | 14 +++++---------
>  drivers/scsi/dc395x.c               |  4 +---
>  drivers/scsi/esas2r/esas2r_main.c   |  4 +---
>  drivers/scsi/libiscsi.c             |  5 ++---
>  drivers/scsi/ncr53c8xx.c            |  4 +---
>  drivers/scsi/qla2xxx/qla_inline.h   |  5 ++---
>  drivers/scsi/qla2xxx/qla_os.c       |  5 ++---
>  drivers/scsi/qla4xxx/ql4_os.c       |  5 ++---
>  drivers/scsi/sym53c8xx_2/sym_glue.c |  4 +---
>  13 files changed, 25 insertions(+), 48 deletions(-)
> 

Please add for the whole series:

Acked-by: Lee Duncan <lduncan@suse.com>

-- 
Lee Duncan
SUSE Labs

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2017-09-22 19:25 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-22  9:51 [PATCH 00/13] use setup_timer() helper function Allen Pais
2017-09-22  9:51 ` [PATCH 01/13] scsi: sym53c8xx: use setup_timer() helper Allen Pais
2017-09-22  9:51 ` [PATCH 02/13] scsi: qla2xxx: " Allen Pais
2017-09-22  9:51 ` [PATCH 03/13] scsi: esas2r: " Allen Pais
2017-09-22  9:51 ` [PATCH 04/13] scsi: bnx2i: " Allen Pais
2017-09-22  9:51 ` [PATCH 05/13] scsi: arcmsr: " Allen Pais
2017-09-22  9:51 ` [PATCH 06/13] scsi: be2iscsi: " Allen Pais
2017-09-22  9:51 ` [PATCH 07/13] scsi: qla4xxx: " Allen Pais
2017-09-22  9:51 ` [PATCH 08/13] scsi: ncr53c8xx: " Allen Pais
2017-09-22  9:51 ` [PATCH 09/13] scsi: arm: fas216: " Allen Pais
2017-09-22  9:51 ` [PATCH 10/13] scsi: libiscsi: " Allen Pais
2017-09-22  9:51 ` [PATCH 11/13] scsi: dc395x: " Allen Pais
2017-09-22  9:51 ` [PATCH 12/13] scsi: qla2xxx: " Allen Pais
2017-09-22  9:51 ` [PATCH 13/13] scsi: bfa: " Allen Pais
2017-09-22 19:25 ` [PATCH 00/13] use setup_timer() helper function Lee Duncan

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.