linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH TRIVIAL 0/5] Input: use new macro module_platform_driver to save some boilerplate code
@ 2011-11-22  9:00 JJ Ding
  2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
                   ` (4 more replies)
  0 siblings, 5 replies; 15+ messages in thread
From: JJ Ding @ 2011-11-22  9:00 UTC (permalink / raw)
  To: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely
  Cc: linux-kernel, linux-input, JJ Ding

Hi List,

With commit 940ab88962bc1aff3273a8356d64577a6e386736 Grant Likely added a new
macro module_platform_driver to save some boilerplate code for platform_driver.
This patchset converts these platform_driver's in input subsystem to use it.

I am not quite sure if it's worth it to convert all these drivers, but I did it
anyway, because:
 - by converting we encourage new code to use it.
 - as a kernel newbie I take it as exercises.

Patches are against Linus' latest tree, I split the whole converting into 5
patches for easier reviewing. Please take a look, thank you very much.

-jj

JJ Ding (5):
  Input: keyboard: use macro module_platform_driver()
  Input: misc: use macro module_platform_driver()
  Input: mouse: use macro module_platform_driver()
  Input: serio: use macro module_platform_driver()
  Input: touchscreen: use macro module_platform_driver()

 drivers/input/keyboard/adp5520-keys.c        |   13 +------------
 drivers/input/keyboard/amikbd.c              |   15 +--------------
 drivers/input/keyboard/bf54x-keys.c          |   14 +-------------
 drivers/input/keyboard/davinci_keyscan.c     |   13 +------------
 drivers/input/keyboard/ep93xx_keypad.c       |   14 +-------------
 drivers/input/keyboard/gpio_keys_polled.c    |   14 +-------------
 drivers/input/keyboard/imx_keypad.c          |   14 +-------------
 drivers/input/keyboard/jornada680_kbd.c      |   14 +-------------
 drivers/input/keyboard/jornada720_kbd.c      |   14 +-------------
 drivers/input/keyboard/matrix_keypad.c       |   14 +-------------
 drivers/input/keyboard/nomadik-ske-keypad.c  |   13 +------------
 drivers/input/keyboard/omap-keypad.c         |   15 +--------------
 drivers/input/keyboard/omap4-keypad.c        |   13 +------------
 drivers/input/keyboard/opencores-kbd.c       |   13 +------------
 drivers/input/keyboard/pmic8xxx-keypad.c     |   13 +------------
 drivers/input/keyboard/pxa27x_keypad.c       |   14 +-------------
 drivers/input/keyboard/pxa930_rotary.c       |   13 +------------
 drivers/input/keyboard/samsung-keypad.c      |   13 +------------
 drivers/input/keyboard/sh_keysc.c            |   14 +-------------
 drivers/input/keyboard/spear-keyboard.c      |   13 +------------
 drivers/input/keyboard/stmpe-keypad.c        |   13 +------------
 drivers/input/keyboard/tc3589x-keypad.c      |   13 +------------
 drivers/input/keyboard/tegra-kbc.c           |   13 +------------
 drivers/input/keyboard/tnetv107x-keypad.c    |   14 +-------------
 drivers/input/keyboard/twl4030_keypad.c      |   13 +------------
 drivers/input/keyboard/w90p910_keypad.c      |   14 +-------------
 drivers/input/misc/88pm860x_onkey.c          |   13 +------------
 drivers/input/misc/ab8500-ponkey.c           |   13 +------------
 drivers/input/misc/bfin_rotary.c             |   13 +------------
 drivers/input/misc/cobalt_btns.c             |   14 +-------------
 drivers/input/misc/dm355evm_keys.c           |   13 +------------
 drivers/input/misc/ixp4xx-beeper.c           |   13 +------------
 drivers/input/misc/max8925_onkey.c           |   13 +------------
 drivers/input/misc/pcap_keys.c               |   14 +-------------
 drivers/input/misc/pcf50633-input.c          |   13 +------------
 drivers/input/misc/pcspkr.c                  |   14 +-------------
 drivers/input/misc/pm8xxx-vibrator.c         |   13 +------------
 drivers/input/misc/pmic8xxx-pwrkey.c         |   13 +------------
 drivers/input/misc/pwm-beeper.c              |   13 +------------
 drivers/input/misc/rb532_button.c            |   14 +-------------
 drivers/input/misc/rotary_encoder.c          |   14 +-------------
 drivers/input/misc/sgi_btns.c                |   13 +------------
 drivers/input/misc/twl4030-pwrbutton.c       |   15 ++-------------
 drivers/input/misc/twl4030-vibra.c           |   14 +-------------
 drivers/input/misc/twl6040-vibra.c           |   13 +------------
 drivers/input/misc/wm831x-on.c               |   13 +------------
 drivers/input/mouse/amimouse.c               |   16 ++--------------
 drivers/input/mouse/gpio_mouse.c             |   13 +------------
 drivers/input/mouse/pxa930_trkball.c         |   14 +-------------
 drivers/input/serio/altera_ps2.c             |   13 +------------
 drivers/input/serio/at32psif.c               |   14 +-------------
 drivers/input/serio/rpckbd.c                 |   14 +-------------
 drivers/input/serio/xilinx_ps2.c             |   14 +-------------
 drivers/input/touchscreen/88pm860x-ts.c      |   13 +------------
 drivers/input/touchscreen/atmel-wm97xx.c     |   13 +------------
 drivers/input/touchscreen/atmel_tsadcc.c     |   15 +--------------
 drivers/input/touchscreen/da9034-ts.c        |   13 +------------
 drivers/input/touchscreen/intel-mid-touch.c  |   13 +------------
 drivers/input/touchscreen/jornada720_ts.c    |   14 +-------------
 drivers/input/touchscreen/lpc32xx_ts.c       |   13 +------------
 drivers/input/touchscreen/mainstone-wm97xx.c |   14 +-------------
 drivers/input/touchscreen/mc13783_ts.c       |   13 +------------
 drivers/input/touchscreen/pcap_ts.c          |   14 +-------------
 drivers/input/touchscreen/s3c2410_ts.c       |   14 +-------------
 drivers/input/touchscreen/stmpe-ts.c         |   15 +--------------
 drivers/input/touchscreen/tnetv107x-ts.c     |   14 +-------------
 drivers/input/touchscreen/tps6507x-ts.c      |   13 +------------
 drivers/input/touchscreen/ucb1400_ts.c       |   14 +-------------
 drivers/input/touchscreen/w90p910_ts.c       |   14 +-------------
 drivers/input/touchscreen/wm831x-ts.c        |   13 +------------
 drivers/input/touchscreen/zylonite-wm97xx.c  |   14 +-------------
 71 files changed, 73 insertions(+), 892 deletions(-)

-- 
1.7.8-rc2


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

* [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2011-11-22  9:00 [PATCH TRIVIAL 0/5] Input: use new macro module_platform_driver to save some boilerplate code JJ Ding
@ 2011-11-22  9:00 ` JJ Ding
  2011-11-22  9:23   ` Linus Walleij
                     ` (3 more replies)
  2011-11-22  9:00 ` [PATCH TRIVIAL 2/5] Input: misc: " JJ Ding
                   ` (3 subsequent siblings)
  4 siblings, 4 replies; 15+ messages in thread
From: JJ Ding @ 2011-11-22  9:00 UTC (permalink / raw)
  To: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely
  Cc: linux-kernel, linux-input, JJ Ding, JJ Ding

From: JJ Ding <dgdunix@gmail.com>

Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
save some platform_driver boilerplate code. Use it.

Signed-off-by: JJ Ding <dgdunix@gmail.com>
---
 drivers/input/keyboard/adp5520-keys.c       |   13 +------------
 drivers/input/keyboard/amikbd.c             |   15 +--------------
 drivers/input/keyboard/bf54x-keys.c         |   14 +-------------
 drivers/input/keyboard/davinci_keyscan.c    |   13 +------------
 drivers/input/keyboard/ep93xx_keypad.c      |   14 +-------------
 drivers/input/keyboard/gpio_keys_polled.c   |   14 +-------------
 drivers/input/keyboard/imx_keypad.c         |   14 +-------------
 drivers/input/keyboard/jornada680_kbd.c     |   14 +-------------
 drivers/input/keyboard/jornada720_kbd.c     |   14 +-------------
 drivers/input/keyboard/matrix_keypad.c      |   14 +-------------
 drivers/input/keyboard/nomadik-ske-keypad.c |   13 +------------
 drivers/input/keyboard/omap-keypad.c        |   15 +--------------
 drivers/input/keyboard/omap4-keypad.c       |   13 +------------
 drivers/input/keyboard/opencores-kbd.c      |   13 +------------
 drivers/input/keyboard/pmic8xxx-keypad.c    |   13 +------------
 drivers/input/keyboard/pxa27x_keypad.c      |   14 +-------------
 drivers/input/keyboard/pxa930_rotary.c      |   13 +------------
 drivers/input/keyboard/samsung-keypad.c     |   13 +------------
 drivers/input/keyboard/sh_keysc.c           |   14 +-------------
 drivers/input/keyboard/spear-keyboard.c     |   13 +------------
 drivers/input/keyboard/stmpe-keypad.c       |   13 +------------
 drivers/input/keyboard/tc3589x-keypad.c     |   13 +------------
 drivers/input/keyboard/tegra-kbc.c          |   13 +------------
 drivers/input/keyboard/tnetv107x-keypad.c   |   14 +-------------
 drivers/input/keyboard/twl4030_keypad.c     |   13 +------------
 drivers/input/keyboard/w90p910_keypad.c     |   14 +-------------
 26 files changed, 26 insertions(+), 327 deletions(-)

diff --git a/drivers/input/keyboard/adp5520-keys.c b/drivers/input/keyboard/adp5520-keys.c
index 3db8006..e9e8674 100644
--- a/drivers/input/keyboard/adp5520-keys.c
+++ b/drivers/input/keyboard/adp5520-keys.c
@@ -202,18 +202,7 @@ static struct platform_driver adp5520_keys_driver = {
 	.probe		= adp5520_keys_probe,
 	.remove		= __devexit_p(adp5520_keys_remove),
 };
-
-static int __init adp5520_keys_init(void)
-{
-	return platform_driver_register(&adp5520_keys_driver);
-}
-module_init(adp5520_keys_init);
-
-static void __exit adp5520_keys_exit(void)
-{
-	platform_driver_unregister(&adp5520_keys_driver);
-}
-module_exit(adp5520_keys_exit);
+module_platform_driver(adp5520_keys_driver);
 
 MODULE_AUTHOR("Michael Hennerich <hennerich@blackfin.uclinux.org>");
 MODULE_DESCRIPTION("Keys ADP5520 Driver");
diff --git a/drivers/input/keyboard/amikbd.c b/drivers/input/keyboard/amikbd.c
index 79172af..6df5f6a 100644
--- a/drivers/input/keyboard/amikbd.c
+++ b/drivers/input/keyboard/amikbd.c
@@ -259,19 +259,6 @@ static struct platform_driver amikbd_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init amikbd_init(void)
-{
-	return platform_driver_probe(&amikbd_driver, amikbd_probe);
-}
-
-module_init(amikbd_init);
-
-static void __exit amikbd_exit(void)
-{
-	platform_driver_unregister(&amikbd_driver);
-}
-
-module_exit(amikbd_exit);
+module_platform_driver(amikbd_driver);
 
 MODULE_ALIAS("platform:amiga-keyboard");
diff --git a/drivers/input/keyboard/bf54x-keys.c b/drivers/input/keyboard/bf54x-keys.c
index 7d98960..683e314 100644
--- a/drivers/input/keyboard/bf54x-keys.c
+++ b/drivers/input/keyboard/bf54x-keys.c
@@ -394,19 +394,7 @@ struct platform_driver bfin_kpad_device_driver = {
 	.suspend	= bfin_kpad_suspend,
 	.resume		= bfin_kpad_resume,
 };
-
-static int __init bfin_kpad_init(void)
-{
-	return platform_driver_register(&bfin_kpad_device_driver);
-}
-
-static void __exit bfin_kpad_exit(void)
-{
-	platform_driver_unregister(&bfin_kpad_device_driver);
-}
-
-module_init(bfin_kpad_init);
-module_exit(bfin_kpad_exit);
+module_platform_driver(bfin_kpad_device_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Michael Hennerich <hennerich@blackfin.uclinux.org>");
diff --git a/drivers/input/keyboard/davinci_keyscan.c b/drivers/input/keyboard/davinci_keyscan.c
index 9d82b3a..4698252 100644
--- a/drivers/input/keyboard/davinci_keyscan.c
+++ b/drivers/input/keyboard/davinci_keyscan.c
@@ -328,18 +328,7 @@ static struct platform_driver davinci_ks_driver = {
 	},
 	.remove	= __devexit_p(davinci_ks_remove),
 };
-
-static int __init davinci_ks_init(void)
-{
-	return platform_driver_probe(&davinci_ks_driver, davinci_ks_probe);
-}
-module_init(davinci_ks_init);
-
-static void __exit davinci_ks_exit(void)
-{
-	platform_driver_unregister(&davinci_ks_driver);
-}
-module_exit(davinci_ks_exit);
+module_platform_driver(davinci_ks_driver);
 
 MODULE_AUTHOR("Miguel Aguilar");
 MODULE_DESCRIPTION("Texas Instruments DaVinci Key Scan Driver");
diff --git a/drivers/input/keyboard/ep93xx_keypad.c b/drivers/input/keyboard/ep93xx_keypad.c
index 4662c5d..0ba69f3 100644
--- a/drivers/input/keyboard/ep93xx_keypad.c
+++ b/drivers/input/keyboard/ep93xx_keypad.c
@@ -390,19 +390,7 @@ static struct platform_driver ep93xx_keypad_driver = {
 	.suspend	= ep93xx_keypad_suspend,
 	.resume		= ep93xx_keypad_resume,
 };
