提交 37f54ee5 编写于 作者: D David Brownell 提交者: Jean Delvare

hwmon: Use subsys_initcall

Subsystem infrastructure should normally register with "subsys_initcall",
so that it's available to drivers that may need to initialize early.

This patch updates "hwmon" to do so.  It's common for embedded systems to
have multifunction chips with hardware monitoring interfaces, and to have
those chips be used during system bringup ... before a normal "module_init"
would kick, or maybe just linked so they'd init before hwmon.
Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: NJean Delvare <khali@linux-fr.org>
上级 41be722b
......@@ -101,7 +101,7 @@ static void __exit hwmon_exit(void)
class_destroy(hwmon_class);
}
module_init(hwmon_init);
subsys_initcall(hwmon_init);
module_exit(hwmon_exit);
EXPORT_SYMBOL_GPL(hwmon_device_register);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册