diff options
| author | Alek Du <alek.du@intel.com> | 2010-11-10 11:50:08 -0500 |
|---|---|---|
| committer | Thomas Gleixner <tglx@linutronix.de> | 2010-11-11 05:34:27 -0500 |
| commit | cfb505a7ebd4c84206b4cc7d9f966d864a2ac05a (patch) | |
| tree | a17a5f480539dd4604b1026d411199040b845079 | |
| parent | 7f05dec3dd70f086870fdc1d40dbe30db1fe0994 (diff) | |
x86: mrst: Add Moorestown specific reboot/shutdown support
Moorestowns needs to use a special IPC command to reboot or shutdown the
platform.
Signed-off-by: Alek Du <alek.du@intel.com>
Signed-off-by: Alan Cox <alan@linux.intel.com>
LKML-Reference: <20101110164928.6365.94243.stgit@localhost.localdomain>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
| -rw-r--r-- | arch/x86/platform/mrst/mrst.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/x86/platform/mrst/mrst.c b/arch/x86/platform/mrst/mrst.c index e6f4473fc05b..c727d97f7f31 100644 --- a/arch/x86/platform/mrst/mrst.c +++ b/arch/x86/platform/mrst/mrst.c | |||
| @@ -35,6 +35,7 @@ | |||
| 35 | #include <asm/i8259.h> | 35 | #include <asm/i8259.h> |
| 36 | #include <asm/intel_scu_ipc.h> | 36 | #include <asm/intel_scu_ipc.h> |
| 37 | #include <asm/apb_timer.h> | 37 | #include <asm/apb_timer.h> |
| 38 | #include <asm/reboot.h> | ||
| 38 | 39 | ||
| 39 | 40 | ||
| 40 | /* | 41 | /* |
| @@ -268,6 +269,17 @@ static int mrst_i8042_detect(void) | |||
| 268 | return 0; | 269 | return 0; |
| 269 | } | 270 | } |
| 270 | 271 | ||
| 272 | /* Reboot and power off are handled by the SCU on a MID device */ | ||
| 273 | static void mrst_power_off(void) | ||
| 274 | { | ||
| 275 | intel_scu_ipc_simple_command(0xf1, 1); | ||
| 276 | } | ||
| 277 | |||
| 278 | static void mrst_reboot(void) | ||
| 279 | { | ||
| 280 | intel_scu_ipc_simple_command(0xf1, 0); | ||
| 281 | } | ||
| 282 | |||
| 271 | /* | 283 | /* |
| 272 | * Moorestown specific x86_init function overrides and early setup | 284 | * Moorestown specific x86_init function overrides and early setup |
| 273 | * calls. | 285 | * calls. |
| @@ -293,6 +305,10 @@ void __init x86_mrst_early_setup(void) | |||
| 293 | 305 | ||
| 294 | legacy_pic = &null_legacy_pic; | 306 | legacy_pic = &null_legacy_pic; |
| 295 | 307 | ||
| 308 | /* Moorestown specific power_off/restart method */ | ||
| 309 | pm_power_off = mrst_power_off; | ||
| 310 | machine_ops.emergency_restart = mrst_reboot; | ||
| 311 | |||
| 296 | /* Avoid searching for BIOS MP tables */ | 312 | /* Avoid searching for BIOS MP tables */ |
| 297 | x86_init.mpparse.find_smp_config = x86_init_noop; | 313 | x86_init.mpparse.find_smp_config = x86_init_noop; |
| 298 | x86_init.mpparse.get_smp_config = x86_init_uint_noop; | 314 | x86_init.mpparse.get_smp_config = x86_init_uint_noop; |