-
-static int __init ep93xx_keypad_init(void)
-{
-	return platform_driver_register(&ep93xx_keypad_driver);
-}
-
-static void __exit ep93xx_keypad_exit(void)
-{
-	platform_driver_unregister(&ep93xx_keypad_driver);
-}
-
-module_init(ep93xx_keypad_init);
-module_exit(ep93xx_keypad_exit);
+module_platform_driver(ep93xx_keypad_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("H Hartley Sweeten <hsweeten@visionengravers.com>");
diff --git a/drivers/input/keyboard/gpio_keys_polled.c b/drivers/input/keyboard/gpio_keys_polled.c
index 4c17aff..20c8ab1 100644
--- a/drivers/input/keyboard/gpio_keys_polled.c
+++ b/drivers/input/keyboard/gpio_keys_polled.c
@@ -241,19 +241,7 @@ static struct platform_driver gpio_keys_polled_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init gpio_keys_polled_init(void)
-{
-	return platform_driver_register(&gpio_keys_polled_driver);
-}
-
-static void __exit gpio_keys_polled_exit(void)
-{
-	platform_driver_unregister(&gpio_keys_polled_driver);
-}
-
-module_init(gpio_keys_polled_init);
-module_exit(gpio_keys_polled_exit);
+module_platform_driver(gpio_keys_polled_driver);
 
 MODULE_LICENSE("GPL v2");
 MODULE_AUTHOR("Gabor Juhos <juhosg@openwrt.org>");
diff --git a/drivers/input/keyboard/imx_keypad.c b/drivers/input/keyboard/imx_keypad.c
index ccebd2d..fb87b3b 100644
--- a/drivers/input/keyboard/imx_keypad.c
+++ b/drivers/input/keyboard/imx_keypad.c
@@ -619,19 +619,7 @@ static struct platform_driver imx_keypad_driver = {
 	.probe		= imx_keypad_probe,
 	.remove		= __devexit_p(imx_keypad_remove),
 };
-
-static int __init imx_keypad_init(void)
-{
-	return platform_driver_register(&imx_keypad_driver);
-}
-
-static void __exit imx_keypad_exit(void)
-{
-	platform_driver_unregister(&imx_keypad_driver);
-}
-
-module_init(imx_keypad_init);
-module_exit(imx_keypad_exit);
+module_platform_driver(imx_keypad_driver);
 
 MODULE_AUTHOR("Alberto Panizzo <maramaopercheseimorto@gmail.com>");
 MODULE_DESCRIPTION("IMX Keypad Port Driver");
diff --git a/drivers/input/keyboard/jornada680_kbd.c b/drivers/input/keyboard/jornada680_kbd.c
index 7197c56..24f3ea0 100644
--- a/drivers/input/keyboard/jornada680_kbd.c
+++ b/drivers/input/keyboard/jornada680_kbd.c
@@ -260,19 +260,7 @@ static struct platform_driver jornada680kbd_driver = {
 	.probe	= jornada680kbd_probe,
 	.remove	= __devexit_p(jornada680kbd_remove),
 };
-
-static int __init jornada680kbd_init(void)
-{
-	return platform_driver_register(&jornada680kbd_driver);
-}
-
-static void __exit jornada680kbd_exit(void)
-{
-	platform_driver_unregister(&jornada680kbd_driver);
-}
-
-module_init(jornada680kbd_init);
-module_exit(jornada680kbd_exit);
+module_platform_driver(jornada680kbd_driver);
 
 MODULE_AUTHOR("Kristoffer Ericson <kristoffer.ericson@gmail.com>");
 MODULE_DESCRIPTION("HP Jornada 620/660/680/690 Keyboard Driver");
diff --git a/drivers/input/keyboard/jornada720_kbd.c b/drivers/input/keyboard/jornada720_kbd.c
index 0aa6740..eeafc30 100644
--- a/drivers/input/keyboard/jornada720_kbd.c
+++ b/drivers/input/keyboard/jornada720_kbd.c
@@ -174,16 +174,4 @@ static struct platform_driver jornada720_kbd_driver = {
 	.probe   = jornada720_kbd_probe,
 	.remove  = __devexit_p(jornada720_kbd_remove),
 };
-
-static int __init jornada720_kbd_init(void)
-{
-	return platform_driver_register(&jornada720_kbd_driver);
-}
-
-static void __exit jornada720_kbd_exit(void)
-{
-	platform_driver_unregister(&jornada720_kbd_driver);
-}
-
-module_init(jornada720_kbd_init);
-module_exit(jornada720_kbd_exit);
+module_platform_driver(jornada720_kbd_driver);
diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboard/matrix_keypad.c
index e2ae657..9b223d7 100644
--- a/drivers/input/keyboard/matrix_keypad.c
+++ b/drivers/input/keyboard/matrix_keypad.c
@@ -496,19 +496,7 @@ static struct platform_driver matrix_keypad_driver = {
 #endif
 	},
 };
-
-static int __init matrix_keypad_init(void)
-{
-	return platform_driver_register(&matrix_keypad_driver);
-}
-
-static void __exit matrix_keypad_exit(void)
-{
-	platform_driver_unregister(&matrix_keypad_driver);
-}
-
-module_init(matrix_keypad_init);
-module_exit(matrix_keypad_exit);
+module_platform_driver(matrix_keypad_driver);
 
 MODULE_AUTHOR("Marek Vasut <marek.vasut@gmail.com>");
 MODULE_DESCRIPTION("GPIO Driven Matrix Keypad Driver");
diff --git a/drivers/input/keyboard/nomadik-ske-keypad.c b/drivers/input/keyboard/nomadik-ske-keypad.c
index fcdec5e..6c4828f 100644
--- a/drivers/input/keyboard/nomadik-ske-keypad.c
+++ b/drivers/input/keyboard/nomadik-ske-keypad.c
@@ -390,18 +390,7 @@ struct platform_driver ske_keypad_driver = {
 	.probe = ske_keypad_probe,
 	.remove = __devexit_p(ske_keypad_remove),
 };
-
-static int __init ske_keypad_init(void)
-{
-	return platform_driver_probe(&ske_keypad_driver, ske_keypad_probe);
-}
-module_init(ske_keypad_init);
-
-static void __exit ske_keypad_exit(void)
-{
-	platform_driver_unregister(&ske_keypad_driver);
-}
-module_exit(ske_keypad_exit);
+module_platform_driver(ske_keypad_driver);
 
 MODULE_LICENSE("GPL v2");
 MODULE_AUTHOR("Naveen Kumar <naveen.gaddipati@stericsson.com> / Sundar Iyer <sundar.iyer@stericsson.com>");
diff --git a/drivers/input/keyboard/omap-keypad.c b/drivers/input/keyboard/omap-keypad.c
index 323bcdf..6b630d9 100644
--- a/drivers/input/keyboard/omap-keypad.c
+++ b/drivers/input/keyboard/omap-keypad.c
@@ -473,20 +473,7 @@ static struct platform_driver omap_kp_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init omap_kp_init(void)
-{
-	printk(KERN_INFO "OMAP Keypad Driver\n");
-	return platform_driver_register(&omap_kp_driver);
-}
-
-static void __exit omap_kp_exit(void)
-{
-	platform_driver_unregister(&omap_kp_driver);
-}
-
-module_init(omap_kp_init);
-module_exit(omap_kp_exit);
+module_platform_driver(omap_kp_driver);
 
 MODULE_AUTHOR("Timo Teräs");
 MODULE_DESCRIPTION("OMAP Keypad Driver");
diff --git a/drivers/input/keyboard/omap4-keypad.c b/drivers/input/keyboard/omap4-keypad.c
index c51a3c4..d5c5d77 100644
--- a/drivers/input/keyboard/omap4-keypad.c
+++ b/drivers/input/keyboard/omap4-keypad.c
@@ -335,18 +335,7 @@ static struct platform_driver omap4_keypad_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init omap4_keypad_init(void)
-{
-	return platform_driver_register(&omap4_keypad_driver);
-}
-module_init(omap4_keypad_init);
-
-static void __exit omap4_keypad_exit(void)
-{
-	platform_driver_unregister(&omap4_keypad_driver);
-}
-module_exit(omap4_keypad_exit);
+module_platform_driver(omap4_keypad_driver);
 
 MODULE_AUTHOR("Texas Instruments");
 MODULE_DESCRIPTION("OMAP4 Keypad Driver");
diff --git a/drivers/input/keyboard/opencores-kbd.c b/drivers/input/keyboard/opencores-kbd.c
index 1f1a556..abe728c 100644
--- a/drivers/input/keyboard/opencores-kbd.c
+++ b/drivers/input/keyboard/opencores-kbd.c
@@ -163,18 +163,7 @@ static struct platform_driver opencores_kbd_device_driver = {
 		.name = "opencores-kbd",
 	},
 };
-
-static int __init opencores_kbd_init(void)
-{
-	return platform_driver_register(&opencores_kbd_device_driver);
-}
-module_init(opencores_kbd_init);
-
-static void __exit opencores_kbd_exit(void)
-{
-	platform_driver_unregister(&opencores_kbd_device_driver);
-}
-module_exit(opencores_kbd_exit);
+module_platform_driver(opencores_kbd_device_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Javier Herrero <jherrero@hvsistemas.es>");
diff --git a/drivers/input/keyboard/pmic8xxx-keypad.c b/drivers/input/keyboard/pmic8xxx-keypad.c
index e7cc51d..01a1c9f 100644
--- a/drivers/input/keyboard/pmic8xxx-keypad.c
+++ b/drivers/input/keyboard/pmic8xxx-keypad.c
@@ -780,18 +780,7 @@ static struct platform_driver pmic8xxx_kp_driver = {
 		.pm = &pm8xxx_kp_pm_ops,
 	},
 };
-
-static int __init pmic8xxx_kp_init(void)
-{
-	return platform_driver_register(&pmic8xxx_kp_driver);
-}
-module_init(pmic8xxx_kp_init);
-
-static void __exit pmic8xxx_kp_exit(void)
-{
-	platform_driver_unregister(&pmic8xxx_kp_driver);
-}
-module_exit(pmic8xxx_kp_exit);
+module_platform_driver(pmic8xxx_kp_driver);
 
 MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("PMIC8XXX keypad driver");
diff --git a/drivers/input/keyboard/pxa27x_keypad.c b/drivers/input/keyboard/pxa27x_keypad.c
index eca6ae6..29fe1b2 100644
--- a/drivers/input/keyboard/pxa27x_keypad.c
+++ b/drivers/input/keyboard/pxa27x_keypad.c
@@ -602,19 +602,7 @@ static struct platform_driver pxa27x_keypad_driver = {
 #endif
 	},
 };
-
-static int __init pxa27x_keypad_init(void)
-{
-	return platform_driver_register(&pxa27x_keypad_driver);
-}
-
-static void __exit pxa27x_keypad_exit(void)
-{
-	platform_driver_unregister(&pxa27x_keypad_driver);
-}
-
-module_init(pxa27x_keypad_init);
-module_exit(pxa27x_keypad_exit);
+module_platform_driver(pxa27x_keypad_driver);
 
 MODULE_DESCRIPTION("PXA27x Keypad Controller Driver");
 MODULE_LICENSE("GPL");
diff --git a/drivers/input/keyboard/pxa930_rotary.c b/drivers/input/keyboard/pxa930_rotary.c
index 35451bf..d7f1134 100644
--- a/drivers/input/keyboard/pxa930_rotary.c
+++ b/drivers/input/keyboard/pxa930_rotary.c
@@ -195,18 +195,7 @@ static struct platform_driver pxa930_rotary_driver = {
 	.probe		= pxa930_rotary_probe,
 	.remove		= __devexit_p(pxa930_rotary_remove),
 };
-
-static int __init pxa930_rotary_init(void)
-{
-	return platform_driver_register(&pxa930_rotary_driver);
-}
-module_init(pxa930_rotary_init);
-
-static void __exit pxa930_rotary_exit(void)
-{
-	platform_driver_unregister(&pxa930_rotary_driver);
-}
-module_exit(pxa930_rotary_exit);
+module_platform_driver(pxa930_rotary_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Driver for PXA93x Enhanced Rotary Controller");
diff --git a/drivers/input/keyboard/samsung-keypad.c b/drivers/input/keyboard/samsung-keypad.c
index f689f49..baab81d 100644
--- a/drivers/input/keyboard/samsung-keypad.c
+++ b/drivers/input/keyboard/samsung-keypad.c
@@ -471,18 +471,7 @@ static struct platform_driver samsung_keypad_driver = {
 	},
 	.id_table	= samsung_keypad_driver_ids,
 };
-
-static int __init samsung_keypad_init(void)
-{
-	return platform_driver_register(&samsung_keypad_driver);
-}
-module_init(samsung_keypad_init);
-
-static void __exit samsung_keypad_exit(void)
-{
-	platform_driver_unregister(&samsung_keypad_driver);
-}
-module_exit(samsung_keypad_exit);
+module_platform_driver(samsung_keypad_driver);
 
 MODULE_DESCRIPTION("Samsung keypad driver");
 MODULE_AUTHOR("Joonyoung Shim <jy0922.shim@samsung.com>");
diff --git a/drivers/input/keyboard/sh_keysc.c b/drivers/input/keyboard/sh_keysc.c
index 934aeb583..da54ad5 100644
--- a/drivers/input/keyboard/sh_keysc.c
+++ b/drivers/input/keyboard/sh_keysc.c
@@ -337,19 +337,7 @@ static struct platform_driver sh_keysc_device_driver = {
 		.pm	= &sh_keysc_dev_pm_ops,
 	}
 };
-
-static int __init sh_keysc_init(void)
-{
-	return platform_driver_register(&sh_keysc_device_driver);
-}
-
-static void __exit sh_keysc_exit(void)
-{
-	platform_driver_unregister(&sh_keysc_device_driver);
-}
-
-module_init(sh_keysc_init);
-module_exit(sh_keysc_exit);
+module_platform_driver(sh_keysc_device_driver);
 
 MODULE_AUTHOR("Magnus Damm");
 MODULE_DESCRIPTION("SuperH KEYSC Keypad Driver");
diff --git a/drivers/input/keyboard/spear-keyboard.c b/drivers/input/keyboard/spear-keyboard.c
index d712dff..c88bd63 100644
--- a/drivers/input/keyboard/spear-keyboard.c
+++ b/drivers/input/keyboard/spear-keyboard.c
@@ -326,18 +326,7 @@ static struct platform_driver spear_kbd_driver = {
 #endif
 	},
 };
-
-static int __init spear_kbd_init(void)
-{
-	return platform_driver_register(&spear_kbd_driver);
-}
-module_init(spear_kbd_init);
-
-static void __exit spear_kbd_exit(void)
-{
-	platform_driver_unregister(&spear_kbd_driver);
-}
-module_exit(spear_kbd_exit);
+module_platform_driver(spear_kbd_driver);
 
 MODULE_AUTHOR("Rajeev Kumar");
 MODULE_DESCRIPTION("SPEAr Keyboard Driver");
diff --git a/drivers/input/keyboard/stmpe-keypad.c b/drivers/input/keyboard/stmpe-keypad.c
index ab7610c..9397cf9 100644
--- a/drivers/input/keyboard/stmpe-keypad.c
+++ b/drivers/input/keyboard/stmpe-keypad.c
@@ -368,18 +368,7 @@ static struct platform_driver stmpe_keypad_driver = {
 	.probe		= stmpe_keypad_probe,
 	.remove		= __devexit_p(stmpe_keypad_remove),
 };
