From patchwork Thu Sep 26 06:18:47 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Kardashevskiy X-Patchwork-Id: 278125 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 0B6662C00BB for ; Thu, 26 Sep 2013 16:47:02 +1000 (EST) Received: from localhost ([::1]:56397 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VP513-0003eb-69 for incoming@patchwork.ozlabs.org; Thu, 26 Sep 2013 02:25:33 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44794) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VP4vD-0001h2-6x for qemu-devel@nongnu.org; Thu, 26 Sep 2013 02:19:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VP4us-000875-Lx for qemu-devel@nongnu.org; Thu, 26 Sep 2013 02:19:31 -0400 Received: from e23smtp02.au.ibm.com ([202.81.31.144]:40051) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VP4us-00086G-2d for qemu-devel@nongnu.org; Thu, 26 Sep 2013 02:19:10 -0400 Received: from /spool/local by e23smtp02.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 26 Sep 2013 16:19:04 +1000 Received: from d23dlp03.au.ibm.com (202.81.31.214) by e23smtp02.au.ibm.com (202.81.31.208) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Thu, 26 Sep 2013 16:19:02 +1000 Received: from d23relay05.au.ibm.com (d23relay05.au.ibm.com [9.190.235.152]) by d23dlp03.au.ibm.com (Postfix) with ESMTP id C6C873578055; Thu, 26 Sep 2013 16:19:01 +1000 (EST) Received: from d23av01.au.ibm.com (d23av01.au.ibm.com [9.190.234.96]) by d23relay05.au.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r8Q62Csm60031010; Thu, 26 Sep 2013 16:02:12 +1000 Received: from d23av01.au.ibm.com (localhost [127.0.0.1]) by d23av01.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id r8Q6J1eX005740; Thu, 26 Sep 2013 16:19:01 +1000 Received: from ozlabs.au.ibm.com (ozlabs.au.ibm.com [9.190.163.12]) by d23av01.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id r8Q6J13J005723; Thu, 26 Sep 2013 16:19:01 +1000 Received: from bran.ozlabs.ibm.com (haven.au.ibm.com [9.190.164.82]) by ozlabs.au.ibm.com (Postfix) with ESMTP id D8F7EA01C5; Thu, 26 Sep 2013 16:19:00 +1000 (EST) Received: from ka1.ozlabs.ibm.com (ka1.ozlabs.ibm.com [10.61.145.11]) by bran.ozlabs.ibm.com (Postfix) with ESMTP id 84FC116ABBA; Thu, 26 Sep 2013 16:19:00 +1000 (EST) From: Alexey Kardashevskiy To: qemu-devel@nongnu.org Date: Thu, 26 Sep 2013 16:18:47 +1000 Message-Id: <1380176328-21320-14-git-send-email-aik@ozlabs.ru> X-Mailer: git-send-email 1.8.4.rc4 In-Reply-To: <1380176328-21320-1-git-send-email-aik@ozlabs.ru> References: <1380176328-21320-1-git-send-email-aik@ozlabs.ru> X-TM-AS-MML: No X-Content-Scanned: Fidelis XPS MAILER x-cbid: 13092606-5490-0000-0000-00000436FB0B X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 202.81.31.144 Cc: Alexey Kardashevskiy , qemu-ppc@nongnu.org, Alexander Graf , Anthony Liguori , David Gibson Subject: [Qemu-devel] [PATCH v5 13/14] xics-kvm: enable irqfd for MSI X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org This enables IRQFD support for sPAPR. The feature decreases the latency of interrupt handling. To enable IRQFD for MSI, this sets kvm_gsi_direct_mapping to true which enables direct MSI mapping. To enable IRQFD for LSI (level triggered INTx interrupts), a PCI host bus callback is required. The patch for that is coming next. Signed-off-by: Alexey Kardashevskiy --- hw/intc/xics_kvm.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hw/intc/xics_kvm.c b/hw/intc/xics_kvm.c index a2ccafa..c203646 100644 --- a/hw/intc/xics_kvm.c +++ b/hw/intc/xics_kvm.c @@ -441,6 +441,12 @@ static void xics_kvm_realize(DeviceState *dev, Error **errp) goto fail; } } + + kvm_kernel_irqchip = true; + kvm_irqfds_allowed = true; + kvm_msi_via_irqfd_allowed = true; + kvm_gsi_direct_mapping = true; + return; fail: