From c7209ef971ab25b28e0fb271fcd8f770005b198c Mon Sep 17 00:00:00 2001 From: Dave Jones Date: Mon, 23 Aug 2004 21:30:50 -0700 Subject: [PATCH] [PATCH] x86: quieten the "ESR value" printks Only print out the ESR value if it changes after enabling vector. Signed-off-by: Dave Jones Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- arch/i386/kernel/apic.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/i386/kernel/apic.c b/arch/i386/kernel/apic.c index 607da069d372e..32d4b331fe714 100644 --- a/arch/i386/kernel/apic.c +++ b/arch/i386/kernel/apic.c @@ -343,7 +343,7 @@ void __init init_bsp_APIC(void) void __init setup_local_APIC (void) { - unsigned long value, ver, maxlvt; + unsigned long oldvalue, value, ver, maxlvt; /* Pound the ESR really hard over the head with a big hammer - mbligh */ if (esr_disable) { @@ -459,9 +459,7 @@ void __init setup_local_APIC (void) maxlvt = get_maxlvt(); if (maxlvt > 3) /* Due to the Pentium erratum 3AP. */ apic_write(APIC_ESR, 0); - value = apic_read(APIC_ESR); - apic_printk(APIC_VERBOSE, "ESR value before enabling vector:" - " %08lx\n", value); + oldvalue = apic_read(APIC_ESR); value = ERROR_APIC_VECTOR; // enables sending errors apic_write_around(APIC_LVTERR, value); @@ -471,8 +469,10 @@ void __init setup_local_APIC (void) if (maxlvt > 3) apic_write(APIC_ESR, 0); value = apic_read(APIC_ESR); - apic_printk(APIC_VERBOSE, "ESR value after enabling vector:" - " %08lx\n", value); + if (value != oldvalue) + apic_printk(APIC_VERBOSE, "ESR value before enabling " + "vector: 0x%08lx after: 0x%08lx\n", + oldvalue, value); } else { if (esr_disable) /* -- 2.53.0