-
-static int __init stmpe_keypad_init(void)
-{
-	return platform_driver_register(&stmpe_keypad_driver);
-}
-module_init(stmpe_keypad_init);
-
-static void __exit stmpe_keypad_exit(void)
-{
-	platform_driver_unregister(&stmpe_keypad_driver);
-}
-module_exit(stmpe_keypad_exit);
+module_platform_driver(stmpe_keypad_driver);
 
 MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("STMPExxxx keypad driver");
diff --git a/drivers/input/keyboard/tc3589x-keypad.c b/drivers/input/keyboard/tc3589x-keypad.c
index f60c9e8..ce916fa 100644
--- a/drivers/input/keyboard/tc3589x-keypad.c
+++ b/drivers/input/keyboard/tc3589x-keypad.c
@@ -453,18 +453,7 @@ static struct platform_driver tc3589x_keypad_driver = {
 	.probe	= tc3589x_keypad_probe,
 	.remove	= __devexit_p(tc3589x_keypad_remove),
 };
-
-static int __init tc3589x_keypad_init(void)
-{
-	return platform_driver_register(&tc3589x_keypad_driver);
-}
-module_init(tc3589x_keypad_init);
-
-static void __exit tc3589x_keypad_exit(void)
-{
-	return platform_driver_unregister(&tc3589x_keypad_driver);
-}
-module_exit(tc3589x_keypad_exit);
+module_platform_driver(tc3589x_keypad_driver);
 
 MODULE_LICENSE("GPL v2");
 MODULE_AUTHOR("Jayeeta Banerjee/Sundar Iyer");
diff --git a/drivers/input/keyboard/tegra-kbc.c b/drivers/input/keyboard/tegra-kbc.c
index cf3228b..08d02f2 100644
--- a/drivers/input/keyboard/tegra-kbc.c
+++ b/drivers/input/keyboard/tegra-kbc.c
@@ -802,18 +802,7 @@ static struct platform_driver tegra_kbc_driver = {
 		.pm	= &tegra_kbc_pm_ops,
 	},
 };
