diff options
author | Lorenzo Pieralisi <Lorenzo.Pieralisi@arm.com> | 2012-05-22 17:10:17 +0100 |
---|---|---|
committer | Marc Zyngier <marc.zyngier@arm.com> | 2012-07-06 14:22:47 +0100 |
commit | a85f490c04cffebdb5851fb8fdc0171422b82a91 (patch) | |
tree | 4a9067c5d49ccbfed8a1664de42876bbcdd4cf11 | |
parent | 1beecf93ea0784789ffa7835b6ffab7d369c6894 (diff) | |
download | linux-kvm-arm-arch_timers-v3.5-rc5.tar.gz |
ARM: kernel: add arch-timer C3STOP featurearch_timers-v3.5-rc5
When a CPU is shutdown its architected timer comparators registers are
lost. Within CPU idle, before processors enter shutdown they enter
clock events broadcast mode through the
clockevents_notify(CLOCK_EVT_NOTIFY_BROADCAST_ENTER, cpuid);
function where the local timers are emulated by a global always-on timer.
On CPU resume, the per-CPU tick device normal mode is restored by exiting
broadcast mode through
clockevents_notify(CLOCK_EVT_NOTIFY_BROADCAST_EXIT, cpuid);
In order for this mechanism to function, architected timers should add to
their feature C3STOP, which means that they are not able to function when the
CPU is in off-mode.
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
-rw-r--r-- | arch/arm/kernel/arch_timer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/kernel/arch_timer.c b/arch/arm/kernel/arch_timer.c index 1bb632ab8a4956..c5b019adb2caeb 100644 --- a/arch/arm/kernel/arch_timer.c +++ b/arch/arm/kernel/arch_timer.c @@ -266,7 +266,7 @@ static int __cpuinit arch_timer_setup(struct clock_event_device *clk) /* Be safe... */ arch_timer_disable(); - clk->features = CLOCK_EVT_FEAT_ONESHOT; + clk->features = CLOCK_EVT_FEAT_ONESHOT | CLOCK_EVT_FEAT_C3STOP; clk->name = "arch_sys_timer"; clk->rating = 450; clk->set_mode = arch_timer_set_mode; |