All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/4] blacklight: Remove redundant spi driver bus initialization
@ 2012-04-10 20:51 Lars-Peter Clausen
  2012-04-10 20:51 ` [PATCH 2/4] can: " Lars-Peter Clausen
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Lars-Peter Clausen @ 2012-04-10 20:51 UTC (permalink / raw)
  To: linux-kernel; +Cc: Lars-Peter Clausen, Richard Purdie, Andrew Morton

In ancient times it was necessary to manually initialize the bus field of an
spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
we can drop the manual assignment.

The patch was generated using the following coccinelle semantic patch:
// <smpl>
@@
identifier _driver;
@@
struct spi_driver _driver = {
	.driver = {
-		.bus = &spi_bus_type,
	},
};
// </smpl>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Cc: Richard Purdie <rpurdie@rpsys.net>
Cc: Andrew Morton <akpm@linux-foundation.org>
---
 drivers/video/backlight/ams369fg06.c |    1 -
 drivers/video/backlight/ld9040.c     |    1 -
 drivers/video/backlight/ltv350qv.c   |    1 -
 drivers/video/backlight/s6e63m0.c    |    1 -
 4 files changed, 4 deletions(-)

diff --git a/drivers/video/backlight/ams369fg06.c b/drivers/video/backlight/ams369fg06.c
index 7bdadc7..d2494c5 100644
--- a/drivers/video/backlight/ams369fg06.c
+++ b/drivers/video/backlight/ams369fg06.c
@@ -619,7 +619,6 @@ static void ams369fg06_shutdown(struct spi_device *spi)
 static struct spi_driver ams369fg06_driver = {
 	.driver = {
 		.name	= "ams369fg06",
-		.bus	= &spi_bus_type,
 		.owner	= THIS_MODULE,
 	},
 	.probe		= ams369fg06_probe,
diff --git a/drivers/video/backlight/ld9040.c b/drivers/video/backlight/ld9040.c
index efd352b..2ea06a5f 100644
--- a/drivers/video/backlight/ld9040.c
+++ b/drivers/video/backlight/ld9040.c
@@ -846,7 +846,6 @@ static void ld9040_shutdown(struct spi_device *spi)
 static struct spi_driver ld9040_driver = {
 	.driver = {
 		.name	= "ld9040",
-		.bus	= &spi_bus_type,
 		.owner	= THIS_MODULE,
 	},
 	.probe		= ld9040_probe,
diff --git a/drivers/video/backlight/ltv350qv.c b/drivers/video/backlight/ltv350qv.c
index 333949f..d23922f 100644
--- a/drivers/video/backlight/ltv350qv.c
+++ b/drivers/video/backlight/ltv350qv.c
@@ -310,7 +310,6 @@ static void ltv350qv_shutdown(struct spi_device *spi)
 static struct spi_driver ltv350qv_driver = {
 	.driver = {
 		.name		= "ltv350qv",
-		.bus		= &spi_bus_type,
 		.owner		= THIS_MODULE,
 	},
 
diff --git a/drivers/video/backlight/s6e63m0.c b/drivers/video/backlight/s6e63m0.c
index e264f55..3ed05c7 100644
--- a/drivers/video/backlight/s6e63m0.c
+++ b/drivers/video/backlight/s6e63m0.c
@@ -899,7 +899,6 @@ static void s6e63m0_shutdown(struct spi_device *spi)
 static struct spi_driver s6e63m0_driver = {
 	.driver = {
 		.name	= "s6e63m0",
-		.bus	= &spi_bus_type,
 		.owner	= THIS_MODULE,
 	},
 	.probe		= s6e63m0_probe,
-- 
1.7.9.5


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

* [PATCH 2/4] can: Remove redundant spi driver bus initialization
  2012-04-10 20:51 [PATCH 1/4] blacklight: Remove redundant spi driver bus initialization Lars-Peter Clausen
@ 2012-04-10 20:51 ` Lars-Peter Clausen
  2012-04-10 20:51 ` [PATCH 3/4] mfd: " Lars-Peter Clausen
  2012-04-10 20:51 ` [PATCH 4/4] net: " Lars-Peter Clausen
  2 siblings, 0 replies; 8+ messages in thread
