From 7c2f489ce669a9f7d068a5904ed7958af523dc89 Mon Sep 17 00:00:00 2001 From: Shai Fultheim Date: Fri, 20 Apr 2012 01:12:32 +0300 Subject: [PATCH] --- yaml --- r: 305015 b: refs/heads/master c: 42fa4250436304d4650fa271f37671f6cee24e08 h: refs/heads/master i: 305013: b5094f86d70b9c9b64d5623e925b88cffd48b65a 305011: 2cf171afc3bcc903bc8334d579cd1c60a7a32f26 305007: b2eaf47669c7d912e0dca5771dcf7d2e830bd075 v: v3 --- [refs] | 2 +- trunk/arch/x86/kernel/apic/apic.c | 12 +++++++----- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/[refs] b/[refs] index cac6b0de2b9b..a2263d1b6417 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 22042c086c1b6814b9f3ecf2720f6280bede9c47 +refs/heads/master: 42fa4250436304d4650fa271f37671f6cee24e08 diff --git a/trunk/arch/x86/kernel/apic/apic.c b/trunk/arch/x86/kernel/apic/apic.c index edc24480469f..3beab627190e 100644 --- a/trunk/arch/x86/kernel/apic/apic.c +++ b/trunk/arch/x86/kernel/apic/apic.c @@ -1325,11 +1325,13 @@ void __cpuinit setup_local_APIC(void) acked); break; } - if (cpu_has_tsc) { - rdtscll(ntsc); - max_loops = (cpu_khz << 10) - (ntsc - tsc); - } else - max_loops--; + if (queued) { + if (cpu_has_tsc) { + rdtscll(ntsc); + max_loops = (cpu_khz << 10) - (ntsc - tsc); + } else + max_loops--; + } } while (queued && max_loops > 0); WARN_ON(max_loops <= 0);