diff --git a/services/init/module_engine/init_modulemgr.c b/services/init/module_engine/init_modulemgr.c index b0136566ee27ad69ca0eb30e26beeafa9d1618fa..19e1573d9ee907043aac8c54a7b967f2e4a76e52 100755 --- a/services/init/module_engine/init_modulemgr.c +++ b/services/init/module_engine/init_modulemgr.c @@ -64,8 +64,16 @@ static int moduleMgrCommandsInit(int stage, int prio, void *cookie) return 0; } +static int loadAutorunModules(int stage, int prio, void *cookie) +{ + MODULE_MGR *autorun = ModuleMgrScan("init/autorun"); + INIT_LOGI("Load autorun modules return %p", autorun); + return 0; +} + MODULE_CONSTRUCTOR(void) { // Depends on parameter service + InitAddGlobalInitHook(0, loadAutorunModules); InitAddPreCfgLoadHook(0, moduleMgrCommandsInit); }