Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 260570
b: refs/heads/master
c: 41646b2
h: refs/heads/master
v: v3
  • Loading branch information
Vasily Khoruzhick authored and Eric Miao committed Jul 12, 2011
1 parent a83fa25 commit 9c1b9e1
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8a97ae2f554d762a4bc67b5d13b52ef39c8d6baa
refs/heads/master: 41646b24993590c49d21e6cc0f4378505e1f94a6
17 changes: 17 additions & 0 deletions trunk/arch/arm/mach-pxa/z2.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
#include <mach/pxafb.h>
#include <mach/mmc.h>
#include <plat/pxa27x_keypad.h>
#include <mach/pm.h>

#include "generic.h"
#include "devices.h"
Expand Down Expand Up @@ -677,6 +678,20 @@ static void __init z2_pmic_init(void)
static inline void z2_pmic_init(void) {}
#endif

#ifdef CONFIG_PM
static void z2_power_off(void)
{
/* We're using deep sleep as poweroff, so clear PSPR to ensure that
* bootloader will jump to its entry point in resume handler
*/
PSPR = 0x0;
local_irq_disable();
pxa27x_cpu_suspend(PWRMODE_DEEPSLEEP, PLAT_PHYS_OFFSET - PAGE_OFFSET);
}
#else
#define z2_power_off NULL
#endif

/******************************************************************************
* Machine init
******************************************************************************/
Expand All @@ -698,6 +713,8 @@ static void __init z2_init(void)
z2_leds_init();
z2_keys_init();
z2_pmic_init();

pm_power_off = z2_power_off;
}

MACHINE_START(ZIPIT2, "Zipit Z2")
Expand Down

0 comments on commit 9c1b9e1

Please sign in to comment.