diff options
author | Lily Zhang <r58066@freescale.com> | 2011-01-13 19:10:40 +0800 |
---|---|---|
committer | Lily Zhang <r58066@freescale.com> | 2011-01-13 19:15:01 +0800 |
commit | 783481236fa5b8d94b2e510a35e56562558d3d63 (patch) | |
tree | 368745fc29dbc37b9363ee963feded51a19e57bd /arch | |
parent | 5b4080ccbbf128c549794560968310d0fec87c49 (diff) |
ENGR00137946 mx53 smd: add power off support
Clear SYS_ON_OFF_CTRL(GPIO7) as 0 to power down
the system.
SW19 must be put as location 2 to make it take
effect.
Signed-off-by: Lily Zhang <r58066@freescale.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-mx5/mx53_smd.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/arm/mach-mx5/mx53_smd.c b/arch/arm/mach-mx5/mx53_smd.c index 19c17d5944c2..8762cb46ce63 100644 --- a/arch/arm/mach-mx5/mx53_smd.c +++ b/arch/arm/mach-mx5/mx53_smd.c @@ -1005,6 +1005,11 @@ static struct mxc_bt_rfkill_platform_data mxc_bt_rfkill_data = { .power_change = mx53_smd_bt_power_change, }; +static void mx53_smd_power_off(void) +{ + gpio_request(MX53_SMD_SYS_ON_OFF_CTL, "power-off"); + gpio_set_value(MX53_SMD_SYS_ON_OFF_CTL, 0); +} /*! * Board specific fixup function. It is called by \b setup_arch() in * setup.c file very early on during kernel starts. It allows the user to @@ -1166,6 +1171,7 @@ static void __init mxc_board_init(void) mxc_cpu_common_init(); mx53_smd_io_init(); + pm_power_off = mx53_smd_power_off; mxc_register_device(&mxc_dma_device, NULL); mxc_register_device(&mxc_wdt_device, NULL); mxc_register_device(&mxcspi1_device, &mxcspi1_data); |