From: Santosh Shilimkar <santosh.shilimkar@ti.com>
To: linux-omap@vger.kernel.org
Cc: khilman@ti.com, ccross@android.com,
linux-arm-kernel@lists.infradead.org,
Santosh Shilimkar <santosh.shilimkar@ti.com>
Subject: [PATCH 1/3] ARM: OMAP: timer: allow gp timer clock-event to be used on both cpus
Date: Fri, 30 Mar 2012 18:57:26 +0530 [thread overview]
Message-ID: <1333114048-26136-2-git-send-email-santosh.shilimkar@ti.com> (raw)
In-Reply-To: <1333114048-26136-1-git-send-email-santosh.shilimkar@ti.com>
For coupled cpuidle to work when both cpus are active, it needs a global timer
that can handle events for both cpus. This timer is used as the broadcast
clock-event when the per-cpu timer hardware stop in low power states.
Set the cpumask of clockevent_gpt to all cpus, set the rating correctly, and
set the irq to allow the clockevent core to determine the affinity of the
timer.
Signed-off-by: Colin Cross <ccross@android.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
---
arch/arm/mach-omap2/timer.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c
index fc73567..e33f9c4 100644
--- a/arch/arm/mach-omap2/timer.c
+++ b/arch/arm/mach-omap2/timer.c
@@ -135,6 +135,7 @@ static struct clock_event_device clockevent_gpt = {
.name = "gp timer",
.features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT,
.shift = 32,
+ .rating = 300,
.set_next_event = omap2_gp_timer_set_next_event,
.set_mode = omap2_gp_timer_set_mode,
};
@@ -225,7 +226,8 @@ static void __init omap2_gp_clockevent_init(int gptimer_id,
clockevent_delta2ns(3, &clockevent_gpt);
/* Timer internal resynch latency. */
- clockevent_gpt.cpumask = cpumask_of(0);
+ clockevent_gpt.cpumask = cpu_all_mask;
+ clockevent_gpt.irq = omap_dm_timer_get_irq(&clkev);
clockevents_register_device(&clockevent_gpt);
pr_info("OMAP clockevent source: GPTIMER%d at %lu Hz\n",
--
1.7.5.4
next prev parent reply other threads:[~2012-03-30 13:27 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-30 13:27 [PATCH 0/3] OMAP4: CPUidle: Add coupled idle support Santosh Shilimkar
2012-03-30 13:27 ` Santosh Shilimkar [this message]
2012-08-03 7:16 ` [PATCH 1/3] ARM: OMAP: timer: allow gp timer clock-event to be used on both cpus Daniel Mack
2012-08-03 7:21 ` Koen Kooi
2012-08-03 8:30 ` Koen Kooi
2012-08-03 9:27 ` Shilimkar, Santosh
2012-08-03 9:33 ` Koen Kooi
2012-08-03 9:42 ` Hiremath, Vaibhav
2012-08-03 9:48 ` Shilimkar, Santosh
2012-08-03 10:32 ` Hiremath, Vaibhav
2012-08-03 10:33 ` Shilimkar, Santosh
2012-08-03 10:04 ` Koen Kooi
2012-08-03 10:14 ` Shilimkar, Santosh
2012-08-03 10:34 ` Hiremath, Vaibhav
2012-08-07 6:50 ` Tony Lindgren
2012-08-03 10:23 ` Hiremath, Vaibhav
2012-08-03 8:22 ` Hiremath, Vaibhav
2012-03-30 13:27 ` [PATCH 2/3] ARM: OMAP4: cpuidle: Use coupled cpuidle states to implement SMP cpuidle Santosh Shilimkar
2012-03-30 19:43 ` Colin Cross
2012-03-31 6:37 ` Shilimkar, Santosh
2012-03-30 13:27 ` [PATCH 3/3] ARM: OMAP4: CPUidle: add synchronization for coupled idle states Santosh Shilimkar
2012-04-03 5:04 ` [PATCH 0/3] OMAP4: CPUidle: Add coupled idle support Kevin Hilman
2012-04-03 15:06 ` Santosh Shilimkar
2012-04-09 6:54 ` Santosh Shilimkar
2012-04-17 10:23 ` Shilimkar, Santosh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1333114048-26136-2-git-send-email-santosh.shilimkar@ti.com \
--to=santosh.shilimkar@ti.com \
--cc=ccross@android.com \
--cc=khilman@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-omap@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).