From a7f5880658a25c6507bc85f456b60eae4a1190f3 Mon Sep 17 00:00:00 2001 From: Tao Huang Date: Tue, 17 Mar 2020 19:46:41 +0800 Subject: [PATCH] kernel/ksysfs.c: Call ksysfs_init() early when CONFIG_INITCALL_ASYNC=y configfs_init()/debugfs_init() depends on ksysfs_init() to init kernel_kobj. But configfs_init()/debugfs_init() and ksysfs_init() are both in the same core_initcall level. Fix this by move ksysfs_init() to the pure_initcall level. Change-Id: Iaa23a25a59b3a133f3cecb396fc69dd7e65d45ad Signed-off-by: Tao Huang --- kernel/ksysfs.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/kernel/ksysfs.c b/kernel/ksysfs.c index 65dba9076f31..4f1f9b40f714 100644 --- a/kernel/ksysfs.c +++ b/kernel/ksysfs.c @@ -270,4 +270,8 @@ exit: return error; } +#ifdef CONFIG_INITCALL_ASYNC +pure_initcall(ksysfs_init); +#else core_initcall(ksysfs_init); +#endif