Commit 5adf5781 authored by Saravana Kannan's avatar Saravana Kannan Committed by Greg Kroah-Hartman

of/platform: Fix device_links_supplier_sync_state_resume() warning

In platforms/devices which have CONFIG_OF turned on but don't have a
populated DT, the calls to device_links_supplier_sync_state_pause() and
device_links_supplier_sync_state_resume() can get mismatched. This will
cause a warning during boot. Fix the warning by making sure the calls are
matched even in that case.
Reported-by: default avatarQian Cai <cai@lca.pw>
Signed-off-by: default avatarSaravana Kannan <saravanak@google.com>
Link: https://lore.kernel.org/r/20190807020559.74458-1-saravanak@google.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 0ad0bdd8
......@@ -723,7 +723,8 @@ arch_initcall_sync(of_platform_default_populate_init);
static int __init of_platform_sync_state_init(void)
{
device_links_supplier_sync_state_resume();
if (of_have_populated_dt())
device_links_supplier_sync_state_resume();
return 0;
}
late_initcall_sync(of_platform_sync_state_init);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment