Skip to content

Commit ff072b2

Browse files
Hari KanigeriLuis Henriques
authored andcommitted
omap:hwspinlocks-ensure the order of registration
Ensure that the hwspinlock driver is registered prior to I2C driver registration since I2C is dependent on hwspinlock. Signed-off-by: Hari Kanigeri <[email protected]>
1 parent 11173ac commit ff072b2

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

arch/arm/mach-omap2/hwspinlocks.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,4 +76,4 @@ int __init hwspinlocks_init(void)
7676

7777
return retval;
7878
}
79-
module_init(hwspinlocks_init);
79+
postcore_initcall(hwspinlocks_init);

arch/arm/plat-omap/hwspinlock.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -310,6 +310,7 @@ static int __init hwspinlock_init(void)
310310

311311
return retval;
312312
}
313+
postcore_initcall(hwspinlock_init);
313314

314315
/* Cleanup function */
315316
static void __exit hwspinlock_exit(void)
@@ -326,8 +327,6 @@ static void __exit hwspinlock_exit(void)
326327
if (hwspinlock_module->is_init)
327328
kfree(hwspinlocks);
328329
}
329-
330-
module_init(hwspinlock_init);
331330
module_exit(hwspinlock_exit);
332331

333332
MODULE_LICENSE("GPL v2");

0 commit comments

Comments
 (0)