[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <tip-2d0640b47da74cff7c11642c798d40de861ed524@git.kernel.org>
Date: Wed, 19 Jan 2011 19:09:52 GMT
From: tip-bot for Stephen Boyd <sboyd@...eaurora.org>
To: linux-tip-commits@...r.kernel.org
Cc: linux-kernel@...r.kernel.org, hpa@...or.com, mingo@...hat.com,
a.p.zijlstra@...llo.nl, tglx@...utronix.de, sboyd@...eaurora.org,
mingo@...e.hu
Subject: [tip:timers/urgent] hrtimers: Notify hrtimer users of switches to NOHZ mode
Commit-ID: 2d0640b47da74cff7c11642c798d40de861ed524
Gitweb: http://git.kernel.org/tip/2d0640b47da74cff7c11642c798d40de861ed524
Author: Stephen Boyd <sboyd@...eaurora.org>
AuthorDate: Tue, 18 Jan 2011 22:46:34 -0800
Committer: Ingo Molnar <mingo@...e.hu>
CommitDate: Wed, 19 Jan 2011 20:08:15 +0100
hrtimers: Notify hrtimer users of switches to NOHZ mode
When NOHZ=y and high res timers are disabled (via cmdline or
Kconfig) tick_nohz_switch_to_nohz() will notify the user about
switching into NOHZ mode. Nothing is printed for the case where
HIGH_RES_TIMERS=y. Fix this for the HIGH_RES_TIMERS=y case by
duplicating the printk from the low res NOHZ path in the high
res NOHZ path.
This confused me since I was thinking 'dmesg | grep -i NOHZ' would
tell me if NOHZ was enabled, but if I have hrtimers there is
nothing.
Signed-off-by: Stephen Boyd <sboyd@...eaurora.org>
Acked-by: Thomas Gleixner <tglx@...utronix.de>
Cc: Peter Zijlstra <a.p.zijlstra@...llo.nl>
LKML-Reference: <1295419594-13085-1-git-send-email-sboyd@...eaurora.org>
Signed-off-by: Ingo Molnar <mingo@...e.hu>
---
kernel/time/tick-sched.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c
index 3e216e0..c55ea24 100644
--- a/kernel/time/tick-sched.c
+++ b/kernel/time/tick-sched.c
@@ -642,8 +642,7 @@ static void tick_nohz_switch_to_nohz(void)
}
local_irq_enable();
- printk(KERN_INFO "Switched to NOHz mode on CPU #%d\n",
- smp_processor_id());
+ printk(KERN_INFO "Switched to NOHz mode on CPU #%d\n", smp_processor_id());
}
/*
@@ -795,8 +794,10 @@ void tick_setup_sched_timer(void)
}
#ifdef CONFIG_NO_HZ
- if (tick_nohz_enabled)
+ if (tick_nohz_enabled) {
ts->nohz_mode = NOHZ_MODE_HIGHRES;
+ printk(KERN_INFO "Switched to NOHz mode on CPU #%d\n", smp_processor_id());
+ }
#endif
}
#endif /* HIGH_RES_TIMERS */
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists