From: Keir Fraser Subject: Re: [PATCH] x86 hvm: freeze PIT/LAPIC timer emulation while its IRQ is masked Date: Thu, 10 Sep 2009 07:49:04 +0100 Message-ID: References: <7khbvb73lz.fsf@pingu.sky.yk.fujitsu.co.jp> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <7khbvb73lz.fsf@pingu.sky.yk.fujitsu.co.jp> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Kouya Shimura , "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org Although I can see the sense here, the patch makes me a bit uneasy. Also I think neater code would result from simply making vpt.c's handling of periodic timers less stupid. By this I mean that calling set_timer() from the timer handler is not really necessary -- you already know an interrupt is now pending and the vcpu is kicked. May as well not set_timer() until the pending interrupt(s) are delivered. That would then effectively get your optimisation "for free", wouldn't it? -- Keir On 10/09/2009 06:47, "Kouya Shimura" wrote: > Hi, > > I've found that modern windows OS never use the PIT timer, > and neither cpu#0's LAPIC timer after boot. > Despite that, xen emulates them busily. It's inefficient. > > Note: this patch ignores the IRQ mask of legacy i8259 since > rombios frequently modifies it. > > Thanks, > Kouya > > Signed-off-by: Kouya Shimura >