-
-static void __exit tegra_kbc_exit(void)
-{
-	platform_driver_unregister(&tegra_kbc_driver);
-}
-module_exit(tegra_kbc_exit);
-
-static int __init tegra_kbc_init(void)
-{
-	return platform_driver_register(&tegra_kbc_driver);
-}
-module_init(tegra_kbc_init);
+module_platform_driver(tegra_kbc_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Rakesh Iyer <riyer@nvidia.com>");
diff --git a/drivers/input/keyboard/tnetv107x-keypad.c b/drivers/input/keyboard/tnetv107x-keypad.c
index 66e55e5..fb39c94 100644
--- a/drivers/input/keyboard/tnetv107x-keypad.c
+++ b/drivers/input/keyboard/tnetv107x-keypad.c
@@ -322,19 +322,7 @@ static struct platform_driver keypad_driver = {
 	.driver.name	= "tnetv107x-keypad",
 	.driver.owner	= THIS_MODULE,
 };
-
-static int __init keypad_init(void)
-{
-	return platform_driver_register(&keypad_driver);
-}
-
-static void __exit keypad_exit(void)
-{
-	platform_driver_unregister(&keypad_driver);
-}
-
-module_init(keypad_init);
-module_exit(keypad_exit);
+module_platform_driver(keypad_driver);
 
 MODULE_AUTHOR("Cyril Chemparathy");
 MODULE_DESCRIPTION("TNETV107X Keypad Driver");
diff --git a/drivers/input/keyboard/twl4030_keypad.c b/drivers/input/keyboard/twl4030_keypad.c
index a26922c..a588578 100644
--- a/drivers/input/keyboard/twl4030_keypad.c
+++ b/drivers/input/keyboard/twl4030_keypad.c
@@ -460,18 +460,7 @@ static struct platform_driver twl4030_kp_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init twl4030_kp_init(void)
-{
-	return platform_driver_register(&twl4030_kp_driver);
-}
-module_init(twl4030_kp_init);
-
-static void __exit twl4030_kp_exit(void)
-{
-	platform_driver_unregister(&twl4030_kp_driver);
-}
-module_exit(twl4030_kp_exit);
+module_platform_driver(twl4030_kp_driver);
 
 MODULE_AUTHOR("Texas Instruments");
 MODULE_DESCRIPTION("TWL4030 Keypad Driver");
diff --git a/drivers/input/keyboard/w90p910_keypad.c b/drivers/input/keyboard/w90p910_keypad.c
index 318586d..99bbb7e 100644
--- a/drivers/input/keyboard/w90p910_keypad.c
+++ b/drivers/input/keyboard/w90p910_keypad.c
@@ -262,19 +262,7 @@ static struct platform_driver w90p910_keypad_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init w90p910_keypad_init(void)
-{
-	return platform_driver_register(&w90p910_keypad_driver);
-}
-
-static void __exit w90p910_keypad_exit(void)
-{
-	platform_driver_unregister(&w90p910_keypad_driver);
-}
-
-module_init(w90p910_keypad_init);
-module_exit(w90p910_keypad_exit);
+module_platform_driver(w90p910_keypad_driver);
 
 MODULE_AUTHOR("Wan ZongShun <mcuos.com@gmail.com>");
 MODULE_DESCRIPTION("w90p910 keypad driver");
-- 
1.7.8-rc2


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

* [PATCH TRIVIAL 2/5] Input: misc: use macro module_platform_driver()
  2011-11-22  9:00 [PATCH TRIVIAL 0/5] Input: use new macro module_platform_driver to save some boilerplate code JJ Ding
  2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
@ 2011-11-22  9:00 ` JJ Ding
  2011-11-22 14:59   ` Mike Frysinger
  2011-11-22  9:00 ` [PATCH TRIVIAL 3/5] Input: mouse: " JJ Ding
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 15+ messages in thread
From: JJ Ding @ 2011-11-22  9:00 UTC (permalink / raw)
  To: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely
  Cc: linux-kernel, linux-input, JJ Ding, JJ Ding

From: JJ Ding <dgdunix@gmail.com>

Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
save some platform_driver boilerplate code. Use it.

Signed-off-by: JJ Ding <dgdunix@gmail.com>
---
 drivers/input/misc/88pm860x_onkey.c    |   13 +------------
 drivers/input/misc/ab8500-ponkey.c     |   13 +------------
 drivers/input/misc/bfin_rotary.c       |   13 +------------
 drivers/input/misc/cobalt_btns.c       |   14 +-------------
 drivers/input/misc/dm355evm_keys.c     |   13 +------------
 drivers/input/misc/ixp4xx-beeper.c     |   13 +------------
 drivers/input/misc/max8925_onkey.c     |   13 +------------
 drivers/input/misc/pcap_keys.c         |   14 +-------------
 drivers/input/misc/pcf50633-input.c    |   13 +------------
 drivers/input/misc/pcspkr.c            |   14 +-------------
 drivers/input/misc/pm8xxx-vibrator.c   |   13 +------------
 drivers/input/misc/pmic8xxx-pwrkey.c   |   13 +------------
 drivers/input/misc/pwm-beeper.c        |   13 +------------
 drivers/input/misc/rb532_button.c      |   14 +-------------
 drivers/input/misc/rotary_encoder.c    |   14 +-------------
 drivers/input/misc/sgi_btns.c          |   13 +------------
 drivers/input/misc/twl4030-pwrbutton.c |   15 ++-------------
 drivers/input/misc/twl4030-vibra.c     |   14 +-------------
 drivers/input/misc/twl6040-vibra.c     |   13 +------------
 drivers/input/misc/wm831x-on.c         |   13 +------------
 20 files changed, 21 insertions(+), 247 deletions(-)

diff --git a/drivers/input/misc/88pm860x_onkey.c b/drivers/input/misc/88pm860x_onkey.c
index 3dca3c1..f2e0cbc 100644
--- a/drivers/input/misc/88pm860x_onkey.c
+++ b/drivers/input/misc/88pm860x_onkey.c
@@ -137,18 +137,7 @@ static struct platform_driver pm860x_onkey_driver = {
 	.probe		= pm860x_onkey_probe,
 	.remove		= __devexit_p(pm860x_onkey_remove),
 };
-
-static int __init pm860x_onkey_init(void)
-{
-	return platform_driver_register(&pm860x_onkey_driver);
-}
-module_init(pm860x_onkey_init);
-
-static void __exit pm860x_onkey_exit(void)
-{
-	platform_driver_unregister(&pm860x_onkey_driver);
-}
-module_exit(pm860x_onkey_exit);
+module_platform_driver(pm860x_onkey_driver);
 
 MODULE_DESCRIPTION("Marvell 88PM860x ONKEY driver");
 MODULE_AUTHOR("Haojian Zhuang <haojian.zhuang@marvell.com>");
diff --git a/drivers/input/misc/ab8500-ponkey.c b/drivers/input/misc/ab8500-ponkey.c
index 3d3288a..79d9016 100644
--- a/drivers/input/misc/ab8500-ponkey.c
+++ b/drivers/input/misc/ab8500-ponkey.c
@@ -139,18 +139,7 @@ static struct platform_driver ab8500_ponkey_driver = {
 	.probe		= ab8500_ponkey_probe,
 	.remove		= __devexit_p(ab8500_ponkey_remove),
 };
-
-static int __init ab8500_ponkey_init(void)
-{
-	return platform_driver_register(&ab8500_ponkey_driver);
-}
-module_init(ab8500_ponkey_init);
-
-static void __exit ab8500_ponkey_exit(void)
-{
-	platform_driver_unregister(&ab8500_ponkey_driver);
-}
-module_exit(ab8500_ponkey_exit);
+module_platform_driver(ab8500_ponkey_driver);
 
 MODULE_LICENSE("GPL v2");
 MODULE_AUTHOR("Sundar Iyer <sundar.iyer@stericsson.com>");
diff --git a/drivers/input/misc/bfin_rotary.c b/drivers/input/misc/bfin_rotary.c
index d00edc9..1c4146f 100644
--- a/drivers/input/misc/bfin_rotary.c
+++ b/drivers/input/misc/bfin_rotary.c
@@ -264,18 +264,7 @@ static struct platform_driver bfin_rotary_device_driver = {
 #endif
 	},
 };
-
-static int __init bfin_rotary_init(void)
-{
-	return platform_driver_register(&bfin_rotary_device_driver);
-}
-module_init(bfin_rotary_init);
-
-static void __exit bfin_rotary_exit(void)
-{
-	platform_driver_unregister(&bfin_rotary_device_driver);
-}
-module_exit(bfin_rotary_exit);
+module_platform_driver(bfin_rotary_device_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Michael Hennerich <hennerich@blackfin.uclinux.org>");
diff --git a/drivers/input/misc/cobalt_btns.c b/drivers/input/misc/cobalt_btns.c
index fd8407a..53e43d2 100644
--- a/drivers/input/misc/cobalt_btns.c
+++ b/drivers/input/misc/cobalt_btns.c
@@ -163,16 +163,4 @@ static struct platform_driver cobalt_buttons_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init cobalt_buttons_init(void)
-{
-	return platform_driver_register(&cobalt_buttons_driver);
-}
-
-static void __exit cobalt_buttons_exit(void)
-{
-	platform_driver_unregister(&cobalt_buttons_driver);
-}
-
-module_init(cobalt_buttons_init);
-module_exit(cobalt_buttons_exit);
+module_platform_driver(cobalt_buttons_driver);
diff --git a/drivers/input/misc/dm355evm_keys.c b/drivers/input/misc/dm355evm_keys.c
index 7283dd2..35083c6 100644
--- a/drivers/input/misc/dm355evm_keys.c
+++ b/drivers/input/misc/dm355evm_keys.c
@@ -267,17 +267,6 @@ static struct platform_driver dm355evm_keys_driver = {
 		.name	= "dm355evm_keys",
 	},
 };
-
-static int __init dm355evm_keys_init(void)
-{
-	return platform_driver_register(&dm355evm_keys_driver);
-}
-module_init(dm355evm_keys_init);
-
-static void __exit dm355evm_keys_exit(void)
-{
-	platform_driver_unregister(&dm355evm_keys_driver);
-}
-module_exit(dm355evm_keys_exit);
+module_platform_driver(dm355evm_keys_driver);
 
 MODULE_LICENSE("GPL");
diff --git a/drivers/input/misc/ixp4xx-beeper.c b/drivers/input/misc/ixp4xx-beeper.c
index 302ab46..50e2830 100644
--- a/drivers/input/misc/ixp4xx-beeper.c
+++ b/drivers/input/misc/ixp4xx-beeper.c
@@ -168,16 +168,5 @@ static struct platform_driver ixp4xx_spkr_platform_driver = {
 	.remove		= __devexit_p(ixp4xx_spkr_remove),
 	.shutdown	= ixp4xx_spkr_shutdown,
 };
+module_platform_driver(ixp4xx_spkr_platform_driver);
 
-static int __init ixp4xx_spkr_init(void)
-{
-	return platform_driver_register(&ixp4xx_spkr_platform_driver);
-}
-
-static void __exit ixp4xx_spkr_exit(void)
-{
-	platform_driver_unregister(&ixp4xx_spkr_platform_driver);
-}
-
-module_init(ixp4xx_spkr_init);
-module_exit(ixp4xx_spkr_exit);
diff --git a/drivers/input/misc/max8925_onkey.c b/drivers/input/misc/max8925_onkey.c
index 7de0ded..23cf082 100644
--- a/drivers/input/misc/max8925_onkey.c
+++ b/drivers/input/misc/max8925_onkey.c
@@ -166,18 +166,7 @@ static struct platform_driver max8925_onkey_driver = {
 	.probe		= max8925_onkey_probe,
 	.remove		= __devexit_p(max8925_onkey_remove),
 };
-
-static int __init max8925_onkey_init(void)
-{
-	return platform_driver_register(&max8925_onkey_driver);
-}
-module_init(max8925_onkey_init);
-
-static void __exit max8925_onkey_exit(void)
-{
-	platform_driver_unregister(&max8925_onkey_driver);
-}
-module_exit(max8925_onkey_exit);
+module_platform_driver(max8925_onkey_driver);
 
 MODULE_DESCRIPTION("Maxim MAX8925 ONKEY driver");
 MODULE_AUTHOR("Haojian Zhuang <haojian.zhuang@marvell.com>");
diff --git a/drivers/input/misc/pcap_keys.c b/drivers/input/misc/pcap_keys.c
index 99335c2..e09b4fe 100644
--- a/drivers/input/misc/pcap_keys.c
+++ b/drivers/input/misc/pcap_keys.c
@@ -125,19 +125,7 @@ static struct platform_driver pcap_keys_device_driver = {
 		.owner	= THIS_MODULE,
 	}
 };
-
-static int __init pcap_keys_init(void)
-{
-	return platform_driver_register(&pcap_keys_device_driver);
-};
-
-static void __exit pcap_keys_exit(void)
-{
-	platform_driver_unregister(&pcap_keys_device_driver);
-};
-
-module_init(pcap_keys_init);
-module_exit(pcap_keys_exit);
+module_platform_driver(pcap_keys_device_driver);
 
 MODULE_DESCRIPTION("Motorola PCAP2 input events driver");
 MODULE_AUTHOR("Ilya Petrov <ilya.muromec@gmail.com>");
diff --git a/drivers/input/misc/pcf50633-input.c b/drivers/input/misc/pcf50633-input.c
index 9556273..53891de 100644
--- a/drivers/input/misc/pcf50633-input.c
+++ b/drivers/input/misc/pcf50633-input.c
@@ -113,18 +113,7 @@ static struct platform_driver pcf50633_input_driver = {
 	.probe = pcf50633_input_probe,
 	.remove = __devexit_p(pcf50633_input_remove),
 };
-
-static int __init pcf50633_input_init(void)
-{
-	return platform_driver_register(&pcf50633_input_driver);
-}
-module_init(pcf50633_input_init);
-
-static void __exit pcf50633_input_exit(void)
-{
-	platform_driver_unregister(&pcf50633_input_driver);
-}
-module_exit(pcf50633_input_exit);
+module_platform_driver(pcf50633_input_driver);
 
 MODULE_AUTHOR("Balaji Rao <balajirrao@openmoko.org>");
 MODULE_DESCRIPTION("PCF50633 input driver");
diff --git a/drivers/input/misc/pcspkr.c b/drivers/input/misc/pcspkr.c
index 34f4d2e..b2484aa 100644
--- a/drivers/input/misc/pcspkr.c
+++ b/drivers/input/misc/pcspkr.c
@@ -134,17 +134,5 @@ static struct platform_driver pcspkr_platform_driver = {
 	.remove		= __devexit_p(pcspkr_remove),
 	.shutdown	= pcspkr_shutdown,
 };
+module_platform_driver(pcspkr_platform_driver);
 
-
-static int __init pcspkr_init(void)
-{
-	return platform_driver_register(&pcspkr_platform_driver);
-}
-
-static void __exit pcspkr_exit(void)
-{
-	platform_driver_unregister(&pcspkr_platform_driver);
-}
-
-module_init(pcspkr_init);
-module_exit(pcspkr_exit);
diff --git a/drivers/input/misc/pm8xxx-vibrator.c b/drivers/input/misc/pm8xxx-vibrator.c
index 4319293..dfbfb46 100644
--- a/drivers/input/misc/pm8xxx-vibrator.c
+++ b/drivers/input/misc/pm8xxx-vibrator.c
@@ -277,18 +277,7 @@ static struct platform_driver pm8xxx_vib_driver = {
 		.pm	= &pm8xxx_vib_pm_ops,
 	},
 };
-
-static int __init pm8xxx_vib_init(void)
-{
-	return platform_driver_register(&pm8xxx_vib_driver);
-}
-module_init(pm8xxx_vib_init);
-
-static void __exit pm8xxx_vib_exit(void)
-{
-	platform_driver_unregister(&pm8xxx_vib_driver);
-}
-module_exit(pm8xxx_vib_exit);
+module_platform_driver(pm8xxx_vib_driver);
 
 MODULE_ALIAS("platform:pm8xxx_vib");
 MODULE_DESCRIPTION("PMIC8xxx vibrator driver based on ff-memless framework");
diff --git a/drivers/input/misc/pmic8xxx-pwrkey.c b/drivers/input/misc/pmic8xxx-pwrkey.c
index b3cfb9c..0f83d0f 100644
--- a/drivers/input/misc/pmic8xxx-pwrkey.c
+++ b/drivers/input/misc/pmic8xxx-pwrkey.c
@@ -213,18 +213,7 @@ static struct platform_driver pmic8xxx_pwrkey_driver = {
 		.pm	= &pm8xxx_pwr_key_pm_ops,
 	},
 };
-
-static int __init pmic8xxx_pwrkey_init(void)
-{
-	return platform_driver_register(&pmic8xxx_pwrkey_driver);
-}
-module_init(pmic8xxx_pwrkey_init);
-
-static void __exit pmic8xxx_pwrkey_exit(void)
-{
-	platform_driver_unregister(&pmic8xxx_pwrkey_driver);
-}
-module_exit(pmic8xxx_pwrkey_exit);
+module_platform_driver(pmic8xxx_pwrkey_driver);
 
 MODULE_ALIAS("platform:pmic8xxx_pwrkey");
 MODULE_DESCRIPTION("PMIC8XXX Power Key driver");
diff --git a/drivers/input/misc/pwm-beeper.c b/drivers/input/misc/pwm-beeper.c
index 57c294f..fc84c8a 100644
--- a/drivers/input/misc/pwm-beeper.c
+++ b/drivers/input/misc/pwm-beeper.c
@@ -180,18 +180,7 @@ static struct platform_driver pwm_beeper_driver = {
 		.pm	= PWM_BEEPER_PM_OPS,
 	},
 };
-
-static int __init pwm_beeper_init(void)
-{
-	return platform_driver_register(&pwm_beeper_driver);
-}
-module_init(pwm_beeper_init);
-
-static void __exit pwm_beeper_exit(void)
-{
-	platform_driver_unregister(&pwm_beeper_driver);
-}
-module_exit(pwm_beeper_exit);
+module_platform_driver(pwm_beeper_driver);
 
 MODULE_AUTHOR("Lars-Peter Clausen <lars@metafoo.de>");
 MODULE_DESCRIPTION("PWM beeper driver");
diff --git a/drivers/input/misc/rb532_button.c b/drivers/input/misc/rb532_button.c
index e2c7f62..aeb02bc 100644
--- a/drivers/input/misc/rb532_button.c
+++ b/drivers/input/misc/rb532_button.c
@@ -100,19 +100,7 @@ static struct platform_driver rb532_button_driver = {
 		.owner = THIS_MODULE,
 	},
 };
-
-static int __init rb532_button_init(void)
-{
-	return platform_driver_register(&rb532_button_driver);
-}
-
-static void __exit rb532_button_exit(void)
-{
-	platform_driver_unregister(&rb532_button_driver);
-}
-
-module_init(rb532_button_init);
-module_exit(rb532_button_exit);
+module_platform_driver(rb532_button_driver);
 
 MODULE_AUTHOR("Phil Sutter <n0-1@freewrt.org>");
 MODULE_LICENSE("GPL");
diff --git a/drivers/input/misc/rotary_encoder.c b/drivers/input/misc/rotary_encoder.c
index 2be2169..f07f784 100644
--- a/drivers/input/misc/rotary_encoder.c
+++ b/drivers/input/misc/rotary_encoder.c
@@ -284,19 +284,7 @@ static struct platform_driver rotary_encoder_driver = {
 		.owner	= THIS_MODULE,
 	}
 };
-
-static int __init rotary_encoder_init(void)
-{
-	return platform_driver_register(&rotary_encoder_driver);
-}
-
-static void __exit rotary_encoder_exit(void)
-{
-	platform_driver_unregister(&rotary_encoder_driver);
-}
-
-module_init(rotary_encoder_init);
-module_exit(rotary_encoder_exit);
+module_platform_driver(rotary_encoder_driver);
 
 MODULE_ALIAS("platform:" DRV_NAME);
 MODULE_DESCRIPTION("GPIO rotary encoder driver");
diff --git a/drivers/input/misc/sgi_btns.c b/drivers/input/misc/sgi_btns.c
index 1a80c0d..5d9fd55 100644
--- a/drivers/input/misc/sgi_btns.c
+++ b/drivers/input/misc/sgi_btns.c
@@ -164,17 +164,6 @@ static struct platform_driver sgi_buttons_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init sgi_buttons_init(void)
-{
-	return platform_driver_register(&sgi_buttons_driver);
-}
-
-static void __exit sgi_buttons_exit(void)
-{
-	platform_driver_unregister(&sgi_buttons_driver);
-}
+module_platform_driver(sgi_buttons_driver);
 
 MODULE_LICENSE("GPL");
-module_init(sgi_buttons_init);
-module_exit(sgi_buttons_exit);
diff --git a/drivers/input/misc/twl4030-pwrbutton.c b/drivers/input/misc/twl4030-pwrbutton.c
index 38e4b50..19a6882 100644
--- a/drivers/input/misc/twl4030-pwrbutton.c
+++ b/drivers/input/misc/twl4030-pwrbutton.c
@@ -107,25 +107,14 @@ static int __exit twl4030_pwrbutton_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver twl4030_pwrbutton_driver = {
+	.probe		= twl4030_pwrbutton_probe,
 	.remove		= __exit_p(twl4030_pwrbutton_remove),
 	.driver		= {
 		.name	= "twl4030_pwrbutton",
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init twl4030_pwrbutton_init(void)
-{
-	return platform_driver_probe(&twl4030_pwrbutton_driver,
-			twl4030_pwrbutton_probe);
-}
-module_init(twl4030_pwrbutton_init);
-
-static void __exit twl4030_pwrbutton_exit(void)
-{
-	platform_driver_unregister(&twl4030_pwrbutton_driver);
-}
-module_exit(twl4030_pwrbutton_exit);
+module_platform_driver(twl4030_pwrbutton_driver);
 
 MODULE_ALIAS("platform:twl4030_pwrbutton");
 MODULE_DESCRIPTION("Triton2 Power Button");
diff --git a/drivers/input/misc/twl4030-vibra.c b/drivers/input/misc/twl4030-vibra.c
index 3c1a432..3765137 100644
--- a/drivers/input/misc/twl4030-vibra.c
+++ b/drivers/input/misc/twl4030-vibra.c
@@ -278,21 +278,9 @@ static struct platform_driver twl4030_vibra_driver = {
 #endif
 	},
 };
-
-static int __init twl4030_vibra_init(void)
-{
-	return platform_driver_register(&twl4030_vibra_driver);
-}
-module_init(twl4030_vibra_init);
-
-static void __exit twl4030_vibra_exit(void)
-{
-	platform_driver_unregister(&twl4030_vibra_driver);
-}
-module_exit(twl4030_vibra_exit);
+module_platform_driver(twl4030_vibra_driver);
 
 MODULE_ALIAS("platform:twl4030-vibra");
-
 MODULE_DESCRIPTION("TWL4030 Vibra driver");
 MODULE_LICENSE("GPL");
 MODULE_AUTHOR("Nokia Corporation");
diff --git a/drivers/input/misc/twl6040-vibra.c b/drivers/input/misc/twl6040-vibra.c
index ad153a4..45874fe 100644
--- a/drivers/input/misc/twl6040-vibra.c
+++ b/drivers/input/misc/twl6040-vibra.c
@@ -410,18 +410,7 @@ static struct platform_driver twl6040_vibra_driver = {
 		.pm	= &twl6040_vibra_pm_ops,
 	},
 };
-
-static int __init twl6040_vibra_init(void)
-{
-	return platform_driver_register(&twl6040_vibra_driver);
-}
-module_init(twl6040_vibra_init);
-
-static void __exit twl6040_vibra_exit(void)
-{
-	platform_driver_unregister(&twl6040_vibra_driver);
-}
-module_exit(twl6040_vibra_exit);
+module_platform_driver(twl6040_vibra_driver);
 
 MODULE_ALIAS("platform:twl6040-vibra");
 MODULE_DESCRIPTION("TWL6040 Vibra driver");
diff --git a/drivers/input/misc/wm831x-on.c b/drivers/input/misc/wm831x-on.c
index c3d7ba5..47f18d6 100644
--- a/drivers/input/misc/wm831x-on.c
+++ b/drivers/input/misc/wm831x-on.c
@@ -145,18 +145,7 @@ static struct platform_driver wm831x_on_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init wm831x_on_init(void)
-{
-	return platform_driver_register(&wm831x_on_driver);
-}
-module_init(wm831x_on_init);
-
-static void __exit wm831x_on_exit(void)
-{
-	platform_driver_unregister(&wm831x_on_driver);
-}
-module_exit(wm831x_on_exit);
+module_platform_driver(wm831x_on_driver);
 
 MODULE_ALIAS("platform:wm831x-on");
 MODULE_DESCRIPTION("WM831x ON pin");
-- 
1.7.8-rc2


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

* [PATCH TRIVIAL 3/5] Input: mouse: use macro module_platform_driver()
  2011-11-22  9:00 [PATCH TRIVIAL 0/5] Input: use new macro module_platform_driver to save some boilerplate code JJ Ding
  2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
  2011-11-22  9:00 ` [PATCH TRIVIAL 2/5] Input: misc: " JJ Ding
@ 2011-11-22  9:00 ` JJ Ding
  2011-11-22  9:00 ` [PATCH TRIVIAL 4/5] Input: serio: " JJ Ding
  2011-11-22  9:00 ` [PATCH TRIVIAL 5/5] Input: touchscreen: " JJ Ding
  4 siblings, 0 replies; 15+ messages in thread
From: JJ Ding @ 2011-11-22  9:00 UTC (permalink / raw)
  To: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely
  Cc: linux-kernel, linux-input, JJ Ding, JJ Ding

From: JJ Ding <dgdunix@gmail.com>

Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
save some platform_driver boilerplate code. Use it.

Signed-off-by: JJ Ding <dgdunix@gmail.com>
---
 drivers/input/mouse/amimouse.c       |   16 ++--------------
 drivers/input/mouse/gpio_mouse.c     |   13 +------------
 drivers/input/mouse/pxa930_trkball.c |   14 +-------------
 3 files changed, 4 insertions(+), 39 deletions(-)

diff --git a/drivers/input/mouse/amimouse.c b/drivers/input/mouse/amimouse.c
index ff5f61a..39be7b8 100644
--- a/drivers/input/mouse/amimouse.c
+++ b/drivers/input/mouse/amimouse.c
@@ -140,25 +140,13 @@ static int __exit amimouse_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver amimouse_driver = {
+	.probe = amimouse_probe,
 	.remove = __exit_p(amimouse_remove),
 	.driver   = {
 		.name	= "amiga-mouse",
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init amimouse_init(void)
-{
-	return platform_driver_probe(&amimouse_driver, amimouse_probe);
-}
-
-module_init(amimouse_init);
-
-static void __exit amimouse_exit(void)
-{
-	platform_driver_unregister(&amimouse_driver);
-}
-
-module_exit(amimouse_exit);
+module_platform_driver(amimouse_driver);
 
 MODULE_ALIAS("platform:amiga-mouse");
diff --git a/drivers/input/mouse/gpio_mouse.c b/drivers/input/mouse/gpio_mouse.c
index 58902fb..a9ad8e1 100644
--- a/drivers/input/mouse/gpio_mouse.c
+++ b/drivers/input/mouse/gpio_mouse.c
@@ -178,18 +178,7 @@ static struct platform_driver gpio_mouse_device_driver = {
 		.owner	= THIS_MODULE,
 	}
 };
-
-static int __init gpio_mouse_init(void)
-{
-	return platform_driver_register(&gpio_mouse_device_driver);
-}
-module_init(gpio_mouse_init);
-
-static void __exit gpio_mouse_exit(void)
-{
-	platform_driver_unregister(&gpio_mouse_device_driver);
-}
-module_exit(gpio_mouse_exit);
+module_platform_driver(gpio_mouse_device_driver);
 
 MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>");
 MODULE_DESCRIPTION("GPIO mouse driver");
diff --git a/drivers/input/mouse/pxa930_trkball.c b/drivers/input/mouse/pxa930_trkball.c
index ee3b0ca..a9e4bfd 100644
--- a/drivers/input/mouse/pxa930_trkball.c
+++ b/drivers/input/mouse/pxa930_trkball.c
@@ -250,19 +250,7 @@ static struct platform_driver pxa930_trkball_driver = {
 	.probe		= pxa930_trkball_probe,
 	.remove		= __devexit_p(pxa930_trkball_remove),
 };
-
-static int __init pxa930_trkball_init(void)
-{
-	return platform_driver_register(&pxa930_trkball_driver);
-}
-
-static void __exit pxa930_trkball_exit(void)
-{
-	platform_driver_unregister(&pxa930_trkball_driver);
-}
-
-module_init(pxa930_trkball_init);
-module_exit(pxa930_trkball_exit);
+module_platform_driver(pxa930_trkball_driver);
 
 MODULE_AUTHOR("Yong Yao <yaoyong@marvell.com>");
 MODULE_DESCRIPTION("PXA930 Trackball Mouse Driver");
-- 
1.7.8-rc2


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

* [PATCH TRIVIAL 4/5] Input: serio: use macro module_platform_driver()
  2011-11-22  9:00 [PATCH TRIVIAL 0/5] Input: use new macro module_platform_driver to save some boilerplate code JJ Ding
                   ` (2 preceding siblings ...)
  2011-11-22  9:00 ` [PATCH TRIVIAL 3/5] Input: mouse: " JJ Ding
@ 2011-11-22  9:00 ` JJ Ding
  2011-11-22  9:00 ` [PATCH TRIVIAL 5/5] Input: touchscreen: " JJ Ding
  4 siblings, 0 replies; 15+ messages in thread
From: JJ Ding @ 2011-11-22  9:00 UTC (permalink / raw)
  To: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely
  Cc: linux-kernel, linux-input, JJ Ding, JJ Ding

From: JJ Ding <dgdunix@gmail.com>

Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
save some platform_driver boilerplate code. Use it.

Signed-off-by: JJ Ding <dgdunix@gmail.com>
---
 drivers/input/serio/altera_ps2.c |   13 +------------
 drivers/input/serio/at32psif.c   |   14 +-------------
 drivers/input/serio/rpckbd.c     |   14 +-------------
 drivers/input/serio/xilinx_ps2.c |   14 +-------------
 4 files changed, 4 insertions(+), 51 deletions(-)

diff --git a/drivers/input/serio/altera_ps2.c b/drivers/input/serio/altera_ps2.c
index d363dc4..35864c6 100644
--- a/drivers/input/serio/altera_ps2.c
+++ b/drivers/input/serio/altera_ps2.c
@@ -196,18 +196,7 @@ static struct platform_driver altera_ps2_driver = {
 		.of_match_table = altera_ps2_match,
 	},
 };
-
-static int __init altera_ps2_init(void)
-{
-	return platform_driver_register(&altera_ps2_driver);
-}
-module_init(altera_ps2_init);
-
-static void __exit altera_ps2_exit(void)
-{
-	platform_driver_unregister(&altera_ps2_driver);
-}
-module_exit(altera_ps2_exit);
+module_platform_driver(altera_ps2_driver);
 
 MODULE_DESCRIPTION("Altera University Program PS2 controller driver");
 MODULE_AUTHOR("Thomas Chou <thomas@wytron.com.tw>");
diff --git a/drivers/input/serio/at32psif.c b/drivers/input/serio/at32psif.c
index 95280f9..421a744 100644
--- a/drivers/input/serio/at32psif.c
+++ b/drivers/input/serio/at32psif.c
@@ -358,19 +358,7 @@ static struct platform_driver psif_driver = {
 	.suspend	= psif_suspend,
 	.resume		= psif_resume,
 };
-
-static int __init psif_init(void)
-{
-	return platform_driver_probe(&psif_driver, psif_probe);
-}
-
-static void __exit psif_exit(void)
-{
-	platform_driver_unregister(&psif_driver);
-}
-
-module_init(psif_init);
-module_exit(psif_exit);
+module_platform_driver(psif_driver);
 
 MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>");
 MODULE_DESCRIPTION("Atmel AVR32 PSIF PS/2 driver");
diff --git a/drivers/input/serio/rpckbd.c b/drivers/input/serio/rpckbd.c
index 7ec3c97..8b44ddc 100644
--- a/drivers/input/serio/rpckbd.c
+++ b/drivers/input/serio/rpckbd.c
@@ -143,16 +143,4 @@ static struct platform_driver rpckbd_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init rpckbd_init(void)
-{
-	return platform_driver_register(&rpckbd_driver);
-}
-
-static void __exit rpckbd_exit(void)
-{
-	platform_driver_unregister(&rpckbd_driver);
-}
-
-module_init(rpckbd_init);
-module_exit(rpckbd_exit);
+module_platform_driver(rpckbd_driver);
diff --git a/drivers/input/serio/xilinx_ps2.c b/drivers/input/serio/xilinx_ps2.c
index d64c5a4..127c391 100644
--- a/drivers/input/serio/xilinx_ps2.c
+++ b/drivers/input/serio/xilinx_ps2.c
@@ -369,19 +369,7 @@ static struct platform_driver xps2_of_driver = {
 	.probe		= xps2_of_probe,
 	.remove		= __devexit_p(xps2_of_remove),
 };
-
-static int __init xps2_init(void)
-{
-	return platform_driver_register(&xps2_of_driver);
-}
-
-static void __exit xps2_cleanup(void)
-{
-	platform_driver_unregister(&xps2_of_driver);
-}
-
-module_init(xps2_init);
-module_exit(xps2_cleanup);
+module_platform_driver(xps2_of_driver);
 
 MODULE_AUTHOR("Xilinx, Inc.");
 MODULE_DESCRIPTION("Xilinx XPS PS/2 driver");
-- 
1.7.8-rc2


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

* [PATCH TRIVIAL 5/5] Input: touchscreen: use macro module_platform_driver()
  2011-11-22  9:00 [PATCH TRIVIAL 0/5] Input: use new macro module_platform_driver to save some boilerplate code JJ Ding
                   ` (3 preceding siblings ...)
  2011-11-22  9:00 ` [PATCH TRIVIAL 4/5] Input: serio: " JJ Ding
@ 2011-11-22  9:00 ` JJ Ding
  4 siblings, 0 replies; 15+ messages in thread
From: JJ Ding @ 2011-11-22  9:00 UTC (permalink / raw)
  To: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely
  Cc: linux-kernel, linux-input, JJ Ding, JJ Ding

From: JJ Ding <dgdunix@gmail.com>

Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
save some platform_driver boilerplate code. Use it.

Signed-off-by: JJ Ding <dgdunix@gmail.com>
---
 drivers/input/touchscreen/88pm860x-ts.c      |   13 +------------
 drivers/input/touchscreen/atmel-wm97xx.c     |   13 +------------
 drivers/input/touchscreen/atmel_tsadcc.c     |   15 +--------------
 drivers/input/touchscreen/da9034-ts.c        |   13 +------------
 drivers/input/touchscreen/intel-mid-touch.c  |   13 +------------
 drivers/input/touchscreen/jornada720_ts.c    |   14 +-------------
 drivers/input/touchscreen/lpc32xx_ts.c       |   13 +------------
 drivers/input/touchscreen/mainstone-wm97xx.c |   14 +-------------
 drivers/input/touchscreen/mc13783_ts.c       |   13 +------------
 drivers/input/touchscreen/pcap_ts.c          |   14 +-------------
 drivers/input/touchscreen/s3c2410_ts.c       |   14 +-------------
 drivers/input/touchscreen/stmpe-ts.c         |   15 +--------------
 drivers/input/touchscreen/tnetv107x-ts.c     |   14 +-------------
 drivers/input/touchscreen/tps6507x-ts.c      |   13 +------------
 drivers/input/touchscreen/ucb1400_ts.c       |   14 +-------------
 drivers/input/touchscreen/w90p910_ts.c       |   14 +-------------
 drivers/input/touchscreen/wm831x-ts.c        |   13 +------------
 drivers/input/touchscreen/zylonite-wm97xx.c  |   14 +-------------
 18 files changed, 18 insertions(+), 228 deletions(-)

diff --git a/drivers/input/touchscreen/88pm860x-ts.c b/drivers/input/touchscreen/88pm860x-ts.c
index b3aebc2..05f30b7 100644
--- a/drivers/input/touchscreen/88pm860x-ts.c
+++ b/drivers/input/touchscreen/88pm860x-ts.c
@@ -217,18 +217,7 @@ static struct platform_driver pm860x_touch_driver = {
 	.probe	= pm860x_touch_probe,
 	.remove	= __devexit_p(pm860x_touch_remove),
 };
-
-static int __init pm860x_touch_init(void)
-{
-	return platform_driver_register(&pm860x_touch_driver);
-}
-module_init(pm860x_touch_init);
-
-static void __exit pm860x_touch_exit(void)
-{
-	platform_driver_unregister(&pm860x_touch_driver);
-}
-module_exit(pm860x_touch_exit);
+module_platform_driver(pm860x_touch_driver);
 
 MODULE_DESCRIPTION("Touchscreen driver for Marvell Semiconductor 88PM860x");
 MODULE_AUTHOR("Haojian Zhuang <haojian.zhuang@marvell.com>");
diff --git a/drivers/input/touchscreen/atmel-wm97xx.c b/drivers/input/touchscreen/atmel-wm97xx.c
index 8034cbb..d016cb2 100644
--- a/drivers/input/touchscreen/atmel-wm97xx.c
+++ b/drivers/input/touchscreen/atmel-wm97xx.c
@@ -429,18 +429,7 @@ static struct platform_driver atmel_wm97xx_driver = {
 	.suspend	= atmel_wm97xx_suspend,
 	.resume		= atmel_wm97xx_resume,
 };
-
-static int __init atmel_wm97xx_init(void)
-{
-	return platform_driver_probe(&atmel_wm97xx_driver, atmel_wm97xx_probe);
-}
-module_init(atmel_wm97xx_init);
-
-static void __exit atmel_wm97xx_exit(void)
-{
-	platform_driver_unregister(&atmel_wm97xx_driver);
-}
-module_exit(atmel_wm97xx_exit);
+module_platform_driver(atmel_wm97xx_driver);
 
 MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>");
 MODULE_DESCRIPTION("wm97xx continuous touch driver for Atmel AT91 and AVR32");
diff --git a/drivers/input/touchscreen/atmel_tsadcc.c b/drivers/input/touchscreen/atmel_tsadcc.c
index 122a878..201b2d2 100644
--- a/drivers/input/touchscreen/atmel_tsadcc.c
+++ b/drivers/input/touchscreen/atmel_tsadcc.c
@@ -351,20 +351,7 @@ static struct platform_driver atmel_tsadcc_driver = {
 		.name	= "atmel_tsadcc",
 	},
 };
