aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/kernel/cpu/shmobile/cpuidle.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sh/kernel/cpu/shmobile/cpuidle.c')
-rw-r--r--arch/sh/kernel/cpu/shmobile/cpuidle.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/sh/kernel/cpu/shmobile/cpuidle.c b/arch/sh/kernel/cpu/shmobile/cpuidle.c
index 4afdd975cc66..1c504bd972c3 100644
--- a/arch/sh/kernel/cpu/shmobile/cpuidle.c
+++ b/arch/sh/kernel/cpu/shmobile/cpuidle.c
@@ -21,6 +21,7 @@
21static unsigned long cpuidle_mode[] = { 21static unsigned long cpuidle_mode[] = {
22 SUSP_SH_SLEEP, /* regular sleep mode */ 22 SUSP_SH_SLEEP, /* regular sleep mode */
23 SUSP_SH_SLEEP | SUSP_SH_SF, /* sleep mode + self refresh */ 23 SUSP_SH_SLEEP | SUSP_SH_SF, /* sleep mode + self refresh */
24 SUSP_SH_STANDBY | SUSP_SH_SF, /* software standby mode + self refresh */
24}; 25};
25 26
26static int cpuidle_sleep_enter(struct cpuidle_device *dev, 27static int cpuidle_sleep_enter(struct cpuidle_device *dev,
@@ -96,6 +97,16 @@ void sh_mobile_setup_cpuidle(void)
96 state->flags |= CPUIDLE_FLAG_TIME_VALID; 97 state->flags |= CPUIDLE_FLAG_TIME_VALID;
97 state->enter = cpuidle_sleep_enter; 98 state->enter = cpuidle_sleep_enter;
98 99
100 state = &dev->states[i++];
101 snprintf(state->name, CPUIDLE_NAME_LEN, "C2");
102 strncpy(state->desc, "SuperH Mobile Standby Mode [SF]", CPUIDLE_DESC_LEN);
103 state->exit_latency = 2300;
104 state->target_residency = 1 * 2;
105 state->power_usage = 1;
106 state->flags = 0;
107 state->flags |= CPUIDLE_FLAG_TIME_VALID;
108 state->enter = cpuidle_sleep_enter;
109
99 dev->state_count = i; 110 dev->state_count = i;
100 111
101 cpuidle_register_device(dev); 112 cpuidle_register_device(dev);