From: Lars-Peter Clausen @ 2012-04-10 20:51 UTC (permalink / raw)
  To: linux-kernel; +Cc: Lars-Peter Clausen, Wolfgang Grandegger, linux-can

In ancient times it was necessary to manually initialize the bus field of an
spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
we can drop the manual assignment.

The patch was generated using the following coccinelle semantic patch:
// <smpl>
@@
identifier _driver;
@@
struct spi_driver _driver = {
	.driver = {
-		.bus = &spi_bus_type,
	},
};
// </smpl>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Cc: Wolfgang Grandegger <wg@grandegger.com>
Cc: linux-can@vger.kernel.org
Acked-by: Marc Kleine-Budde <mkl@pengutronix.de>
---
 drivers/net/can/mcp251x.c |    1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/can/mcp251x.c b/drivers/net/can/mcp251x.c
index 346785c..2bccaf7 100644
--- a/drivers/net/can/mcp251x.c
+++ b/drivers/net/can/mcp251x.c
@@ -1184,7 +1184,6 @@ MODULE_DEVICE_TABLE(spi, mcp251x_id_table);
 static struct spi_driver mcp251x_can_driver = {
 	.driver = {
 		.name = DEVICE_NAME,
-		.bus = &spi_bus_type,
 		.owner = THIS_MODULE,
 	},
 
-- 
1.7.9.5

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

* [PATCH 3/4] mfd: Remove redundant spi driver bus initialization
  2012-04-10 20:51 [PATCH 1/4] blacklight: Remove redundant spi driver bus initialization Lars-Peter Clausen
  2012-04-10 20:51 ` [PATCH 2/4] can: " Lars-Peter Clausen
@ 2012-04-10 20:51 ` Lars-Peter Clausen
  2012-04-11  8:39   ` Linus Walleij
  2012-04-16 16:08   ` Samuel Ortiz
  2012-04-10 20:51 ` [PATCH 4/4] net: " Lars-Peter Clausen
  2 siblings, 2 replies; 8+ messages in thread
From: Lars-Peter Clausen @ 2012-04-10 20:51 UTC (permalink / raw)
  To: linux-kernel
  Cc: Lars-Peter Clausen, Samuel Ortiz, Srinidhi Kasagar, Linus Walleij

In ancient times it was necessary to manually initialize the bus field of an
spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
we can drop the manual assignment.

The patch was generated using the following coccinelle semantic patch:
// <smpl>
@@
identifier _driver;
@@
struct spi_driver _driver = {
    .driver = {
-           .bus = &spi_bus_type,
    },
};
// </smpl>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Cc: Samuel Ortiz <sameo@linux.intel.com>
Cc: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
Cc: Linus Walleij <linus.walleij@stericsson.com>

---
 drivers/mfd/da9052-spi.c |    1 -
 drivers/mfd/stmpe-spi.c  |    1 -
 2 files changed, 2 deletions(-)

diff --git a/drivers/mfd/da9052-spi.c b/drivers/mfd/da9052-spi.c
index 6faf149..6e09498 100644
--- a/drivers/mfd/da9052-spi.c
+++ b/drivers/mfd/da9052-spi.c
@@ -88,7 +88,6 @@ static struct spi_driver da9052_spi_driver = {
 	.id_table = da9052_spi_id,
 	.driver = {
 		.name = "da9052",
-		.bus = &spi_bus_type,
 		.owner = THIS_MODULE,
 	},
 };
diff --git a/drivers/mfd/stmpe-spi.c b/drivers/mfd/stmpe-spi.c
index b58c43c..afd4590 100644
--- a/drivers/mfd/stmpe-spi.c
+++ b/drivers/mfd/stmpe-spi.c
@@ -122,7 +122,6 @@ MODULE_DEVICE_TABLE(spi, stmpe_id);
 static struct spi_driver stmpe_spi_driver = {
 	.driver = {
 		.name	= "stmpe-spi",
-		.bus	= &spi_bus_type,
 		.owner	= THIS_MODULE,
 #ifdef CONFIG_PM
 		.pm	= &stmpe_dev_pm_ops,
-- 
1.7.9.5


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

* [PATCH 4/4] net: Remove redundant spi driver bus initialization
  2012-04-10 20:51 [PATCH 1/4] blacklight: Remove redundant spi driver bus initialization Lars-Peter Clausen
  2012-04-10 20:51 ` [PATCH 2/4] can: " Lars-Peter Clausen
  2012-04-10 20:51 ` [PATCH 3/4] mfd: " Lars-Peter Clausen
@ 2012-04-10 20:51 ` Lars-Peter Clausen
  2012-04-12  6:23   ` Gabor Juhos
  2012-04-13 17:13   ` David Miller
  2 siblings, 2 replies; 8+ messages in thread
From: Lars-Peter Clausen @ 2012-04-10 20:51 UTC (permalink / raw)
  To: linux-kernel
  Cc: Lars-Peter Clausen, David S. Miller, Gabor Juhos,
	Frederic Lambert, netdev

In ancient times it was necessary to manually initialize the bus field of an
spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
we can drop the manual assignment.

The patch was generated using the following coccinelle semantic patch:
// <smpl>
@@
identifier _driver;
@@
struct spi_driver _driver = {
	.driver = {
-		.bus = &spi_bus_type,
	},
};
// </smpl>

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Gabor Juhos <juhosg@openwrt.org>
Cc: Frederic Lambert <frdrc66@gmail.com>
Cc: netdev@vger.kernel.org
---
 drivers/net/phy/spi_ks8995.c |    1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/phy/spi_ks8995.c b/drivers/net/phy/spi_ks8995.c
index 116a2dd..4eb98bc 100644
--- a/drivers/net/phy/spi_ks8995.c
+++ b/drivers/net/phy/spi_ks8995.c
@@ -348,7 +348,6 @@ static int __devexit ks8995_remove(struct spi_device *spi)
 static struct spi_driver ks8995_driver = {
 	.driver = {
 		.name	    = "spi-ks8995",
-		.bus	     = &spi_bus_type,
 		.owner	   = THIS_MODULE,
 	},
 	.probe	  = ks8995_probe,
-- 
1.7.9.5


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

* Re: [PATCH 3/4] mfd: Remove redundant spi driver bus initialization
  2012-04-10 20:51 ` [PATCH 3/4] mfd: " Lars-Peter Clausen
@ 2012-04-11  8:39   ` Linus Walleij
  2012-04-16 16:08   ` Samuel Ortiz
  1 sibling, 0 replies; 8+ messages in thread
From: Linus Walleij @ 2012-04-11  8:39 UTC (permalink / raw)
  To: Lars-Peter Clausen
  Cc: linux-kernel, Samuel Ortiz, Srinidhi Kasagar, Linus Walleij

On Tue, Apr 10, 2012 at 10:51 PM, Lars-Peter Clausen <lars@metafoo.de> wrote:

> In ancient times it was necessary to manually initialize the bus field of an
> spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
> we can drop the manual assignment.
>
> The patch was generated using the following coccinelle semantic patch:
> // <smpl>
> @@
> identifier _driver;
> @@
> struct spi_driver _driver = {
>    .driver = {
> -           .bus = &spi_bus_type,
>    },
> };
> // </smpl>
>
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> Cc: Samuel Ortiz <sameo@linux.intel.com>
> Cc: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
> Cc: Linus Walleij <linus.walleij@stericsson.com>

Looks good to me.
Acked-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

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

* Re: [PATCH 4/4] net: Remove redundant spi driver bus initialization
  2012-04-10 20:51 ` [PATCH 4/4] net: " Lars-Peter Clausen
@ 2012-04-12  6:23   ` Gabor Juhos
  2012-04-13 17:13   ` David Miller
  1 sibling, 0 replies; 8+ messages in thread
From: Gabor Juhos @ 2012-04-12  6:23 UTC (permalink / raw)
  To: Lars-Peter Clausen
  Cc: linux-kernel, David S. Miller, Frederic Lambert, netdev

2012.04.10. 22:51 keltezéssel, Lars-Peter Clausen írta:
> In ancient times it was necessary to manually initialize the bus field of an
> spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
> we can drop the manual assignment.
> 
> The patch was generated using the following coccinelle semantic patch:
> // <smpl>
> @@
> identifier _driver;
> @@
> struct spi_driver _driver = {
> 	.driver = {
> -		.bus = &spi_bus_type,
> 	},
> };
> // </smpl>
> 
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> Cc: "David S. Miller" <davem@davemloft.net>
> Cc: Gabor Juhos <juhosg@openwrt.org>
> Cc: Frederic Lambert <frdrc66@gmail.com>
> Cc: netdev@vger.kernel.org
> ---
>  drivers/net/phy/spi_ks8995.c |    1 -
>  1 file changed, 1 deletion(-)

Acked-by: Gabor Juhos <juhosg@openwrt.org>

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

* Re: [PATCH 4/4] net: Remove redundant spi driver bus initialization
  2012-04-10 20:51 ` [PATCH 4/4] net: " Lars-Peter Clausen
  2012-04-12  6:23   ` Gabor Juhos
@ 2012-04-13 17:13   ` David Miller
  1 sibling, 0 replies; 8+ messages in thread
From: David Miller @ 2012-04-13 17:13 UTC (permalink / raw)
  To: lars; +Cc: linux-kernel, juhosg, frdrc66, netdev

From: Lars-Peter Clausen <lars@metafoo.de>
Date: Tue, 10 Apr 2012 22:51:29 +0200

> In ancient times it was necessary to manually initialize the bus field of an
> spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
> we can drop the manual assignment.
> 
> The patch was generated using the following coccinelle semantic patch:
> // <smpl>
> @@
> identifier _driver;
> @@
> struct spi_driver _driver = {
> 	.driver = {
> -		.bus = &spi_bus_type,
> 	},
> };
> // </smpl>
> 
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>

Applied to net-next, thanks.

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

* Re: [PATCH 3/4] mfd: Remove redundant spi driver bus initialization
  2012-04-10 20:51 ` [PATCH 3/4] mfd: " Lars-Peter Clausen
  2012-04-11  8:39   ` Linus Walleij
@ 2012-04-16 16:08   ` Samuel Ortiz
  1 sibling, 0 replies; 8+ messages in thread
From: Samuel Ortiz @ 2012-04-16 16:08 UTC (permalink / raw)
  To: Lars-Peter Clausen; +Cc: linux-kernel, Srinidhi Kasagar, Linus Walleij

Hi Lars-Peter,

On Tue, Apr 10, 2012 at 10:51:28PM +0200, Lars-Peter Clausen wrote:
> In ancient times it was necessary to manually initialize the bus field of an
> spi_driver to spi_bus_type. These days this is done in spi_driver_register() so
> we can drop the manual assignment.
> 
> The patch was generated using the following coccinelle semantic patch:
> // <smpl>
> @@
> identifier _driver;
> @@
> struct spi_driver _driver = {
>     .driver = {
> -           .bus = &spi_bus_type,
>     },
> };
> // </smpl>
> 
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> Cc: Samuel Ortiz <sameo@linux.intel.com>
> Cc: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com>
> Cc: Linus Walleij <linus.walleij@stericsson.com>
Looks good, patch applied to my for-next branch. Thanks.

Cheers,
Samuel.

-- 
Intel Open Source Technology Centre
http://oss.intel.com/

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

end of thread, other threads:[~2012-04-16 15:59 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-04-10 20:51 [PATCH 1/4] blacklight: Remove redundant spi driver bus initialization Lars-Peter Clausen
2012-04-10 20:51 ` [PATCH 2/4] can: " Lars-Peter Clausen
2012-04-10 20:51 ` [PATCH 3/4] mfd: " Lars-Peter Clausen
2012-04-11  8:39   ` Linus Walleij
2012-04-16 16:08   ` Samuel Ortiz
2012-04-10 20:51 ` [PATCH 4/4] net: " Lars-Peter Clausen
2012-04-12  6:23   ` Gabor Juhos
2012-04-13 17:13   ` David Miller

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.