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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 18 Oct 2009 17:18:08 +0900
From:	Jeremy Fitzhardinge <jeremy@...p.org>
To:	john stultz <johnstul@...ibm.com>
CC:	Dan Magenheimer <dan.magenheimer@...cle.com>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Xen-devel <xen-devel@...ts.xensource.com>,
	kurt.hackel@...cle.com, arch/x86 maintainers <x86@...nel.org>,
	Glauber de Oliveira Costa <gcosta@...hat.com>,
	Avi Kivity <avi@...hat.com>, chris.mason@...cle.com
Subject: Re: [Xen-devel] [PATCH 05/12] xen/pvclock: add monotonicity check

On 10/17/09 02:58, john stultz wrote:
>> (I can think of plenty of ways of doing it incorrectly, where you'd get
>> apparent non-monotonicity regardless of the quality of the time source.)
>>     
> There's been some interesting talk of creating a more offset-robust TSC
> clocksource using a per-cpu TSC offsets synced periodically against a
> global counter like the HPET.  It seems like it could work, but there
> are a lot of edge cases and it really has to be right all of the time,
> so I don't think its quite as trivial as some folks have thought. But it
> would be interesting to see!
>   

Xen and KVM do this already.  The host system provides the tsc rate and
offset information for each cpu so that the guest kernel can compute a
global system time (ns since boot) from the tsc.

I suspect its quite difficult to guarantee that you get completely
monotonic results if the tscs are at different rates, but if they're the
same rate but merely offset it should give completely OK results.

    J
--
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