+ platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     From: Axel Lin <axel.lin@xxxxxxxxx>
has been added to the -mm tree.  Its filename is
     platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Axel Lin <axel.lin@xxxxxxxxx>
Subject: platform-drivers-x86: convert drivers/platform/x86/* to use module_platform_driver()

Convert the drivers in drivers/platform/x86/* to use the
module_platform_driver() macro which makes the code smaller and a bit
simpler.

Signed-off-by: Axel Lin <axel.lin@xxxxxxxxx>
Cc: Hong Liu <hong.liu@xxxxxxxxx>
Acked-by: Durgadoss R <Durgadoss.r@xxxxxxxxx>
Cc: Daniel Drake <dsd@xxxxxxxxxx>
Cc: Matthew Garrett <mjg@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 drivers/platform/x86/intel_mid_powerbtn.c |   12 +-----------
 drivers/platform/x86/intel_mid_thermal.c  |   13 +------------
 drivers/platform/x86/xo1-rfkill.c         |   13 +------------
 3 files changed, 3 insertions(+), 35 deletions(-)

diff -puN drivers/platform/x86/intel_mid_powerbtn.c~platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver drivers/platform/x86/intel_mid_powerbtn.c
--- a/drivers/platform/x86/intel_mid_powerbtn.c~platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver
+++ a/drivers/platform/x86/intel_mid_powerbtn.c
@@ -118,17 +118,7 @@ static struct platform_driver mfld_pb_dr
 	.remove	= __devexit_p(mfld_pb_remove),
 };
 
-static int __init mfld_pb_init(void)
-{
-	return platform_driver_register(&mfld_pb_driver);
-}
-module_init(mfld_pb_init);
-
-static void __exit mfld_pb_exit(void)
-{
-	platform_driver_unregister(&mfld_pb_driver);
-}
-module_exit(mfld_pb_exit);
+module_platform_driver(mfld_pb_driver);
 
 MODULE_AUTHOR("Hong Liu <hong.liu@xxxxxxxxx>");
 MODULE_DESCRIPTION("Intel Medfield Power Button Driver");
diff -puN drivers/platform/x86/intel_mid_thermal.c~platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver drivers/platform/x86/intel_mid_thermal.c
--- a/drivers/platform/x86/intel_mid_thermal.c~platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver
+++ a/drivers/platform/x86/intel_mid_thermal.c
@@ -565,18 +565,7 @@ static struct platform_driver mid_therma
 	.id_table = therm_id_table,
 };
 
-static int __init mid_thermal_module_init(void)
-{
-	return platform_driver_register(&mid_thermal_driver);
-}
-
-static void __exit mid_thermal_module_exit(void)
-{
-	platform_driver_unregister(&mid_thermal_driver);
-}
-
-module_init(mid_thermal_module_init);
-module_exit(mid_thermal_module_exit);
+module_platform_driver(mid_thermal_driver);
 
 MODULE_AUTHOR("Durgadoss R <durgadoss.r@xxxxxxxxx>");
 MODULE_DESCRIPTION("Intel Medfield Platform Thermal Driver");
diff -puN drivers/platform/x86/xo1-rfkill.c~platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver drivers/platform/x86/xo1-rfkill.c
--- a/drivers/platform/x86/xo1-rfkill.c~platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver
+++ a/drivers/platform/x86/xo1-rfkill.c
@@ -67,19 +67,8 @@ static struct platform_driver xo1_rfkill
 	.remove		= __devexit_p(xo1_rfkill_remove),
 };
 
-static int __init xo1_rfkill_init(void)
-{
-	return platform_driver_register(&xo1_rfkill_driver);
-}
-
-static void __exit xo1_rfkill_exit(void)
-{
-	platform_driver_unregister(&xo1_rfkill_driver);
-}
+module_platform_driver(xo1_rfkill_driver);
 
 MODULE_AUTHOR("Daniel Drake <dsd@xxxxxxxxxx>");
 MODULE_LICENSE("GPL");
 MODULE_ALIAS("platform:xo1-rfkill");
-
-module_init(xo1_rfkill_init);
-module_exit(xo1_rfkill_exit);
_
Subject: From: Axel Lin <axel.lin@xxxxxxxxx>

Patches currently in -mm which might be from axel.lin@xxxxxxxxx are

drivers-video-backlight-adp88x0_blc-fix-bit-testing-logic.patch
drivers-video-backlight-l4f00242t03c-return-proper-error-in-l4f00242t03_probe-if-regulator_get-fails.patch
linux-next.patch
platform-drivers-x86-convert-drivers-platform-x86-to-use-module_platform_driver.patch
backlight-convert-backlight-i2c-drivers-to-module_i2c_driver.patch
backlight-convert-backlight-spi-drivers-to-module_spi_driver.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux