Commit 89d5b717 authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Rafael J. Wysocki

ACPI: PM: s2idle: fix section mismatch warning

The acpi_sleep_suspend_setup() function is missing an __init annotation,
which causes a warning in rare configurations that end up not inlining
it into its caller:

WARNING: modpost: vmlinux.o: section mismatch in reference: acpi_sleep_suspend_setup (section: .text) -> acpi_s2idle_setup (section: .init.text)

It's only called from an __init function, so adding the annotation is
correct here.
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent 9561de3a
...@@ -840,7 +840,7 @@ void __weak acpi_s2idle_setup(void) ...@@ -840,7 +840,7 @@ void __weak acpi_s2idle_setup(void)
s2idle_set_ops(&acpi_s2idle_ops); s2idle_set_ops(&acpi_s2idle_ops);
} }
static void acpi_sleep_suspend_setup(void) static void __init acpi_sleep_suspend_setup(void)
{ {
bool suspend_ops_needed = false; bool suspend_ops_needed = false;
int i; int i;
......
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