Skip to contentSkip to conversation

olpc-ec: initialise earlier

PATCH Superseded Daniel Drake 2 participants 2 messages Aug 10, 2013 – Aug 14, 2013 x86 platform drivers

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 olpc-ec: initialise earlier

Being a low-level component, various drivers (e.g. olpc-battery) assume that it is ok to communicate with the OLPC Embedded Controller during probe. Therefore the OLPC EC driver must be initialised before other drivers try to use it. This was the case until it was recently moved out of arch/x86 and restructured.

Use arch_initcall so that olpc-ec is readied earlier, matching the previous behaviour. Fixes various drivers such as olpc-battery and olpc-xo1-sci.

---
 drivers/platform/olpc/olpc-ec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/platform/olpc/olpc-ec.c +1 -1
index 0f9f859..f911952 100644
@@ -330,7 +330,7 @@ static int __init olpc_ec_init_module(void)
 	return platform_driver_register(&olpc_ec_plat_driver);
 }
 
-module_init(olpc_ec_init_module);
+arch_initcall(olpc_ec_init_module);
 
 MODULE_AUTHOR("Andres Salomon <[email protected]>");
 MODULE_LICENSE("GPL");
Signature · 1 line
1.8.3.1
#1 lore raw
Quoted 10 lines · On Sat, 10 Aug 2013 15:22:15 -0400 (EDT) Daniel Drake <[email protected]> wrote:

Being a low-level component, various drivers (e.g. olpc-battery) assume that it is ok to communicate with the OLPC Embedded Controller during probe. Therefore the OLPC EC driver must be initialised before other drivers try to use it. This was the case until it was recently moved out of arch/x86 and restructured.

Use arch_initcall so that olpc-ec is readied earlier, matching the previous behaviour. Fixes various drivers such as olpc-battery and olpc-xo1-sci.

You imply that there was a regression, but don't describe the user-visible effects of the regression.

You provide hints which would permit me, with sufficient effort, to approximately work out which kernel versions were affected by the regression and then left it at that.

I need to work out which kernel version(s) need patching, and why. Please, make it easier for me!