Ensure that the hwspinlock driver is registered prior to
I2C driver registration since I2C is dependent on hwspinlock.

Signed-off-by: Hari Kanigeri <h-kanige...@ti.com>
---
 arch/arm/mach-omap2/hwspinlocks.c |    2 +-
 arch/arm/plat-omap/hwspinlock.c   |    3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/arch/arm/mach-omap2/hwspinlocks.c 
b/arch/arm/mach-omap2/hwspinlocks.c
index f0f05e1..a9f85b9 100644
--- a/arch/arm/mach-omap2/hwspinlocks.c
+++ b/arch/arm/mach-omap2/hwspinlocks.c
@@ -67,4 +67,4 @@ int __init hwspinlocks_init(void)
 
        return retval;
 }
-module_init(hwspinlocks_init);
+postcore_initcall(hwspinlocks_init);
diff --git a/arch/arm/plat-omap/hwspinlock.c b/arch/arm/plat-omap/hwspinlock.c
index 1883add..3742b04 100644
--- a/arch/arm/plat-omap/hwspinlock.c
+++ b/arch/arm/plat-omap/hwspinlock.c
@@ -309,6 +309,7 @@ static int __init hwspinlock_init(void)
 
        return retval;
 }
+postcore_initcall(hwspinlock_init);
 
 /* Cleanup function */
 static void __exit hwspinlock_exit(void)
@@ -325,8 +326,6 @@ static void __exit hwspinlock_exit(void)
        if (hwspinlock_module->is_init)
                kfree(hwspinlocks);
 }
-
-module_init(hwspinlock_init);
 module_exit(hwspinlock_exit);
 
 MODULE_LICENSE("GPL v2");
-- 
1.7.0

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

Reply via email to