[PATCH] PM / s2idle: Export s2idle_set_ops

From: Claude Yen
Date: Thu Oct 22 2020 - 02:23:29 EST


As suspend_set_ops is exported in commit a5e4fd8783a2
("PM / Suspend: Export suspend_set_ops, suspend_valid_only_mem"),
exporting s2idle_set_ops to make kernel module setup s2idle ops too.

In this way, kernel module can hook platform suspend
functions regardless of Suspend-to-Ram(S2R) or
Suspend-to-Idle(S2I)

Signed-off-by: Claude Yen <claude.yen@xxxxxxxxxxxx>
---
kernel/power/suspend.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/kernel/power/suspend.c b/kernel/power/suspend.c
index 8b1bb5ee7e5d..0dc3e8344318 100644
--- a/kernel/power/suspend.c
+++ b/kernel/power/suspend.c
@@ -79,6 +79,7 @@ void s2idle_set_ops(const struct platform_s2idle_ops *ops)
s2idle_ops = ops;
unlock_system_sleep();
}
+EXPORT_SYMBOL_GPL(s2idle_set_ops);

static void s2idle_begin(void)
{
--
2.18.0