-
-static int __init atmel_tsadcc_init(void)
-{
-	return platform_driver_register(&atmel_tsadcc_driver);
-}
-
-static void __exit atmel_tsadcc_exit(void)
-{
-	platform_driver_unregister(&atmel_tsadcc_driver);
-}
-
-module_init(atmel_tsadcc_init);
-module_exit(atmel_tsadcc_exit);
-
+module_platform_driver(atmel_tsadcc_driver);
 
 MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Atmel TouchScreen Driver");
diff --git a/drivers/input/touchscreen/da9034-ts.c b/drivers/input/touchscreen/da9034-ts.c
index 2b72a59..36b65cf 100644
--- a/drivers/input/touchscreen/da9034-ts.c
+++ b/drivers/input/touchscreen/da9034-ts.c
@@ -379,18 +379,7 @@ static struct platform_driver da9034_touch_driver = {
 	.probe		= da9034_touch_probe,
 	.remove		= __devexit_p(da9034_touch_remove),
 };
-
-static int __init da9034_touch_init(void)
-{
-	return platform_driver_register(&da9034_touch_driver);
-}
-module_init(da9034_touch_init);
-
-static void __exit da9034_touch_exit(void)
-{
-	platform_driver_unregister(&da9034_touch_driver);
-}
-module_exit(da9034_touch_exit);
+module_platform_driver(da9034_touch_driver);
 
 MODULE_DESCRIPTION("Touchscreen driver for Dialog Semiconductor DA9034");
 MODULE_AUTHOR("Eric Miao <eric.miao@marvell.com>, Bin Yang <bin.yang@marvell.com>");
diff --git a/drivers/input/touchscreen/intel-mid-touch.c b/drivers/input/touchscreen/intel-mid-touch.c
index 3276952..3cd7a83 100644
--- a/drivers/input/touchscreen/intel-mid-touch.c
+++ b/drivers/input/touchscreen/intel-mid-touch.c
@@ -664,18 +664,7 @@ static struct platform_driver mrstouch_driver = {
 	.probe		= mrstouch_probe,
 	.remove		= __devexit_p(mrstouch_remove),
 };
-
-static int __init mrstouch_init(void)
-{
-	return platform_driver_register(&mrstouch_driver);
-}
-module_init(mrstouch_init);
-
-static void __exit mrstouch_exit(void)
-{
-	platform_driver_unregister(&mrstouch_driver);
-}
-module_exit(mrstouch_exit);
+module_platform_driver(mrstouch_driver);
 
 MODULE_AUTHOR("Sreedhara Murthy. D.S, sreedhara.ds@intel.com");
 MODULE_DESCRIPTION("Intel Moorestown Resistive Touch Screen Driver");
