From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcelo Tosatti Subject: Re: [PATCH] kvm-ia64 irq assignment 2/2 userspace Date: Wed, 11 Jun 2008 15:58:37 -0300 Message-ID: <20080611185837.GA13245@dmt.cnet> References: <51CFAB8CB6883745AE7B93B3E084EBE201CC8760@pdsmsx412.ccr.corp.intel.com> <20080611165441.GA7926@dmt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Avi Kivity , Jes Sorensen , kvm@vger.kernel.org, kvm-ia64@vger.kernel.org To: "Xu, Anthony" Return-path: Received: from mx1.redhat.com ([66.187.233.31]:40782 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1760895AbYFKTBI (ORCPT ); Wed, 11 Jun 2008 15:01:08 -0400 Content-Disposition: inline In-Reply-To: <20080611165441.GA7926@dmt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: > > @@ -220,6 +232,11 @@ static void piix3_set_irq(qemu_irq *pic, int > > irq_num, int level) > > { > > int i, pic_irq, pic_level; > > > > +#if defined(KVM_CAP_IRQCHIP) && defined(TARGET_IA64) > > + if(kvm_enabled()) > > + kvm_set_irq(irq_num, level); > > + return; > > +#endif > > pci_irq_levels[irq_num] = level; > > Why the current hook into i8259_set_irq does not work for IA64? if (pic_irq < 16) { /* The pic level is the logical OR of all the PCI irqs mapped to it */ Ok, but still, how can you share interrupts by directly changing the level without checking for individual devices first. > I think this breaks interrupt sharing, because the logic to detect if > all devices sharing the line are low or high is in i8259_set_irq, and s/i8259_set_irq/piix3_set_irq/ > you simply skip that.