[PATCH v3 47/47] kernel: Remove pm_power_off
From: Guenter Roeck
Date: Mon Oct 27 2014 - 11:58:03 EST
No users of pm_power_off are left, so it is safe to remove the function.
Cc: Rafael J. Wysocki <rjw@xxxxxxxxxxxxx>
Cc: Pavel Machek <pavel@xxxxxx>
Cc: Len Brown <len.brown@xxxxxxxxx>
Acked-by: Rafael J. Wysocki <rjw@xxxxxxxxxxxxx>
Signed-off-by: Guenter Roeck <linux@xxxxxxxxxxxx>
---
v3:
- Replace poweroff in all newly introduced variables and in text
with power_off or power-off as appropriate
v2:
- poweroff -> power_off for API functions
include/linux/pm.h | 1 -
kernel/power/power_off_handler.c | 10 +---------
2 files changed, 1 insertion(+), 10 deletions(-)
diff --git a/include/linux/pm.h b/include/linux/pm.h
index 49b3420..4d92122 100644
--- a/include/linux/pm.h
+++ b/include/linux/pm.h
@@ -31,7 +31,6 @@
/*
* Callbacks for platform drivers to implement.
*/
-extern void (*pm_power_off)(void);
extern void (*pm_power_off_prepare)(void);
/*
diff --git a/kernel/power/power_off_handler.c b/kernel/power/power_off_handler.c
index 97b7163..8d01e77 100644
--- a/kernel/power/power_off_handler.c
+++ b/kernel/power/power_off_handler.c
@@ -22,12 +22,6 @@
#include <linux/types.h>
/*
- * If set, calling this function will power off the system immediately.
- */
-void (*pm_power_off)(void);
-EXPORT_SYMBOL(pm_power_off);
-
-/*
* Notifier list for kernel code which wants to be called
* to power off the system.
*/
@@ -259,8 +253,6 @@ void do_kernel_power_off(void)
* removed while the call chain is traversed, but we'll have to carry
* that risk.
*/
- if (pm_power_off)
- pm_power_off();
raw_notifier_call_chain(&power_off_handler_list, 0, NULL);
}
@@ -271,6 +263,6 @@ void do_kernel_power_off(void)
*/
bool have_kernel_power_off(void)
{
- return pm_power_off != NULL || power_off_handler_list.head != NULL;
+ return power_off_handler_list.head != NULL;
}
EXPORT_SYMBOL(have_kernel_power_off);
--
1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/