From patchwork Wed May 4 15:18:08 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Auger X-Patchwork-Id: 9015921 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id A0383BF29F for ; Wed, 4 May 2016 15:20:40 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C36F7203AB for ; Wed, 4 May 2016 15:20:39 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id EC2C220397 for ; Wed, 4 May 2016 15:20:38 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1axyZy-0000Iw-RW; Wed, 04 May 2016 15:19:10 +0000 Received: from mail-wm0-x232.google.com ([2a00:1450:400c:c09::232]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1axyZd-0000A6-9s for linux-arm-kernel@lists.infradead.org; Wed, 04 May 2016 15:18:50 +0000 Received: by mail-wm0-x232.google.com with SMTP id a17so100408481wme.0 for ; Wed, 04 May 2016 08:18:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=zB2wDg59XNtH3PXzpfR+aImbEOn4ilYrFwkpOh2hE6g=; b=H+giIxXigfKMvCBczUZv6LFC3+vT7p+fGfVXX6qLcGscWb3jWI5FqJK6u6VSmcWfHd 1gnCw0DWgwCdMseYmaq4NPbPGfvEldDk27X1WDF1NCyhpxQ/F6N5KPfPOU7LF+9ntSY3 guEpwZ+Aqvt9RhK9NVaRQkWQQDrBe/MYoRsPE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=zB2wDg59XNtH3PXzpfR+aImbEOn4ilYrFwkpOh2hE6g=; b=NYUGLKDieB1Il08iO4nCKIqduYybsZBuYlKjRrLhuaJO6DGS0ckHvRIYRXIS8WNmUj gkTFNpfBnXG+ER0KjvXysGUfkww4k2E4S3mN0/Xo+3MyzZALdM5b3wps5bGIOAz3/QML CYO5jBOjYe1NB48t7fNFT0vrvvyRKJXQyszKmEQGV0eSzfbR6mAhGkrJcwwT2OiH74zr GUnu/iHbPk+rSjYETLFRXrIjtDKT5FRyBpJ41+YDG4PZW93IJJTkjHlr2ZmRJEmRTJNB eD7/fhG+h/Awqw8AJPbhH5PRqGT+GBoH91ZRGuePQt/nlApqkDFbt7pe9t7uAZEe/VRV f/zg== X-Gm-Message-State: AOPr4FVQ8jGR5dgiuJKbh9Ro55DJtTfWqGedb0VkbKHp+o6081qHYTS4ssGpFt+6KmfmCPbZ X-Received: by 10.28.230.69 with SMTP id d66mr31965441wmh.73.1462375107565; Wed, 04 May 2016 08:18:27 -0700 (PDT) Received: from new-host-57.home (LMontsouris-657-1-37-90.w80-11.abo.wanadoo.fr. [80.11.198.90]) by smtp.gmail.com with ESMTPSA id c4sm4773821wjm.24.2016.05.04.08.18.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 04 May 2016 08:18:26 -0700 (PDT) From: Eric Auger To: eric.auger@st.com, eric.auger@linaro.org, robin.murphy@arm.com, alex.williamson@redhat.com, will.deacon@arm.com, joro@8bytes.org, tglx@linutronix.de, jason@lakedaemon.net, marc.zyngier@arm.com, christoffer.dall@linaro.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v9 2/8] irqchip/gic-v3-its: ITS advertises MSI_FLAG_IRQ_REMAPPING Date: Wed, 4 May 2016 15:18:08 +0000 Message-Id: <1462375094-2390-3-git-send-email-eric.auger@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1462375094-2390-1-git-send-email-eric.auger@linaro.org> References: <1462375094-2390-1-git-send-email-eric.auger@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160504_081849_620211_EE00D81D X-CRM114-Status: GOOD ( 13.11 ) X-Spam-Score: -2.7 (--) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: julien.grall@arm.com, patches@linaro.org, Jean-Philippe.Brucker@arm.com, p.fedin@samsung.com, linux-kernel@vger.kernel.org, Bharat.Bhushan@freescale.com, iommu@lists.linux-foundation.org, pranav.sawargaonkar@gmail.com, yehuday@marvell.com MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-6.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The ITS is the first ARM MSI controller advertising the new MSI_FLAG_IRQ_REMAPPING flag. It does so because it supports interrupt translation service. This HW support offers isolation of MSIs, feature used when using KVM device passthrough. Signed-off-by: Eric Auger --- v5: new --- drivers/irqchip/irq-gic-v3-its-pci-msi.c | 3 ++- drivers/irqchip/irq-gic-v3-its-platform-msi.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/irqchip/irq-gic-v3-its-pci-msi.c b/drivers/irqchip/irq-gic-v3-its-pci-msi.c index aee60ed..8223765 100644 --- a/drivers/irqchip/irq-gic-v3-its-pci-msi.c +++ b/drivers/irqchip/irq-gic-v3-its-pci-msi.c @@ -96,7 +96,8 @@ static struct msi_domain_ops its_pci_msi_ops = { static struct msi_domain_info its_pci_msi_domain_info = { .flags = (MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS | - MSI_FLAG_MULTI_PCI_MSI | MSI_FLAG_PCI_MSIX), + MSI_FLAG_MULTI_PCI_MSI | MSI_FLAG_PCI_MSIX | + MSI_FLAG_IRQ_REMAPPING), .ops = &its_pci_msi_ops, .chip = &its_msi_irq_chip, }; diff --git a/drivers/irqchip/irq-gic-v3-its-platform-msi.c b/drivers/irqchip/irq-gic-v3-its-platform-msi.c index 470b4aa..8c0d69d 100644 --- a/drivers/irqchip/irq-gic-v3-its-platform-msi.c +++ b/drivers/irqchip/irq-gic-v3-its-platform-msi.c @@ -63,7 +63,8 @@ static struct msi_domain_ops its_pmsi_ops = { }; static struct msi_domain_info its_pmsi_domain_info = { - .flags = (MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS), + .flags = (MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS | + MSI_FLAG_IRQ_REMAPPING), .ops = &its_pmsi_ops, .chip = &its_pmsi_irq_chip, };