From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [Android-virt] [PATCH v5 05/13] ARM: KVM: Inject IRQs and FIQs from userspace Date: Mon, 12 Dec 2011 19:40:38 +0200 Message-ID: <4EE63C96.9000602@redhat.com> References: <20111211102403.21693.6887.stgit@localhost> <20111211102449.21693.12265.stgit@localhost> <4EE4C9D8.1010601@web.de> <-4744042178058961854@unknownmsgid> <4EE53663.2050808@web.de> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: Jan Kiszka , Christoffer Dall , "kvm@vger.kernel.org" , "Marc.Zyngier@arm.com" , "android-virt@lists.cs.columbia.edu" , "tech@virtualopensystems.com" To: Peter Maydell Return-path: Received: from mx1.redhat.com ([209.132.183.28]:58071 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751547Ab1LLRky (ORCPT ); Mon, 12 Dec 2011 12:40:54 -0500 In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: On 12/12/2011 06:31 PM, Peter Maydell wrote: > On 11 December 2011 23:01, Jan Kiszka wrote: > > Enabling in-kernel irqchips usually means "switching worlds". So the > > semantics of these particular IRQ inject interface details may change > > without breaking anything. > > > > However, things might look different if there will be a need to inject > > also the CPU IRQs directly, not only the irqchip inputs. In that case, > > it may make some sense to reserve more space for interrupt types than > > just one bit and use a common encoding scheme. > > I think with an in-kernel GIC model you'd only need to be able to set > one of the (256 including internal-to-the-CPU inputs) GIC input lines; > the GIC itself then connects directly to the vcpu IRQ and FIQ. > > So we could just have different semantics for the ioctl in the 'kernel > GIC model enabled' config, as you suggest. btw, since we use the KVM_IRQ_LINE ioctl, it may make sense to require KVM_CREATE_IRQCHIP. To create a kernel GIC model, just call KVM_CREATE_IRQCHIP with a different parameter. This removes an "except for ARM" from the documentation. -- error compiling committee.c: too many arguments to function