-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ARM: shmobile: sh73a0: Add CPU sleep suspend
Add the lighest possible sleep mode on Cortex-A9 cores: CPU sleep. It is entered by a simple dsb and wfi instruction via cpu_do_idle(). As just clocks are stopped there is no need to save or restore any state of the system. Signed-off-by: Bastian Hecht <hechtb+renesas@gmail.com> Acked-by: Magnus Damm <damm@opensource.se> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
- Loading branch information
Bastian Hecht
authored and
Simon Horman
committed
Jan 25, 2013
1 parent
8a21cda
commit 13baf88
Showing
4 changed files
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/* | ||
* sh73a0 Power management support | ||
* | ||
* Copyright (C) 2012 Bastian Hecht <hechtb+renesas@gmail.com> | ||
* | ||
* This file is subject to the terms and conditions of the GNU General Public | ||
* License. See the file "COPYING" in the main directory of this archive | ||
* for more details. | ||
*/ | ||
|
||
#include <linux/suspend.h> | ||
#include <mach/common.h> | ||
|
||
#ifdef CONFIG_SUSPEND | ||
static int sh73a0_enter_suspend(suspend_state_t suspend_state) | ||
{ | ||
cpu_do_idle(); | ||
return 0; | ||
} | ||
|
||
static void sh73a0_suspend_init(void) | ||
{ | ||
shmobile_suspend_ops.enter = sh73a0_enter_suspend; | ||
} | ||
#else | ||
static void sh73a0_suspend_init(void) {} | ||
#endif | ||
|
||
void __init sh73a0_pm_init(void) | ||
{ | ||
sh73a0_suspend_init(); | ||
} |