All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] i2c-mux-pca9541: fix setup_timer.cocci warnings
@ 2016-04-27 19:06 Julia Lawall
  2016-04-27 21:42   ` Peter Rosin
  2016-05-11 15:14 ` Wolfram Sang
  0 siblings, 2 replies; 4+ messages in thread
From: Julia Lawall @ 2016-04-27 19:06 UTC (permalink / raw)
  To: Corey Minyard, Guenter Roeck, Wolfram Sang
  Cc: kbuild-all, linux-i2c, linux-kernel

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

Generated by: scripts/coccinelle/api/setup_timer.cocci

Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
---

tree:   git://git.code.sf.net/p/openipmi/linux-ipmi v4.5-ipmi
head:   671fec027e30fdac67b341f0271841f02db0a027
commit: 4a199ab1bf7b7a2b5f7e0b0eb4162b4e98b9cd7f [25/33] i2c-mux-pca9541: 
Add support for non-blocking handling

 i2c-mux-pca9541.c |    4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

--- a/drivers/i2c/muxes/i2c-mux-pca9541.c
+++ b/drivers/i2c/muxes/i2c-mux-pca9541.c
@@ -547,9 +547,7 @@ static int pca9541_probe(struct i2c_clie
 	data->op_e.smbus.data = &data->op_data;
 	data->op_e.smbus.size = I2C_SMBUS_BYTE_DATA;
 
-	init_timer(&data->timer);
-	data->timer.data = (unsigned long) data;
-	data->timer.function = pca9541_timeout;
+	setup_timer(&data->timer, pca9541_timeout, (unsigned long)data);
 
 	/*
 	 * I2C accesses are unprotected here.

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

* Re: [PATCH] i2c-mux-pca9541: fix setup_timer.cocci warnings
  2016-04-27 19:06 [PATCH] i2c-mux-pca9541: fix setup_timer.cocci warnings Julia Lawall
@ 2016-04-27 21:42   ` Peter Rosin
  2016-05-11 15:14 ` Wolfram Sang
  1 sibling, 0 replies; 4+ messages in thread
From: Peter Rosin @ 2016-04-27 21:42 UTC (permalink / raw)
  To: Julia Lawall, Corey Minyard, Guenter Roeck, Wolfram Sang
  Cc: kbuild-all, linux-i2c, linux-kernel

On 2016-04-27 21:06, Julia Lawall wrote:
> Use setup_timer function instead of initializing timer with the function
> and data fields
>
> Generated by: scripts/coccinelle/api/setup_timer.cocci
>
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
> Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
>
Acked-by: Peter Rosin <peda@axentia.se>

Cheers,
Peter

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

* Re: [PATCH] i2c-mux-pca9541: fix setup_timer.cocci warnings
@ 2016-04-27 21:42   ` Peter Rosin
  0 siblings, 0 replies; 4+ messages in thread
From: Peter Rosin @ 2016-04-27 21:42 UTC (permalink / raw)
  To: Julia Lawall, Corey Minyard, Guenter Roeck, Wolfram Sang
  Cc: kbuild-all, linux-i2c, linux-kernel

On 2016-04-27 21:06, Julia Lawall wrote:
> Use setup_timer function instead of initializing timer with the function
> and data fields
>
> Generated by: scripts/coccinelle/api/setup_timer.cocci
>
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
> Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
>
Acked-by: Peter Rosin <peda@axentia.se>

Cheers,
Peter

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

* Re: [PATCH] i2c-mux-pca9541: fix setup_timer.cocci warnings
  2016-04-27 19:06 [PATCH] i2c-mux-pca9541: fix setup_timer.cocci warnings Julia Lawall
  2016-04-27 21:42   ` Peter Rosin
@ 2016-05-11 15:14 ` Wolfram Sang
  1 sibling, 0 replies; 4+ messages in thread
From: Wolfram Sang @ 2016-05-11 15:14 UTC (permalink / raw)
  To: Julia Lawall
  Cc: Corey Minyard, Guenter Roeck, kbuild-all, linux-i2c, linux-kernel

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

On Wed, Apr 27, 2016 at 09:06:47PM +0200, Julia Lawall wrote:
> Use setup_timer function instead of initializing timer with the function
> and data fields
> 
> Generated by: scripts/coccinelle/api/setup_timer.cocci
> 
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
> Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
> ---
> 
> tree:   git://git.code.sf.net/p/openipmi/linux-ipmi v4.5-ipmi

Why is this patch sent to the i2c-list? This patch does not apply
upstream. If it is really needed to send this to the i2c list, it should
be stated very clearly that this is not for upstream.


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

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

end of thread, other threads:[~2016-05-11 15:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-27 19:06 [PATCH] i2c-mux-pca9541: fix setup_timer.cocci warnings Julia Lawall
2016-04-27 21:42 ` Peter Rosin
2016-04-27 21:42   ` Peter Rosin
2016-05-11 15:14 ` Wolfram Sang

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.