2006-01-14 18:18:37

by Yoichi Yuasa

[permalink] [raw]
Subject: [-mm PATCH] mips: add pm_power_off

Hi,

This patch adds pm_power_off() to MIPS.
This patch exists only for 2.6.15-mm4.

Signed-off-by: Yoichi Yuasa <[email protected]>

diff -Npru -X dontdiff mm4-orig/arch/mips/kernel/reset.c mm4/arch/mips/kernel/reset.c
--- mm4-orig/arch/mips/kernel/reset.c 2006-01-03 12:21:10.000000000 +0900
+++ mm4/arch/mips/kernel/reset.c 2006-01-15 02:44:26.000000000 +0900
@@ -12,6 +12,9 @@
#include <linux/reboot.h>
#include <asm/reboot.h>

+void (*pm_power_off)(void);
+EXPORT_SYMBOL(pm_power_off);
+
/*
* Urgs ... Too many MIPS machines to handle this in a generic way.
* So handle all using function pointers to machine specific
@@ -33,6 +36,9 @@ void machine_halt(void)

void machine_power_off(void)
{
+ if (pm_power_off)
+ pm_power_off();
+
_machine_power_off();
}