]> git.ipfire.org Git - ipfire-2.x.git/blame - src/patches/suse-2.6.27.39/patches.arch/x86-mce-use-round_jiffies-instead-round_jiffies_relative
Imported linux-2.6.27.39 suse/xen patches.
[ipfire-2.x.git] / src / patches / suse-2.6.27.39 / patches.arch / x86-mce-use-round_jiffies-instead-round_jiffies_relative
CommitLineData
2cb7cef9
BS
1From: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
2Date: Wed, 11 Mar 2009 01:14:26 +0000 (+0900)
3Subject: x86, mce: use round_jiffies() instead round_jiffies_relative()
4Patch-mainline: 2.6.30-rc3
5Git-commit: 5490fa96735ce0e2af270c0868987d644b9a38ec
6References: bnc#507557
7
8x86, mce: use round_jiffies() instead round_jiffies_relative()
9
10Impact: saving power _very_ little
11
12round_jiffies() round up absolute jiffies to full second.
13round_jiffies_relative() round up relative jiffies to full second.
14
15The "t->expires" is absolute jiffies. Then, round_jiffies() should be
16used instead round_jiffies_relative().
17
18Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
19Cc: Andi Kleen <andi@firstfloor.org>
20Cc: H. Peter Anvin <hpa@linux.intel.com>
21Signed-off-by: H. Peter Anvin <hpa@zytor.com>
22Acked-by: Jeff Mahoney <jeffm@suse.com>
23
24---
25 arch/x86/kernel/cpu/mcheck/mce_64.c | 4 ++--
26 1 file changed, 2 insertions(+), 2 deletions(-)
27
28--- a/arch/x86/kernel/cpu/mcheck/mce_64.c
29+++ b/arch/x86/kernel/cpu/mcheck/mce_64.c
30@@ -509,7 +509,7 @@ static void mce_init_timer(void)
31 if (!next_interval)
32 return;
33 setup_timer(t, mcheck_timer, smp_processor_id());
34- t->expires = round_jiffies_relative(jiffies + next_interval);
35+ t->expires = round_jiffies(jiffies + next_interval);
36 add_timer(t);
37 }
38
39@@ -912,7 +912,7 @@ static int __cpuinit mce_cpu_callback(st
40 break;
41 case CPU_DOWN_FAILED:
42 case CPU_DOWN_FAILED_FROZEN:
43- t->expires = round_jiffies_relative(jiffies + next_interval);
44+ t->expires = round_jiffies(jiffies + next_interval);
45 add_timer_on(t, cpu);
46 break;
47 }