diff --git a/drivers/input/touchscreen/jornada720_ts.c b/drivers/input/touchscreen/jornada720_ts.c
index 50076c2..c3848ad 100644
--- a/drivers/input/touchscreen/jornada720_ts.c
+++ b/drivers/input/touchscreen/jornada720_ts.c
@@ -172,16 +172,4 @@ static struct platform_driver jornada720_ts_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init jornada720_ts_init(void)
-{
-	return platform_driver_register(&jornada720_ts_driver);
-}
-
-static void __exit jornada720_ts_exit(void)
-{
-	platform_driver_unregister(&jornada720_ts_driver);
-}
-
-module_init(jornada720_ts_init);
-module_exit(jornada720_ts_exit);
+module_platform_driver(jornada720_ts_driver);
diff --git a/drivers/input/touchscreen/lpc32xx_ts.c b/drivers/input/touchscreen/lpc32xx_ts.c
index 0a484ed..afcd069 100644
--- a/drivers/input/touchscreen/lpc32xx_ts.c
+++ b/drivers/input/touchscreen/lpc32xx_ts.c
@@ -392,18 +392,7 @@ static struct platform_driver lpc32xx_ts_driver = {
 		.pm	= LPC32XX_TS_PM_OPS,
 	},
 };
-
-static int __init lpc32xx_ts_init(void)
-{
-	return platform_driver_register(&lpc32xx_ts_driver);
-}
-module_init(lpc32xx_ts_init);
-
-static void __exit lpc32xx_ts_exit(void)
-{
-	platform_driver_unregister(&lpc32xx_ts_driver);
-}
-module_exit(lpc32xx_ts_exit);
+module_platform_driver(lpc32xx_ts_driver);
 
 MODULE_AUTHOR("Kevin Wells <kevin.wells@nxp.com");
 MODULE_DESCRIPTION("LPC32XX TSC Driver");
diff --git a/drivers/input/touchscreen/mainstone-wm97xx.c b/drivers/input/touchscreen/mainstone-wm97xx.c
index e966c29..7d2b213 100644
--- a/drivers/input/touchscreen/mainstone-wm97xx.c
+++ b/drivers/input/touchscreen/mainstone-wm97xx.c
@@ -302,19 +302,7 @@ static struct platform_driver mainstone_wm97xx_driver = {
 		.name = "wm97xx-touch",
 	},
 };
-
-static int __init mainstone_wm97xx_init(void)
-{
-	return platform_driver_register(&mainstone_wm97xx_driver);
-}
-
-static void __exit mainstone_wm97xx_exit(void)
-{
-	platform_driver_unregister(&mainstone_wm97xx_driver);
-}
-
-module_init(mainstone_wm97xx_init);
-module_exit(mainstone_wm97xx_exit);
+module_platform_driver(mainstone_wm97xx_driver);
 
 /* Module information */
 MODULE_AUTHOR("Liam Girdwood <lrg@slimlogic.co.uk>");
diff --git a/drivers/input/touchscreen/mc13783_ts.c b/drivers/input/touchscreen/mc13783_ts.c
index ede0274..68f86f7 100644
--- a/drivers/input/touchscreen/mc13783_ts.c
+++ b/drivers/input/touchscreen/mc13783_ts.c
@@ -240,18 +240,7 @@ static struct platform_driver mc13783_ts_driver = {
 		.name	= MC13783_TS_NAME,
 	},
 };
-
-static int __init mc13783_ts_init(void)
-{
-	return platform_driver_probe(&mc13783_ts_driver, &mc13783_ts_probe);
-}
-module_init(mc13783_ts_init);
-
-static void __exit mc13783_ts_exit(void)
-{
-	platform_driver_unregister(&mc13783_ts_driver);
-}
-module_exit(mc13783_ts_exit);
+module_platform_driver(mc13783_ts_driver);
 
 MODULE_DESCRIPTION("MC13783 input touchscreen driver");
 MODULE_AUTHOR("Sascha Hauer <s.hauer@pengutronix.de>");
diff --git a/drivers/input/touchscreen/pcap_ts.c b/drivers/input/touchscreen/pcap_ts.c
index ea6ef16..f57aeb8 100644
--- a/drivers/input/touchscreen/pcap_ts.c
+++ b/drivers/input/touchscreen/pcap_ts.c
@@ -252,19 +252,7 @@ static struct platform_driver pcap_ts_driver = {
 		.pm	= PCAP_TS_PM_OPS,
 	},
 };
-
-static int __init pcap_ts_init(void)
-{
-	return platform_driver_register(&pcap_ts_driver);
-}
-
-static void __exit pcap_ts_exit(void)
-{
-	platform_driver_unregister(&pcap_ts_driver);
-}
-
-module_init(pcap_ts_init);
-module_exit(pcap_ts_exit);
+module_platform_driver(pcap_ts_driver);
 
 MODULE_DESCRIPTION("Motorola PCAP2 touchscreen driver");
 MODULE_AUTHOR("Daniel Ribeiro / Harald Welte");
diff --git a/drivers/input/touchscreen/s3c2410_ts.c b/drivers/input/touchscreen/s3c2410_ts.c
index 64ce697..bf1a064 100644
--- a/drivers/input/touchscreen/s3c2410_ts.c
+++ b/drivers/input/touchscreen/s3c2410_ts.c
@@ -432,19 +432,7 @@ static struct platform_driver s3c_ts_driver = {
 	.probe		= s3c2410ts_probe,
 	.remove		= __devexit_p(s3c2410ts_remove),
 };
-
-static int __init s3c2410ts_init(void)
-{
-	return platform_driver_register(&s3c_ts_driver);
-}
-
-static void __exit s3c2410ts_exit(void)
-{
-	platform_driver_unregister(&s3c_ts_driver);
-}
-
-module_init(s3c2410ts_init);
-module_exit(s3c2410ts_exit);
+module_platform_driver(s3c_ts_driver);
 
 MODULE_AUTHOR("Arnaud Patard <arnaud.patard@rtp-net.org>, "
 	      "Ben Dooks <ben@simtec.co.uk>, "
diff --git a/drivers/input/touchscreen/stmpe-ts.c b/drivers/input/touchscreen/stmpe-ts.c
index ae88e13..692b685 100644
--- a/drivers/input/touchscreen/stmpe-ts.c
+++ b/drivers/input/touchscreen/stmpe-ts.c
@@ -379,20 +379,7 @@ static struct platform_driver stmpe_ts_driver = {
 	.probe = stmpe_input_probe,
 	.remove = __devexit_p(stmpe_ts_remove),
 };
-
-static int __init stmpe_ts_init(void)
-{
-	return platform_driver_register(&stmpe_ts_driver);
-}
-
-module_init(stmpe_ts_init);
-
-static void __exit stmpe_ts_exit(void)
-{
-	platform_driver_unregister(&stmpe_ts_driver);
-}
-
-module_exit(stmpe_ts_exit);
+module_platform_driver(stmpe_ts_driver);
 
 MODULE_AUTHOR("Luotao Fu <l.fu@pengutronix.de>");
 MODULE_DESCRIPTION("STMPEXXX touchscreen driver");
diff --git a/drivers/input/touchscreen/tnetv107x-ts.c b/drivers/input/touchscreen/tnetv107x-ts.c
index 0e8f63e..7e74880 100644
--- a/drivers/input/touchscreen/tnetv107x-ts.c
+++ b/drivers/input/touchscreen/tnetv107x-ts.c
@@ -378,19 +378,7 @@ static struct platform_driver tsc_driver = {
 	.driver.name	= "tnetv107x-ts",
 	.driver.owner	= THIS_MODULE,
 };
-
-static int __init tsc_init(void)
-{
-	return platform_driver_register(&tsc_driver);
-}
-
-static void __exit tsc_exit(void)
-{
-	platform_driver_unregister(&tsc_driver);
-}
-
-module_init(tsc_init);
-module_exit(tsc_exit);
+module_platform_driver(tsc_driver);
 
 MODULE_AUTHOR("Cyril Chemparathy");
 MODULE_DESCRIPTION("TNETV107X Touchscreen Driver");
diff --git a/drivers/input/touchscreen/tps6507x-ts.c b/drivers/input/touchscreen/tps6507x-ts.c
index 4303149..6c6f6d8 100644
--- a/drivers/input/touchscreen/tps6507x-ts.c
+++ b/drivers/input/touchscreen/tps6507x-ts.c
@@ -371,18 +371,7 @@ static struct platform_driver tps6507x_ts_driver = {
 	.probe = tps6507x_ts_probe,
 	.remove = __devexit_p(tps6507x_ts_remove),
 };
-
-static int __init tps6507x_ts_init(void)
-{
-	return platform_driver_register(&tps6507x_ts_driver);
-}
-module_init(tps6507x_ts_init);
-
-static void __exit tps6507x_ts_exit(void)
-{
-	platform_driver_unregister(&tps6507x_ts_driver);
-}
-module_exit(tps6507x_ts_exit);
+module_platform_driver(tps6507x_ts_driver);
 
 MODULE_AUTHOR("Todd Fischer <todd.fischer@ridgerun.com>");
 MODULE_DESCRIPTION("TPS6507x - TouchScreen driver");
diff --git a/drivers/input/touchscreen/ucb1400_ts.c b/drivers/input/touchscreen/ucb1400_ts.c
index 3b5b5df..cf2440f 100644
--- a/drivers/input/touchscreen/ucb1400_ts.c
+++ b/drivers/input/touchscreen/ucb1400_ts.c
@@ -456,16 +456,7 @@ static struct platform_driver ucb1400_ts_driver = {
 		.name	= "ucb1400_ts",
 	},
 };
-
-static int __init ucb1400_ts_init(void)
-{
-	return platform_driver_register(&ucb1400_ts_driver);
-}
-
-static void __exit ucb1400_ts_exit(void)
-{
-	platform_driver_unregister(&ucb1400_ts_driver);
-}
+module_platform_driver(ucb1400_ts_driver);
 
 module_param(adcsync, bool, 0444);
 MODULE_PARM_DESC(adcsync, "Synchronize touch readings with ADCSYNC pin.");
@@ -479,8 +470,5 @@ MODULE_PARM_DESC(ts_delay_pressure,
 		"delay between panel setup and pressure read."
 		"  Default = 0us.");
 
-module_init(ucb1400_ts_init);
-module_exit(ucb1400_ts_exit);
-
 MODULE_DESCRIPTION("Philips UCB1400 touchscreen driver");
 MODULE_LICENSE("GPL");
diff --git a/drivers/input/touchscreen/w90p910_ts.c b/drivers/input/touchscreen/w90p910_ts.c
index 217aa51..9396b21 100644
--- a/drivers/input/touchscreen/w90p910_ts.c
+++ b/drivers/input/touchscreen/w90p910_ts.c
@@ -331,19 +331,7 @@ static struct platform_driver w90x900ts_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-
-static int __init w90x900ts_init(void)
-{
-	return platform_driver_register(&w90x900ts_driver);
-}
-
-static void __exit w90x900ts_exit(void)
-{
-	platform_driver_unregister(&w90x900ts_driver);
-}
-
-module_init(w90x900ts_init);
-module_exit(w90x900ts_exit);
+module_platform_driver(w90x900ts_driver);
 
 MODULE_AUTHOR("Wan ZongShun <mcuos.com@gmail.com>");
 MODULE_DESCRIPTION("w90p910 touch screen driver!");
diff --git a/drivers/input/touchscreen/wm831x-ts.c b/drivers/input/touchscreen/wm831x-ts.c
index 9175d49..4bc851a 100644
--- a/drivers/input/touchscreen/wm831x-ts.c
+++ b/drivers/input/touchscreen/wm831x-ts.c
@@ -401,18 +401,7 @@ static struct platform_driver wm831x_ts_driver = {
 	.probe = wm831x_ts_probe,
 	.remove = __devexit_p(wm831x_ts_remove),
 };
-
-static int __init wm831x_ts_init(void)
-{
-	return platform_driver_register(&wm831x_ts_driver);
-}
-module_init(wm831x_ts_init);
-
-static void __exit wm831x_ts_exit(void)
-{
-	platform_driver_unregister(&wm831x_ts_driver);
-}
-module_exit(wm831x_ts_exit);
+module_platform_driver(wm831x_ts_driver);
 
 /* Module information */
 MODULE_AUTHOR("Mark Brown <broonie@opensource.wolfsonmicro.com>");
diff --git a/drivers/input/touchscreen/zylonite-wm97xx.c b/drivers/input/touchscreen/zylonite-wm97xx.c
index f6328c0..add6e3b 100644
--- a/drivers/input/touchscreen/zylonite-wm97xx.c
+++ b/drivers/input/touchscreen/zylonite-wm97xx.c
@@ -223,19 +223,7 @@ static struct platform_driver zylonite_wm97xx_driver = {
 		.name	= "wm97xx-touch",
 	},
 };
-
-static int __init zylonite_wm97xx_init(void)
-{
-	return platform_driver_register(&zylonite_wm97xx_driver);
-}
-
-static void __exit zylonite_wm97xx_exit(void)
-{
-	platform_driver_unregister(&zylonite_wm97xx_driver);
-}
-
-module_init(zylonite_wm97xx_init);
-module_exit(zylonite_wm97xx_exit);
+module_platform_driver(zylonite_wm97xx_driver);
 
 /* Module information */
 MODULE_AUTHOR("Mark Brown <broonie@opensource.wolfsonmicro.com>");
-- 
1.7.8-rc2


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

* Re: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
@ 2011-11-22  9:23   ` Linus Walleij
  2011-11-22 15:00   ` Mike Frysinger
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 15+ messages in thread
From: Linus Walleij @ 2011-11-22  9:23 UTC (permalink / raw)
  To: JJ Ding
  Cc: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

On Tue, Nov 22, 2011 at 10:00 AM, JJ Ding <jj_ding@emc.com.tw> wrote:

> Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
> save some platform_driver boilerplate code. Use it.
>
> Signed-off-by: JJ Ding <dgdunix@gmail.com>
(...)
> diff --git a/drivers/input/keyboard/nomadik-ske-keypad.c b/drivers/input/keyboard/nomadik-ske-keypad.c
> index fcdec5e..6c4828f 100644
> --- a/drivers/input/keyboard/nomadik-ske-keypad.c
> +++ b/drivers/input/keyboard/nomadik-ske-keypad.c
> @@ -390,18 +390,7 @@ struct platform_driver ske_keypad_driver = {
>        .probe = ske_keypad_probe,
>        .remove = __devexit_p(ske_keypad_remove),
>  };
> -
> -static int __init ske_keypad_init(void)
> -{
> -       return platform_driver_probe(&ske_keypad_driver, ske_keypad_probe);
> -}
> -module_init(ske_keypad_init);
> -
> -static void __exit ske_keypad_exit(void)
> -{
> -       platform_driver_unregister(&ske_keypad_driver);
> -}
> -module_exit(ske_keypad_exit);
> +module_platform_driver(ske_keypad_driver);
>
>  MODULE_LICENSE("GPL v2");
>  MODULE_AUTHOR("Naveen Kumar <naveen.gaddipati@stericsson.com> / Sundar Iyer <sundar.iyer@stericsson.com>");

This actually also fixes a bug since platform_driver_probe() was used even
though there is a .probe member in the driver struct, so thanks.

Acked-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

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

* Re: [PATCH TRIVIAL 2/5] Input: misc: use macro module_platform_driver()
  2011-11-22  9:00 ` [PATCH TRIVIAL 2/5] Input: misc: " JJ Ding
@ 2011-11-22 14:59   ` Mike Frysinger
  0 siblings, 0 replies; 15+ messages in thread
From: Mike Frysinger @ 2011-11-22 14:59 UTC (permalink / raw)
  To: JJ Ding
  Cc: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

On Tue, Nov 22, 2011 at 04:00, JJ Ding <jj_ding@emc.com.tw> wrote:
>  drivers/input/misc/bfin_rotary.c       |   13 +------------

Acked-by: Mike Frysinger <vapier@gentoo.org>
-mike

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

* Re: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
  2011-11-22  9:23   ` Linus Walleij
@ 2011-11-22 15:00   ` Mike Frysinger
  2011-11-22 20:15   ` H Hartley Sweeten
  2012-01-10 20:47   ` Geert Uytterhoeven
  3 siblings, 0 replies; 15+ messages in thread
From: Mike Frysinger @ 2011-11-22 15:00 UTC (permalink / raw)
  To: JJ Ding
  Cc: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

On Tue, Nov 22, 2011 at 04:00, JJ Ding wrote:
>  drivers/input/keyboard/adp5520-keys.c       |   13 +------------
>  drivers/input/keyboard/bf54x-keys.c         |   14 +-------------

Acked-by: Mike Frysinger <vapier@gentoo.org>
-mike

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

* RE: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
  2011-11-22  9:23   ` Linus Walleij
  2011-11-22 15:00   ` Mike Frysinger
@ 2011-11-22 20:15   ` H Hartley Sweeten
  2012-01-10 20:47   ` Geert Uytterhoeven
  3 siblings, 0 replies; 15+ messages in thread
From: H Hartley Sweeten @ 2011-11-22 20:15 UTC (permalink / raw)
  To: JJ Ding, Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely
  Cc: linux-kernel, linux-input, JJ Ding

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 1382 bytes --]

On Tuesday, November 22, 2011 2:01 AM, JJ Ding wrote:
> 
> Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
> save some platform_driver boilerplate code. Use it.
> 
> Signed-off-by: JJ Ding <dgdunix@gmail.com>
> ---
>  drivers/input/keyboard/ep93xx_keypad.c      |   14 +-------------
> 
> diff --git a/drivers/input/keyboard/ep93xx_keypad.c b/drivers/input/keyboard/ep93xx_keypad.c
> index 4662c5d..0ba69f3 100644
> --- a/drivers/input/keyboard/ep93xx_keypad.c
> +++ b/drivers/input/keyboard/ep93xx_keypad.c
> @@ -390,19 +390,7 @@ static struct platform_driver ep93xx_keypad_driver = {
>  	.suspend	= ep93xx_keypad_suspend,
>  	.resume		= ep93xx_keypad_resume,
>  };
> -
> -static int __init ep93xx_keypad_init(void)
> -{
> -	return platform_driver_register(&ep93xx_keypad_driver);
> -}
> -
> -static void __exit ep93xx_keypad_exit(void)
> -{
> -	platform_driver_unregister(&ep93xx_keypad_driver);
> -}
> -
> -module_init(ep93xx_keypad_init);
> -module_exit(ep93xx_keypad_exit);
> +module_platform_driver(ep93xx_keypad_driver);
>  
>  MODULE_LICENSE("GPL");
>  MODULE_AUTHOR("H Hartley Sweeten <hsweeten@visionengravers.com>");

Acked-by: H Hartley Sweeten <hsweeten@visionengravers.com>

Thanks!ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

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

* Re: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
                     ` (2 preceding siblings ...)
  2011-11-22 20:15   ` H Hartley Sweeten
@ 2012-01-10 20:47   ` Geert Uytterhoeven
  2012-01-10 20:57     ` Geert Uytterhoeven
  3 siblings, 1 reply; 15+ messages in thread
From: Geert Uytterhoeven @ 2012-01-10 20:47 UTC (permalink / raw)
  To: JJ Ding
  Cc: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

On Tue, Nov 22, 2011 at 10:00, JJ Ding <jj_ding@emc.com.tw> wrote:
> From: JJ Ding <dgdunix@gmail.com>
>
> Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
> save some platform_driver boilerplate code. Use it.

> diff --git a/drivers/input/keyboard/amikbd.c b/drivers/input/keyboard/amikbd.c
> index 79172af..6df5f6a 100644
> --- a/drivers/input/keyboard/amikbd.c
> +++ b/drivers/input/keyboard/amikbd.c
> @@ -259,19 +259,6 @@ static struct platform_driver amikbd_driver = {
>                .owner  = THIS_MODULE,
>        },
>  };
> -
> -static int __init amikbd_init(void)
> -{
> -       return platform_driver_probe(&amikbd_driver, amikbd_probe);
> -}
> -
> -module_init(amikbd_init);
> -
> -static void __exit amikbd_exit(void)
> -{
> -       platform_driver_unregister(&amikbd_driver);
> -}
> -
> -module_exit(amikbd_exit);
> +module_platform_driver(amikbd_driver);
>
>  MODULE_ALIAS("platform:amiga-keyboard");

Sorry for not noticing before, but this is not correct.
Drivers using platform_driver_probe() typically don't fill in the
platform_driver.probe
method, as it's passed explicitly to platform_driver_probe() instead.
Hence amikbd_probe() is now referenced nowhere, and thus never called
(doesn't the compiler warn about amikbd_probe() being defined but unused?).

> diff --git a/drivers/input/keyboard/davinci_keyscan.c b/drivers/input/keyboard/davinci_keyscan.c
> index 9d82b3a..4698252 100644
> --- a/drivers/input/keyboard/davinci_keyscan.c
> +++ b/drivers/input/keyboard/davinci_keyscan.c
> @@ -328,18 +328,7 @@ static struct platform_driver davinci_ks_driver = {
>        },
>        .remove = __devexit_p(davinci_ks_remove),
>  };
> -
> -static int __init davinci_ks_init(void)
> -{
> -       return platform_driver_probe(&davinci_ks_driver, davinci_ks_probe);
> -}
> -module_init(davinci_ks_init);
> -
> -static void __exit davinci_ks_exit(void)
> -{
> -       platform_driver_unregister(&davinci_ks_driver);
> -}
> -module_exit(davinci_ks_exit);
> +module_platform_driver(davinci_ks_driver);
>
>  MODULE_AUTHOR("Miguel Aguilar");
>  MODULE_DESCRIPTION("Texas Instruments DaVinci Key Scan Driver");

Same here, I think.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

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

* Re: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2012-01-10 20:47   ` Geert Uytterhoeven
@ 2012-01-10 20:57     ` Geert Uytterhoeven
  2012-01-10 22:22       ` Dmitry Torokhov
  2012-01-11  2:07       ` JJ Ding
  0 siblings, 2 replies; 15+ messages in thread
From: Geert Uytterhoeven @ 2012-01-10 20:57 UTC (permalink / raw)
  To: JJ Ding
  Cc: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

On Tue, Jan 10, 2012 at 21:47, Geert Uytterhoeven <geert@linux-m68k.org> wrote:
> On Tue, Nov 22, 2011 at 10:00, JJ Ding <jj_ding@emc.com.tw> wrote:
>> From: JJ Ding <dgdunix@gmail.com>
>>
>> Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
>> save some platform_driver boilerplate code. Use it.
>
>> diff --git a/drivers/input/keyboard/amikbd.c b/drivers/input/keyboard/amikbd.c
>> index 79172af..6df5f6a 100644
>> --- a/drivers/input/keyboard/amikbd.c
>> +++ b/drivers/input/keyboard/amikbd.c
>> @@ -259,19 +259,6 @@ static struct platform_driver amikbd_driver = {
>>                .owner  = THIS_MODULE,
>>        },
>>  };
>> -
>> -static int __init amikbd_init(void)
>> -{
>> -       return platform_driver_probe(&amikbd_driver, amikbd_probe);
>> -}
>> -
>> -module_init(amikbd_init);
>> -
>> -static void __exit amikbd_exit(void)
>> -{
>> -       platform_driver_unregister(&amikbd_driver);
>> -}
>> -
>> -module_exit(amikbd_exit);
>> +module_platform_driver(amikbd_driver);
>>
>>  MODULE_ALIAS("platform:amiga-keyboard");
>
> Sorry for not noticing before, but this is not correct.
> Drivers using platform_driver_probe() typically don't fill in the
> platform_driver.probe
> method, as it's passed explicitly to platform_driver_probe() instead.
> Hence amikbd_probe() is now referenced nowhere, and thus never called
> (doesn't the compiler warn about amikbd_probe() being defined but unused?).
>
>> diff --git a/drivers/input/keyboard/davinci_keyscan.c b/drivers/input/keyboard/davinci_keyscan.c
>> index 9d82b3a..4698252 100644
>> --- a/drivers/input/keyboard/davinci_keyscan.c
>> +++ b/drivers/input/keyboard/davinci_keyscan.c
>> @@ -328,18 +328,7 @@ static struct platform_driver davinci_ks_driver = {
>>        },
>>        .remove = __devexit_p(davinci_ks_remove),
>>  };
>> -
>> -static int __init davinci_ks_init(void)
>> -{
>> -       return platform_driver_probe(&davinci_ks_driver, davinci_ks_probe);
>> -}
>> -module_init(davinci_ks_init);
>> -
>> -static void __exit davinci_ks_exit(void)
>> -{
>> -       platform_driver_unregister(&davinci_ks_driver);
>> -}
>> -module_exit(davinci_ks_exit);
>> +module_platform_driver(davinci_ks_driver);
>>
>>  MODULE_AUTHOR("Miguel Aguilar");
>>  MODULE_DESCRIPTION("Texas Instruments DaVinci Key Scan Driver");
>
> Same here, I think.

And looking for platform_driver_probe() in recent changesets, I found
a few more:

drivers/input/touchscreen/atmel-wm97xx.c atmel_wm97xx_probe
drivers/input/touchscreen/mc13783_ts.c mc13783_ts_probe
drivers/input/serio/at32psif.c psif_probe
drivers/input/mouse/amimouse.c amimouse_probe

Interestingly, in drivers/input/misc/twl4030-pwrbutton.c you did make
platform_driver.probe point to twl4030_pwrbutton_probe().
But that one is also broken, as twl4030_pwrbutton_probe() is marked __init,
which is no longer correct.

Still, setting up platform_driver.probe and removing __init from all probe
functions is not the right thing to do, as this make (non-__init) kernel code
size bigger, while none of these devices are hotpluggable and thus cannot
appear after bootup. That's why we have platform_driver_probe() in the
first place. So I think all of this should be reverted for non-hotpluggable
drivers.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

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

* Re: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2012-01-10 20:57     ` Geert Uytterhoeven
@ 2012-01-10 22:22       ` Dmitry Torokhov
  2012-01-10 23:07         ` Dmitry Torokhov
  2012-01-11  2:07       ` JJ Ding
  1 sibling, 1 reply; 15+ messages in thread
From: Dmitry Torokhov @ 2012-01-10 22:22 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: JJ Ding, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

On Tue, Jan 10, 2012 at 09:57:08PM +0100, Geert Uytterhoeven wrote:
> On Tue, Jan 10, 2012 at 21:47, Geert Uytterhoeven <geert@linux-m68k.org> wrote:
> > On Tue, Nov 22, 2011 at 10:00, JJ Ding <jj_ding@emc.com.tw> wrote:
> >> From: JJ Ding <dgdunix@gmail.com>
> >>
> >> Commit 940ab88962bc1aff3273a8356d64577a6e386736 introduced a new macro to
> >> save some platform_driver boilerplate code. Use it.
> >
> >> diff --git a/drivers/input/keyboard/amikbd.c b/drivers/input/keyboard/amikbd.c
> >> index 79172af..6df5f6a 100644
> >> --- a/drivers/input/keyboard/amikbd.c
> >> +++ b/drivers/input/keyboard/amikbd.c
> >> @@ -259,19 +259,6 @@ static struct platform_driver amikbd_driver = {
> >>                .owner  = THIS_MODULE,
> >>        },
> >>  };
> >> -
> >> -static int __init amikbd_init(void)
> >> -{
> >> -       return platform_driver_probe(&amikbd_driver, amikbd_probe);
> >> -}
> >> -
> >> -module_init(amikbd_init);
> >> -
> >> -static void __exit amikbd_exit(void)
> >> -{
> >> -       platform_driver_unregister(&amikbd_driver);
> >> -}
> >> -
> >> -module_exit(amikbd_exit);
> >> +module_platform_driver(amikbd_driver);
> >>
> >>  MODULE_ALIAS("platform:amiga-keyboard");
> >
> > Sorry for not noticing before, but this is not correct.
> > Drivers using platform_driver_probe() typically don't fill in the
> > platform_driver.probe
> > method, as it's passed explicitly to platform_driver_probe() instead.
> > Hence amikbd_probe() is now referenced nowhere, and thus never called
> > (doesn't the compiler warn about amikbd_probe() being defined but unused?).
> >
> >> diff --git a/drivers/input/keyboard/davinci_keyscan.c b/drivers/input/keyboard/davinci_keyscan.c
> >> index 9d82b3a..4698252 100644
> >> --- a/drivers/input/keyboard/davinci_keyscan.c
> >> +++ b/drivers/input/keyboard/davinci_keyscan.c
> >> @@ -328,18 +328,7 @@ static struct platform_driver davinci_ks_driver = {
> >>        },
> >>        .remove = __devexit_p(davinci_ks_remove),
> >>  };
> >> -
> >> -static int __init davinci_ks_init(void)
> >> -{
> >> -       return platform_driver_probe(&davinci_ks_driver, davinci_ks_probe);
> >> -}
> >> -module_init(davinci_ks_init);
> >> -
> >> -static void __exit davinci_ks_exit(void)
> >> -{
> >> -       platform_driver_unregister(&davinci_ks_driver);
> >> -}
> >> -module_exit(davinci_ks_exit);
> >> +module_platform_driver(davinci_ks_driver);
> >>
> >>  MODULE_AUTHOR("Miguel Aguilar");
> >>  MODULE_DESCRIPTION("Texas Instruments DaVinci Key Scan Driver");
> >
> > Same here, I think.
> 
> And looking for platform_driver_probe() in recent changesets, I found
> a few more:
> 
> drivers/input/touchscreen/atmel-wm97xx.c atmel_wm97xx_probe
> drivers/input/touchscreen/mc13783_ts.c mc13783_ts_probe
> drivers/input/serio/at32psif.c psif_probe
> drivers/input/mouse/amimouse.c amimouse_probe
> 
> Interestingly, in drivers/input/misc/twl4030-pwrbutton.c you did make
> platform_driver.probe point to twl4030_pwrbutton_probe().
> But that one is also broken, as twl4030_pwrbutton_probe() is marked __init,
> which is no longer correct.
> 
> Still, setting up platform_driver.probe and removing __init from all probe
> functions is not the right thing to do, as this make (non-__init) kernel code
> size bigger, while none of these devices are hotpluggable and thus cannot
> appear after bootup. That's why we have platform_driver_probe() in the
> first place. So I think all of this should be reverted for non-hotpluggable
> drivers.

