linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c: pca-isa: Utilize the module_isa_driver macro
@ 2016-05-31 16:22 William Breathitt Gray
  2016-06-19 17:48 ` Wolfram Sang
  0 siblings, 1 reply; 2+ messages in thread
From: William Breathitt Gray @ 2016-05-31 16:22 UTC (permalink / raw)
  To: wsa; +Cc: linux-i2c, linux-kernel

This driver does not do anything special in module init/exit. This patch
eliminates the module init/exit boilerplate code by utilizing the
module_isa_driver macro.

Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com>
---
 drivers/i2c/busses/i2c-pca-isa.c | 13 +------------
 1 file changed, 1 insertion(+), 12 deletions(-)

diff --git a/drivers/i2c/busses/i2c-pca-isa.c b/drivers/i2c/busses/i2c-pca-isa.c
index e0eb4ca..d916fc4 100644
--- a/drivers/i2c/busses/i2c-pca-isa.c
+++ b/drivers/i2c/busses/i2c-pca-isa.c
@@ -193,16 +193,6 @@ static struct isa_driver pca_isa_driver = {
 	}
 };
 
-static int __init pca_isa_init(void)
-{
-	return isa_register_driver(&pca_isa_driver, 1);
-}
-
-static void __exit pca_isa_exit(void)
-{
-	isa_unregister_driver(&pca_isa_driver);
-}
-
 MODULE_AUTHOR("Ian Campbell <icampbell@arcom.com>");
 MODULE_DESCRIPTION("ISA base PCA9564/PCA9665 driver");
 MODULE_LICENSE("GPL");
@@ -221,5 +211,4 @@ MODULE_PARM_DESC(clock, "Clock rate in hertz.\n\t\t"
 		"\t\t\t\tFast+: 400100 - 10000099\n"
 		"\t\t\t\tTurbo: Up to 1265800");
 
-module_init(pca_isa_init);
-module_exit(pca_isa_exit);
+module_isa_driver(pca_isa_driver, 1);
-- 
2.7.3

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

* Re: [PATCH] i2c: pca-isa: Utilize the module_isa_driver macro
  2016-05-31 16:22 [PATCH] i2c: pca-isa: Utilize the module_isa_driver macro William Breathitt Gray
@ 2016-06-19 17:48 ` Wolfram Sang
  0 siblings, 0 replies; 2+ messages in thread
From: Wolfram Sang @ 2016-06-19 17:48 UTC (permalink / raw)
  To: William Breathitt Gray; +Cc: linux-i2c, linux-kernel

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

On Tue, May 31, 2016 at 12:22:34PM -0400, William Breathitt Gray wrote:
> This driver does not do anything special in module init/exit. This patch
> eliminates the module init/exit boilerplate code by utilizing the
> module_isa_driver macro.
> 
> Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com>

Applied to for-next, thanks!


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

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

end of thread, other threads:[~2016-06-19 17:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-31 16:22 [PATCH] i2c: pca-isa: Utilize the module_isa_driver macro William Breathitt Gray
2016-06-19 17:48 ` Wolfram Sang

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