From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gleb Natapov Subject: Re: [patch 4/8] KVM: x86: replace hrtimer based timer emulation Date: Wed, 8 Jul 2009 19:40:57 +0300 Message-ID: <20090708164057.GT28046@redhat.com> References: <20090706015511.923596553@localhost.localdomain> <20090706015812.786509491@localhost.localdomain> <20090708125819.GM28046@redhat.com> <20090708131721.GA3382@amt.cnet> <20090708162958.GS28046@redhat.com> <20090708163739.GA6867@amt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: kvm@vger.kernel.org To: Marcelo Tosatti Return-path: Received: from mx2.redhat.com ([66.187.237.31]:41337 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754827AbZGHQlA (ORCPT ); Wed, 8 Jul 2009 12:41:00 -0400 Received: from int-mx2.corp.redhat.com (int-mx2.corp.redhat.com [172.16.27.26]) by mx2.redhat.com (8.13.8/8.13.8) with ESMTP id n68GexQt032501 for ; Wed, 8 Jul 2009 12:40:59 -0400 Content-Disposition: inline In-Reply-To: <20090708163739.GA6867@amt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: On Wed, Jul 08, 2009 at 01:37:39PM -0300, Marcelo Tosatti wrote: > On Wed, Jul 08, 2009 at 07:29:58PM +0300, Gleb Natapov wrote: > > On Wed, Jul 08, 2009 at 10:17:21AM -0300, Marcelo Tosatti wrote: > > > (but yes, bypassing the irq injection system its not a very beatiful > > > shortcut, but its done in other places too eg i8254.c NMI injection via > > > all cpus LINT0). > > > > > I've looked at this. Why do you say i8254.c NMI injection bypass the irq > > injection system? It look to me like it uses usual way to send interrupt > > to all cpus. > > It goes through apic_accept_irq so its somewhat fine. But it accesses > the lapics of other vcpus locklessly (which does not happen via > kvm_set_irq path due to irq_lock protection). Ah, that the bug then. But otherwise it goes through usual interrupt logic. Do you know why the lock is missing? Due to potential deadlock or we just forget to lock? -- Gleb.