Crap, I didn't notice we messed up platform_driver_probe() users; I'll
revert changes to these drivers.

Thanks.

-- 
Dmitry

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

* Re: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2012-01-10 22:22       ` Dmitry Torokhov
@ 2012-01-10 23:07         ` Dmitry Torokhov
  0 siblings, 0 replies; 15+ messages in thread
From: Dmitry Torokhov @ 2012-01-10 23:07 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: JJ Ding, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

On Tue, Jan 10, 2012 at 02:22:31PM -0800, Dmitry Torokhov wrote:
> On Tue, Jan 10, 2012 at 09:57:08PM +0100, Geert Uytterhoeven wrote:
> > 
> > Still, setting up platform_driver.probe and removing __init from all probe
> > functions is not the right thing to do, as this make (non-__init) kernel code
> > size bigger, while none of these devices are hotpluggable and thus cannot
> > appear after bootup. That's why we have platform_driver_probe() in the
> > first place. So I think all of this should be reverted for non-hotpluggable
> > drivers.
> 
> Crap, I didn't notice we messed up platform_driver_probe() users; I'll
> revert changes to these drivers.
> 

So something like below should take care of the problem.

Thanks.

-- 
Dmitry

Input: revert some over-zealous conversions to module_platform_driver()

Recent conversion to module_platform_driver() went a bit too far and
converted not only drivers that used platform_driver_register() but
also ones using platform_driver_probe(), breaking them in process.

Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
---

 drivers/input/keyboard/amikbd.c             |   15 ++++++++++++++-
 drivers/input/keyboard/davinci_keyscan.c    |   13 ++++++++++++-
 drivers/input/keyboard/nomadik-ske-keypad.c |   13 ++++++++++++-
 drivers/input/misc/twl4030-pwrbutton.c      |   15 +++++++++++++--
 drivers/input/mouse/amimouse.c              |   16 ++++++++++++++--
 drivers/input/serio/at32psif.c              |   14 +++++++++++++-
 drivers/input/touchscreen/atmel-wm97xx.c    |   13 ++++++++++++-
 drivers/input/touchscreen/mc13783_ts.c      |   13 ++++++++++++-
 8 files changed, 102 insertions(+), 10 deletions(-)


diff --git a/drivers/input/keyboard/amikbd.c b/drivers/input/keyboard/amikbd.c
index 6df5f6a..79172af 100644
--- a/drivers/input/keyboard/amikbd.c
+++ b/drivers/input/keyboard/amikbd.c
@@ -259,6 +259,19 @@ static struct platform_driver amikbd_driver = {
 		.owner	= THIS_MODULE,
 	},
 };
-module_platform_driver(amikbd_driver);
+
+static int __init amikbd_init(void)
+{
+	return platform_driver_probe(&amikbd_driver, amikbd_probe);
+}
+
+module_init(amikbd_init);
+
+static void __exit amikbd_exit(void)
+{
+	platform_driver_unregister(&amikbd_driver);
+}
+
+module_exit(amikbd_exit);
 
 MODULE_ALIAS("platform:amiga-keyboard");
diff --git a/drivers/input/keyboard/davinci_keyscan.c b/drivers/input/keyboard/davinci_keyscan.c
index 4698252..9d82b3a 100644
--- a/drivers/input/keyboard/davinci_keyscan.c
+++ b/drivers/input/keyboard/davinci_keyscan.c
@@ -328,7 +328,18 @@ static struct platform_driver davinci_ks_driver = {
 	},
 	.remove	= __devexit_p(davinci_ks_remove),
 };
-module_platform_driver(davinci_ks_driver);
+
+static int __init davinci_ks_init(void)
+{
+	return platform_driver_probe(&davinci_ks_driver, davinci_ks_probe);
+}
+module_init(davinci_ks_init);
+
+static void __exit davinci_ks_exit(void)
+{
+	platform_driver_unregister(&davinci_ks_driver);
+}
+module_exit(davinci_ks_exit);
 
 MODULE_AUTHOR("Miguel Aguilar");
 MODULE_DESCRIPTION("Texas Instruments DaVinci Key Scan Driver");
diff --git a/drivers/input/keyboard/nomadik-ske-keypad.c b/drivers/input/keyboard/nomadik-ske-keypad.c
index 5a71e55..e35566a 100644
--- a/drivers/input/keyboard/nomadik-ske-keypad.c
+++ b/drivers/input/keyboard/nomadik-ske-keypad.c
@@ -390,7 +390,18 @@ static struct platform_driver ske_keypad_driver = {
 	.probe = ske_keypad_probe,
 	.remove = __devexit_p(ske_keypad_remove),
 };
-module_platform_driver(ske_keypad_driver);
+
+static int __init ske_keypad_init(void)
+{
+	return platform_driver_probe(&ske_keypad_driver, ske_keypad_probe);
+}
+module_init(ske_keypad_init);
+
+static void __exit ske_keypad_exit(void)
+{
+	platform_driver_unregister(&ske_keypad_driver);
+}
+module_exit(ske_keypad_exit);
 
 MODULE_LICENSE("GPL v2");
 MODULE_AUTHOR("Naveen Kumar <naveen.gaddipati@stericsson.com> / Sundar Iyer <sundar.iyer@stericsson.com>");
diff --git a/drivers/input/misc/twl4030-pwrbutton.c b/drivers/input/misc/twl4030-pwrbutton.c
index 19a6882..38e4b50 100644
--- a/drivers/input/misc/twl4030-pwrbutton.c
+++ b/drivers/input/misc/twl4030-pwrbutton.c
@@ -107,14 +107,25 @@ static int __exit twl4030_pwrbutton_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver twl4030_pwrbutton_driver = {
-	.probe		= twl4030_pwrbutton_probe,
 	.remove		= __exit_p(twl4030_pwrbutton_remove),
 	.driver		= {
 		.name	= "twl4030_pwrbutton",
 		.owner	= THIS_MODULE,
 	},
 };
-module_platform_driver(twl4030_pwrbutton_driver);
+
+static int __init twl4030_pwrbutton_init(void)
+{
+	return platform_driver_probe(&twl4030_pwrbutton_driver,
+			twl4030_pwrbutton_probe);
+}
+module_init(twl4030_pwrbutton_init);
+
+static void __exit twl4030_pwrbutton_exit(void)
+{
+	platform_driver_unregister(&twl4030_pwrbutton_driver);
+}
+module_exit(twl4030_pwrbutton_exit);
 
 MODULE_ALIAS("platform:twl4030_pwrbutton");
 MODULE_DESCRIPTION("Triton2 Power Button");
diff --git a/drivers/input/mouse/amimouse.c b/drivers/input/mouse/amimouse.c
index 39be7b8..ff5f61a 100644
--- a/drivers/input/mouse/amimouse.c
+++ b/drivers/input/mouse/amimouse.c
@@ -140,13 +140,25 @@ static int __exit amimouse_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver amimouse_driver = {
-	.probe = amimouse_probe,
 	.remove = __exit_p(amimouse_remove),
 	.driver   = {
 		.name	= "amiga-mouse",
 		.owner	= THIS_MODULE,
 	},
 };
-module_platform_driver(amimouse_driver);
+
+static int __init amimouse_init(void)
+{
+	return platform_driver_probe(&amimouse_driver, amimouse_probe);
+}
+
+module_init(amimouse_init);
+
+static void __exit amimouse_exit(void)
+{
+	platform_driver_unregister(&amimouse_driver);
+}
+
+module_exit(amimouse_exit);
 
 MODULE_ALIAS("platform:amiga-mouse");
diff --git a/drivers/input/serio/at32psif.c b/drivers/input/serio/at32psif.c
index 421a744..95280f9 100644
--- a/drivers/input/serio/at32psif.c
+++ b/drivers/input/serio/at32psif.c
@@ -358,7 +358,19 @@ static struct platform_driver psif_driver = {
 	.suspend	= psif_suspend,
 	.resume		= psif_resume,
 };
-module_platform_driver(psif_driver);
+
+static int __init psif_init(void)
+{
+	return platform_driver_probe(&psif_driver, psif_probe);
+}
+
+static void __exit psif_exit(void)
+{
+	platform_driver_unregister(&psif_driver);
+}
+
+module_init(psif_init);
+module_exit(psif_exit);
 
 MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>");
 MODULE_DESCRIPTION("Atmel AVR32 PSIF PS/2 driver");
diff --git a/drivers/input/touchscreen/atmel-wm97xx.c b/drivers/input/touchscreen/atmel-wm97xx.c
index d016cb2..8034cbb 100644
--- a/drivers/input/touchscreen/atmel-wm97xx.c
+++ b/drivers/input/touchscreen/atmel-wm97xx.c
@@ -429,7 +429,18 @@ static struct platform_driver atmel_wm97xx_driver = {
 	.suspend	= atmel_wm97xx_suspend,
 	.resume		= atmel_wm97xx_resume,
 };
-module_platform_driver(atmel_wm97xx_driver);
+
+static int __init atmel_wm97xx_init(void)
+{
+	return platform_driver_probe(&atmel_wm97xx_driver, atmel_wm97xx_probe);
+}
+module_init(atmel_wm97xx_init);
+
+static void __exit atmel_wm97xx_exit(void)
+{
+	platform_driver_unregister(&atmel_wm97xx_driver);
+}
+module_exit(atmel_wm97xx_exit);
 
 MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>");
 MODULE_DESCRIPTION("wm97xx continuous touch driver for Atmel AT91 and AVR32");
diff --git a/drivers/input/touchscreen/mc13783_ts.c b/drivers/input/touchscreen/mc13783_ts.c
index 68f86f7..ede0274 100644
--- a/drivers/input/touchscreen/mc13783_ts.c
+++ b/drivers/input/touchscreen/mc13783_ts.c
@@ -240,7 +240,18 @@ static struct platform_driver mc13783_ts_driver = {
 		.name	= MC13783_TS_NAME,
 	},
 };
-module_platform_driver(mc13783_ts_driver);
+
+static int __init mc13783_ts_init(void)
+{
+	return platform_driver_probe(&mc13783_ts_driver, &mc13783_ts_probe);
+}
+module_init(mc13783_ts_init);
+
+static void __exit mc13783_ts_exit(void)
+{
+	platform_driver_unregister(&mc13783_ts_driver);
+}
+module_exit(mc13783_ts_exit);
 
 MODULE_DESCRIPTION("MC13783 input touchscreen driver");
 MODULE_AUTHOR("Sascha Hauer <s.hauer@pengutronix.de>");

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

* Re: [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver()
  2012-01-10 20:57     ` Geert Uytterhoeven
  2012-01-10 22:22       ` Dmitry Torokhov
@ 2012-01-11  2:07       ` JJ Ding
  1 sibling, 0 replies; 15+ messages in thread
From: JJ Ding @ 2012-01-11  2:07 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Dmitry Torokhov, Greg Kroah-Hartman, Grant Likely, linux-kernel,
	linux-input, JJ Ding

Hi Geert,

On Tue, 10 Jan 2012 21:57:08 +0100, Geert Uytterhoeven <geert@linux-m68k.org> wrote:
> On Tue, Jan 10, 2012 at 21:47, Geert Uytterhoeven <geert@linux-m68k.org> wrote:
> 
> And looking for platform_driver_probe() in recent changesets, I found
> a few more:
> 
> drivers/input/touchscreen/atmel-wm97xx.c atmel_wm97xx_probe
> drivers/input/touchscreen/mc13783_ts.c mc13783_ts_probe
> drivers/input/serio/at32psif.c psif_probe
> drivers/input/mouse/amimouse.c amimouse_probe
> 
> Interestingly, in drivers/input/misc/twl4030-pwrbutton.c you did make
> platform_driver.probe point to twl4030_pwrbutton_probe().
> But that one is also broken, as twl4030_pwrbutton_probe() is marked __init,
> which is no longer correct.
> 
> Still, setting up platform_driver.probe and removing __init from all probe
> functions is not the right thing to do, as this make (non-__init) kernel code
> size bigger, while none of these devices are hotpluggable and thus cannot
> appear after bootup. That's why we have platform_driver_probe() in the
> first place. So I think all of this should be reverted for non-hotpluggable
> drivers.

Thank you for explaining this.
I am sorry for the trouble.

jj

> Gr{oetje,eeting}s,
> 
>                         Geert
> 
> --
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
> 
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
>                                 -- Linus Torvalds
> 

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

end of thread, other threads:[~2012-01-11  2:18 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-22  9:00 [PATCH TRIVIAL 0/5] Input: use new macro module_platform_driver to save some boilerplate code JJ Ding
2011-11-22  9:00 ` [PATCH TRIVIAL 1/5] Input: keyboard: use macro module_platform_driver() JJ Ding
2011-11-22  9:23   ` Linus Walleij
2011-11-22 15:00   ` Mike Frysinger
2011-11-22 20:15   ` H Hartley Sweeten
2012-01-10 20:47   ` Geert Uytterhoeven
2012-01-10 20:57     ` Geert Uytterhoeven
2012-01-10 22:22       ` Dmitry Torokhov
2012-01-10 23:07         ` Dmitry Torokhov
2012-01-11  2:07       ` JJ Ding
2011-11-22  9:00 ` [PATCH TRIVIAL 2/5] Input: misc: " JJ Ding
2011-11-22 14:59   ` Mike Frysinger
2011-11-22  9:00 ` [PATCH TRIVIAL 3/5] Input: mouse: " JJ Ding
2011-11-22  9:00 ` [PATCH TRIVIAL 4/5] Input: serio: " JJ Ding
2011-11-22  9:00 ` [PATCH TRIVIAL 5/5] Input: touchscreen: " JJ Ding

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).