aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/mfgpt_32.c
diff options
context:
space:
mode:
authorJordan Crouse <jordan.crouse@amd.com>2008-02-09 17:24:08 -0500
committerThomas Gleixner <tglx@linutronix.de>2008-02-09 17:24:08 -0500
commitdcee77be2f0a7010633fb2c025db38550c4b0e72 (patch)
treec1a59caa0687dcc32f67c83b22a83ce86d8d0afb /arch/x86/kernel/mfgpt_32.c
parentf54ae69bafa16434ce46bc2f1fe556bce4d23650 (diff)
x86: GEODE: make sure the right MFGPT timer fired the timer tick
Each AMD Geode MFGPT timer interrupt output is paired with another timer; esentially the interrupt goes if either timer fires. This is okay, but the handlers need to be aware of this. Make sure in the timer tick handler that our timer really did expire. Signed-off-by: Jordan Crouse <jordan.crouse@amd.com> Signed-off-by: Andres Salomon <dilinger@debian.org> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel/mfgpt_32.c')
-rw-r--r--arch/x86/kernel/mfgpt_32.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/x86/kernel/mfgpt_32.c b/arch/x86/kernel/mfgpt_32.c
index 81aa9db01f5f..eeb461f391a0 100644
--- a/arch/x86/kernel/mfgpt_32.c
+++ b/arch/x86/kernel/mfgpt_32.c
@@ -293,10 +293,14 @@ static int mfgpt_next_event(unsigned long delta, struct clock_event_device *evt)
293 return 0; 293 return 0;
294} 294}
295 295
296/* Assume (foolishly?), that this interrupt was due to our tick */
297
298static irqreturn_t mfgpt_tick(int irq, void *dev_id) 296static irqreturn_t mfgpt_tick(int irq, void *dev_id)
299{ 297{
298 u16 val = geode_mfgpt_read(mfgpt_event_clock, MFGPT_REG_SETUP);
299
300 /* See if the interrupt was for us */
301 if (!(val & (MFGPT_SETUP_SETUP | MFGPT_SETUP_CMP2 | MFGPT_SETUP_CMP1)))
302 return IRQ_NONE;
303
300 /* Turn off the clock (and clear the event) */ 304 /* Turn off the clock (and clear the event) */
301 mfgpt_disable_timer(mfgpt_event_clock); 305 mfgpt_disable_timer(mfgpt_event_clock);
302 306