lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 4 Feb 2010 20:11:12 +0100
From:	Andi Kleen <andi@...stfloor.org>
To:	tglx@...utronix.de, linux-kernel@...r.kernel.org,
	venkatesh.pallipadi@...el.com
Subject: [PATCH] HPET: Drop WARN_ON for mismatch on HPET CMP readback

    HPET: Drop WARN_ON for mismatch on HPET CMP readback
    
    At least one Intel chipset seems to always return a constant value
    when reading back the HPET CMP register. This triggers the WARN_ON_ONCE
    on each boot.
    
    In addition the WARN_ON was buggy: it has a side-effect and
    actually needed code could be optimized out if someone disabled
    CONFIG_BUG.
    
    So far there's no indication that miscompare on reading
    points to actual problem.
    
    So simply drop the WARN_ON_ONCE.
    
    Based on discussions with Thomas Gleixner.
    
    Signed-off-by: Andi Kleen <ak@...ux.intel.com>

diff --git a/arch/x86/kernel/hpet.c b/arch/x86/kernel/hpet.c
index ad80a1c..18cf7a6 100644
--- a/arch/x86/kernel/hpet.c
+++ b/arch/x86/kernel/hpet.c
@@ -394,14 +394,11 @@ static int hpet_next_event(unsigned long delta,
 	 * at that point and we would wait for the next hpet interrupt
 	 * forever. We found out that reading the CMP register back
 	 * forces the transfer so we can rely on the comparison with
-	 * the counter register below. If the read back from the
-	 * compare register does not match the value we programmed
-	 * then we might have a real hardware problem. We can not do
-	 * much about it here, but at least alert the user/admin with
-	 * a prominent warning.
+	 * the counter register below. 
+         * But don't actually check the read-back value. Some Intel chipsets
+	 * return always the same value.
 	 */
-	WARN_ONCE(hpet_readl(HPET_Tn_CMP(timer)) != cnt,
-		  KERN_WARNING "hpet: compare register read back failed.\n");
+	(void)hpet_readl(HPET_Tn_CMP(timer);
 
 	return (s32)(hpet_readl(HPET_COUNTER) - cnt) >= 0 ? -ETIME : 0;
 }
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