From: Thomas Gleixner Subject: Re: [patch 01/12] expose ACPI pmtimer to userspace (/dev/pmtimer) Date: Sun, 1 Jun 2008 20:17:38 +0200 (CEST) Message-ID: References: <20080529222249.563011248@localhost.localdomain> <20080529222828.541115340@localhost.localdomain> <20080601175604.GA3070@dmt> Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: Avi Kivity , Chris Wright , Glauber Costa , Anthony Liguori , kvm@vger.kernel.org, john stultz To: Marcelo Tosatti Return-path: Received: from www.tglx.de ([62.245.132.106]:50399 "EHLO www.tglx.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751340AbYFASTZ (ORCPT ); Sun, 1 Jun 2008 14:19:25 -0400 In-Reply-To: <20080601175604.GA3070@dmt> Sender: kvm-owner@vger.kernel.org List-ID: On Sun, 1 Jun 2008, Marcelo Tosatti wrote: > On Sun, Jun 01, 2008 at 06:34:27PM +0200, Thomas Gleixner wrote: > > A sysfs entry sounds fine and much simpler. Should probably be a generic > clocksource interface (so userspace can read any available clocksource) > rather than acpi_pm specific. Agreed. > > return clocksource_acpi_pm.read == acpi_pm_read; > > > > So we don't need reliable_pmtimer at all. > > For KVM's use case, we'd rather not allow direct pmtimer access if the > host has an unreliable (buggy) chipset. well, "return clocksource_acpi_pm.read == acpi_pm_read;" is supposed to do that just without an additional variable "reliable_pmtimer" :) > But then, I doubt any of those older affected chipsets have HW > virtualization support, so it shouldnt be an issue. It's exactly one old crappy chipset, which definitely has no HW virt support and therefor we just can use read_pmtmr() w/o checking for reliable or not. Thanks, tglx