Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cfb505a7 authored by Alek Du's avatar Alek Du Committed by Thomas Gleixner
Browse files

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: default avatarAlek Du <alek.du@intel.com>
Signed-off-by: default avatarAlan Cox <alan@linux.intel.com>
LKML-Reference: <20101110164928.6365.94243.stgit@localhost.localdomain>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 7f05dec3
Loading
Loading
Loading
Loading
+16 −0
Original line number Original line Diff line number Diff line
@@ -35,6 +35,7 @@
#include <asm/i8259.h>
#include <asm/i8259.h>
#include <asm/intel_scu_ipc.h>
#include <asm/intel_scu_ipc.h>
#include <asm/apb_timer.h>
#include <asm/apb_timer.h>
#include <asm/reboot.h>




/*
/*
@@ -268,6 +269,17 @@ static int mrst_i8042_detect(void)
	return 0;
	return 0;
}
}


/* Reboot and power off are handled by the SCU on a MID device */
static void mrst_power_off(void)
{
	intel_scu_ipc_simple_command(0xf1, 1);
}

static void mrst_reboot(void)
{
	intel_scu_ipc_simple_command(0xf1, 0);
}

/*
/*
 * Moorestown specific x86_init function overrides and early setup
 * Moorestown specific x86_init function overrides and early setup
 * calls.
 * calls.
@@ -293,6 +305,10 @@ void __init x86_mrst_early_setup(void)


	legacy_pic = &null_legacy_pic;
	legacy_pic = &null_legacy_pic;


	/* Moorestown specific power_off/restart method */
	pm_power_off = mrst_power_off;
	machine_ops.emergency_restart  = mrst_reboot;

	/* Avoid searching for BIOS MP tables */
	/* Avoid searching for BIOS MP tables */
	x86_init.mpparse.find_smp_config = x86_init_noop;
	x86_init.mpparse.find_smp_config = x86_init_noop;
	x86_init.mpparse.get_smp_config = x86_init_uint_noop;
	x86_init.mpparse.get_smp_config = x86_init_uint_noop;