linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dmaengine: ioat: use setup_timer
@ 2017-04-09  1:41 Geliang Tang
  2017-04-09  1:41 ` [PATCH] i2c: img-scb: " Geliang Tang
                   ` (4 more replies)
  0 siblings, 5 replies; 8+ messages in thread
From: Geliang Tang @ 2017-04-09  1:41 UTC (permalink / raw)
  To: Vinod Koul, Dan Williams, Dave Jiang
  Cc: Geliang Tang, dmaengine, linux-kernel

Use setup_timer() instead of init_timer() to simplify the code.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
---
 drivers/dma/ioat/init.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/dma/ioat/init.c b/drivers/dma/ioat/init.c
index cc5259b..6ad4384 100644
--- a/drivers/dma/ioat/init.c
+++ b/drivers/dma/ioat/init.c
@@ -760,9 +760,7 @@ ioat_init_channel(struct ioatdma_device *ioat_dma,
 	dma_cookie_init(&ioat_chan->dma_chan);
 	list_add_tail(&ioat_chan->dma_chan.device_node, &dma->channels);
 	ioat_dma->idx[idx] = ioat_chan;
-	init_timer(&ioat_chan->timer);
-	ioat_chan->timer.function = ioat_timer_event;
-	ioat_chan->timer.data = data;
+	setup_timer(&ioat_chan->timer, ioat_timer_event, data);
 	tasklet_init(&ioat_chan->cleanup_task, ioat_cleanup_event, data);
 }
 
-- 
2.9.3

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

* [PATCH] i2c: img-scb: use setup_timer
  2017-04-09  1:41 [PATCH] dmaengine: ioat: use setup_timer Geliang Tang
@ 2017-04-09  1:41 ` Geliang Tang
  2017-04-16 19:51   ` Wolfram Sang
  2017-04-09  1:41 ` [PATCH] ide: " Geliang Tang
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 8+ messages in thread
From: Geliang Tang @ 2017-04-09  1:41 UTC (permalink / raw)
  To: Wolfram Sang; +Cc: Geliang Tang, linux-i2c, linux-kernel

Use setup_timer() instead of init_timer() to simplify the code.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
---
 drivers/i2c/busses/i2c-img-scb.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/i2c/busses/i2c-img-scb.c b/drivers/i2c/busses/i2c-img-scb.c
index db8e8b4..84fb35f 100644
--- a/drivers/i2c/busses/i2c-img-scb.c
+++ b/drivers/i2c/busses/i2c-img-scb.c
@@ -1362,9 +1362,8 @@ static int img_i2c_probe(struct platform_device *pdev)
 	}
 
 	/* Set up the exception check timer */
-	init_timer(&i2c->check_timer);
-	i2c->check_timer.function = img_i2c_check_timer;
-	i2c->check_timer.data = (unsigned long)i2c;
+	setup_timer(&i2c->check_timer, img_i2c_check_timer,
+		    (unsigned long)i2c);
 
 	i2c->bitrate = timings[0].max_bitrate;
 	if (!of_property_read_u32(node, "clock-frequency", &val))
-- 
2.9.3

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

* [PATCH] ide: use setup_timer
  2017-04-09  1:41 [PATCH] dmaengine: ioat: use setup_timer Geliang Tang
  2017-04-09  1:41 ` [PATCH] i2c: img-scb: " Geliang Tang
@ 2017-04-09  1:41 ` Geliang Tang
  2017-05-08 21:37   ` David Miller
  2017-04-09  1:41 ` [PATCH] SGI-XP: " Geliang Tang
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 8+ messages in thread
From: Geliang Tang @ 2017-04-09  1:41 UTC (permalink / raw)
  To: David S. Miller; +Cc: Geliang Tang, linux-ide, linux-kernel

Use setup_timer() instead of init_timer() to simplify the code.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
---
 drivers/ide/ide-probe.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c
index a74ae8df..0235625 100644
--- a/drivers/ide/ide-probe.c
+++ b/drivers/ide/ide-probe.c
@@ -1183,9 +1183,7 @@ static void ide_init_port_data(ide_hwif_t *hwif, unsigned int index)
 
 	spin_lock_init(&hwif->lock);
 
-	init_timer(&hwif->timer);
-	hwif->timer.function = &ide_timer_expiry;
-	hwif->timer.data = (unsigned long)hwif;
+	setup_timer(&hwif->timer, &ide_timer_expiry, (unsigned long)hwif);
 
 	init_completion(&hwif->gendev_rel_comp);
 
-- 
2.9.3

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

* [PATCH] SGI-XP: use setup_timer
  2017-04-09  1:41 [PATCH] dmaengine: ioat: use setup_timer Geliang Tang
  2017-04-09  1:41 ` [PATCH] i2c: img-scb: " Geliang Tang
  2017-04-09  1:41 ` [PATCH] ide: " Geliang Tang
@ 2017-04-09  1:41 ` Geliang Tang
  2017-04-09 18:04 ` [PATCH] dmaengine: ioat: " Dan Williams
  2017-04-24  4:09 ` Vinod Koul
  4 siblings, 0 replies; 8+ messages in thread
From: Geliang Tang @ 2017-04-09  1:41 UTC (permalink / raw)
  To: Cliff Whickman, Robin Holt; +Cc: Geliang Tang, linux-kernel

Use setup_timer() instead of init_timer() to simplify the code.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
---
 drivers/misc/sgi-xp/xpc_main.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/misc/sgi-xp/xpc_main.c b/drivers/misc/sgi-xp/xpc_main.c
