mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Grygorii Strashko <grygorii.strashko@ti.com>
To: Tony Lindgren <tony@atomide.com>, Samuel Ortiz <sameo@linux.intel.com>
Cc: Grygorii Strashko <grygorii.strashko@ti.com>,
	Santosh Shilimkar <santosh.shilimkar@ti.com>,
	<linux-omap@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: [PATCH 2/2] mfd: twl-core: convert to module_i2c_driver()
Date: Tue, 23 Apr 2013 16:19:10 +0300	[thread overview]
Message-ID: <1366723151-23209-3-git-send-email-grygorii.strashko@ti.com> (raw)
In-Reply-To: <1366723151-23209-1-git-send-email-grygorii.strashko@ti.com>

Shift TWL initialization to module/device init layer, because I2C now is
not initialized on subsys init layer and shifted to module/device init
layer instead.

The I2C <--> TWL dependency should be resolved in drivers/Makefile now.

Cc: Santosh Shilimkar <santosh.shilimkar@ti.com>
Cc: linux-omap@vger.kernel.org
Cc: linux-kernel@vger.kernel.org

Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
---
 drivers/mfd/twl-core.c |   12 +-----------
 1 file changed, 1 insertion(+), 11 deletions(-)

diff --git a/drivers/mfd/twl-core.c b/drivers/mfd/twl-core.c
index 4f3baad..f01340d 100644
--- a/drivers/mfd/twl-core.c
+++ b/drivers/mfd/twl-core.c
@@ -1347,17 +1347,7 @@ static struct i2c_driver twl_driver = {
 	.remove		= twl_remove,
 };
 
-static int __init twl_init(void)
-{
-	return i2c_add_driver(&twl_driver);
-}
-subsys_initcall(twl_init);
-
-static void __exit twl_exit(void)
-{
-	i2c_del_driver(&twl_driver);
-}
-module_exit(twl_exit);
+module_i2c_driver(twl_driver);
 
 MODULE_AUTHOR("Texas Instruments, Inc.");
 MODULE_DESCRIPTION("I2C Core interface for TWL");
-- 
1.7.9.5


  parent reply	other threads:[~2013-04-23 13:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-23 13:19 [PATCH 0/2] OMAP: fix boot sequence Grygorii Strashko
2013-04-23 13:19 ` [PATCH 1/2] i2c: omap: convert to module_platform_driver() Grygorii Strashko
2013-06-03 20:59   ` Kevin Hilman
2013-06-04 11:32     ` Grygorii Strashko
2013-06-04 18:29       ` Kevin Hilman
2013-06-05 11:28         ` Grygorii Strashko
2013-06-05 13:50           ` Wolfram Sang
2013-06-06 14:58             ` Grygorii Strashko
2013-04-23 13:19 ` Grygorii Strashko [this message]
2013-05-16 22:17   ` [PATCH 2/2] mfd: twl-core: convert to module_i2c_driver() Samuel Ortiz
2013-05-16 22:58     ` Tony Lindgren
2013-05-17 10:46       ` Grygorii Strashko
2013-04-23 17:34 ` [PATCH 0/2] OMAP: fix boot sequence Tony Lindgren
2013-04-23 17:50   ` Grygorii Strashko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1366723151-23209-3-git-send-email-grygorii.strashko@ti.com \
    --to=grygorii.strashko@ti.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=sameo@linux.intel.com \
    --cc=santosh.shilimkar@ti.com \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®