From owner-freebsd-hackers@freebsd.org Fri Oct 30 15:50:24 2015 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1E7ABA20AEB for ; Fri, 30 Oct 2015 15:50:24 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 65DE112D9; Fri, 30 Oct 2015 15:50:22 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id RAA18038; Fri, 30 Oct 2015 17:50:19 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1ZsBwZ-000M5w-01; Fri, 30 Oct 2015 17:50:19 +0200 Subject: Re: instability of timekeeping To: Adrian Chadd References: <56261398.60102@FreeBSD.org> <56261FE6.90302@FreeBSD.org> <56274FFC.2000608@FreeBSD.org> <20151021184850.GX2257@kib.kiev.ua> <562F3E2F.2010100@FreeBSD.org> <20151027115810.GU2257@kib.kiev.ua> <562F8109.4050203@FreeBSD.org> <20151027140403.GB2257@kib.kiev.ua> <5630FC3B.2070908@FreeBSD.org> <5631FB66.4000007@FreeBSD.org> <56329E11.1070102@FreeBSD.org> Cc: Konstantin Belousov , Alexander Motin , freebsd-hackers , Poul-Henning Kamp , Jung-uk Kim From: Andriy Gapon X-Enigmail-Draft-Status: N1110 Message-ID: <56339196.3060304@FreeBSD.org> Date: Fri, 30 Oct 2015 17:49:42 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Oct 2015 15:50:24 -0000 On 30/10/2015 15:22, Adrian Chadd wrote: > Hm! > > are you able to come up with a sane way to check whether it does C1E > the silly way (eg that MSR on that particular platform) so we can > print/disable it? > > That way noone else has this same problem. Well, even the silly way can work correctly. I believe that this particular BIOS had a bug, but there are many vendors and versions out there. It might still make sense to print a warning. It should be as easy as checking bit AMDK8_SMIONCMPHALT in MSR_AMDK8_IPM, see sys/x86/x86/cpu_machdep.c. -- Andriy Gapon