index 7f32712..a1b6f75 100644
--- a/drivers/misc/sgi-xp/xpc_main.c
+++ b/drivers/misc/sgi-xp/xpc_main.c
@@ -931,10 +931,9 @@ xpc_setup_partitions(void)
 		part->act_state = XPC_P_AS_INACTIVE;
 		XPC_SET_REASON(part, 0, 0);
 
-		init_timer(&part->disengage_timer);
-		part->disengage_timer.function =
-		    xpc_timeout_partition_disengage;
-		part->disengage_timer.data = (unsigned long)part;
+		setup_timer(&part->disengage_timer,
+			    xpc_timeout_partition_disengage,
+			    (unsigned long)part);
 
 		part->setup_state = XPC_P_SS_UNSET;
 		init_waitqueue_head(&part->teardown_wq);
-- 
2.9.3

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

* Re: [PATCH] dmaengine: ioat: use setup_timer
  2017-04-09  1:41 [PATCH] dmaengine: ioat: use setup_timer Geliang Tang
                   ` (2 preceding siblings ...)
  2017-04-09  1:41 ` [PATCH] SGI-XP: " Geliang Tang
@ 2017-04-09 18:04 ` Dan Williams
  2017-04-24  4:09 ` Vinod Koul
  4 siblings, 0 replies; 8+ messages in thread
From: Dan Williams @ 2017-04-09 18:04 UTC (permalink / raw)
  To: Geliang Tang; +Cc: Vinod Koul, Dave Jiang, dmaengine, linux-kernel

On Sat, Apr 8, 2017 at 6:41 PM, Geliang Tang <geliangtang@gmail.com> wrote:
> Use setup_timer() instead of init_timer() to simplify the code.
>
> Signed-off-by: Geliang Tang <geliangtang@gmail.com>
> ---
>  drivers/dma/ioat/init.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/dma/ioat/init.c b/drivers/dma/ioat/init.c
> index cc5259b..6ad4384 100644
> --- a/drivers/dma/ioat/init.c
> +++ b/drivers/dma/ioat/init.c
> @@ -760,9 +760,7 @@ ioat_init_channel(struct ioatdma_device *ioat_dma,
>         dma_cookie_init(&ioat_chan->dma_chan);
>         list_add_tail(&ioat_chan->dma_chan.device_node, &dma->channels);
>         ioat_dma->idx[idx] = ioat_chan;
> -       init_timer(&ioat_chan->timer);
> -       ioat_chan->timer.function = ioat_timer_event;
> -       ioat_chan->timer.data = data;
> +       setup_timer(&ioat_chan->timer, ioat_timer_event, data);
>         tasklet_init(&ioat_chan->cleanup_task, ioat_cleanup_event, data);
>  }
>
> --
> 2.9.3
>

Reviewed-by: Dan Williams <dan.j.williams@intel.com>

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

* Re: [PATCH] i2c: img-scb: use setup_timer
  2017-04-09  1:41 ` [PATCH] i2c: img-scb: " Geliang Tang
@ 2017-04-16 19:51   ` Wolfram Sang
  0 siblings, 0 replies; 8+ messages in thread
From: Wolfram Sang @ 2017-04-16 19:51 UTC (permalink / raw)
  To: Geliang Tang; +Cc: linux-i2c, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 223 bytes --]

On Sun, Apr 09, 2017 at 09:41:31AM +0800, Geliang Tang wrote:
> Use setup_timer() instead of init_timer() to simplify the code.
> 
> Signed-off-by: Geliang Tang <geliangtang@gmail.com>

Applied to for-next, thanks!


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH] dmaengine: ioat: use setup_timer
  2017-04-09  1:41 [PATCH] dmaengine: ioat: use setup_timer Geliang Tang
                   ` (3 preceding siblings ...)
  2017-04-09 18:04 ` [PATCH] dmaengine: ioat: " Dan Williams
@ 2017-04-24  4:09 ` Vinod Koul
  4 siblings, 0 replies; 8+ messages in thread
From: Vinod Koul @ 2017-04-24  4:09 UTC (permalink / raw)
  To: Geliang Tang; +Cc: Dan Williams, Dave Jiang, dmaengine, linux-kernel

On Sun, Apr 09, 2017 at 09:41:30AM +0800, Geliang Tang wrote:
> Use setup_timer() instead of init_timer() to simplify the code.

Applied, thanks

-- 
~Vinod

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

* Re: [PATCH] ide: use setup_timer
  2017-04-09  1:41 ` [PATCH] ide: " Geliang Tang
@ 2017-05-08 21:37   ` David Miller
  0 siblings, 0 replies; 8+ messages in thread
From: David Miller @ 2017-05-08 21:37 UTC (permalink / raw)
  To: geliangtang; +Cc: linux-ide, linux-kernel

From: Geliang Tang <geliangtang@gmail.com>
Date: Sun,  9 Apr 2017 09:41:32 +0800

> Use setup_timer() instead of init_timer() to simplify the code.
> 
> Signed-off-by: Geliang Tang <geliangtang@gmail.com>

Applied.

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

end of thread, other threads:[~2017-05-08 21:37 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-09  1:41 [PATCH] dmaengine: ioat: use setup_timer Geliang Tang
2017-04-09  1:41 ` [PATCH] i2c: img-scb: " Geliang Tang
2017-04-16 19:51   ` Wolfram Sang
2017-04-09  1:41 ` [PATCH] ide: " Geliang Tang
2017-05-08 21:37   ` David Miller
2017-04-09  1:41 ` [PATCH] SGI-XP: " Geliang Tang
2017-04-09 18:04 ` [PATCH] dmaengine: ioat: " Dan Williams
2017-04-24  4:09 ` Vinod Koul

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).