From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753451AbdFVQwB (ORCPT ); Thu, 22 Jun 2017 12:52:01 -0400 Received: from terminus.zytor.com ([65.50.211.136]:58137 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751434AbdFVQwA (ORCPT ); Thu, 22 Jun 2017 12:52:00 -0400 Date: Thu, 22 Jun 2017 09:46:19 -0700 From: tip-bot for Thomas Gleixner Message-ID: Cc: keith.busch@intel.com, marc.zyngier@arm.com, hch@lst.de, mpe@ellerman.id.au, mingo@kernel.org, hpa@zytor.com, axboe@kernel.dk, linux-kernel@vger.kernel.org, joro@8bytes.org, tglx@linutronix.de, peterz@infradead.org Reply-To: peterz@infradead.org, axboe@kernel.dk, linux-kernel@vger.kernel.org, tglx@linutronix.de, joro@8bytes.org, hpa@zytor.com, mpe@ellerman.id.au, mingo@kernel.org, keith.busch@intel.com, marc.zyngier@arm.com, hch@lst.de In-Reply-To: <20170619235444.142270582@linutronix.de> References: <20170619235444.142270582@linutronix.de> To: linux-tip-commits@vger.kernel.org Subject: [tip:irq/core] iommu/amd: Use named irq domain interface Git-Commit-ID: 3e49a8182277ea57736285aede5f43bfa6aa11b1 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Archived-At: List-Archive: List-Post: Commit-ID: 3e49a8182277ea57736285aede5f43bfa6aa11b1 Gitweb: http://git.kernel.org/tip/3e49a8182277ea57736285aede5f43bfa6aa11b1 Author: Thomas Gleixner AuthorDate: Tue, 20 Jun 2017 01:37:12 +0200 Committer: Thomas Gleixner CommitDate: Thu, 22 Jun 2017 18:21:11 +0200 iommu/amd: Use named irq domain interface Signed-off-by: Thomas Gleixner Acked-by: Joerg Roedel Cc: Jens Axboe Cc: Marc Zyngier Cc: Michael Ellerman Cc: Keith Busch Cc: Peter Zijlstra Cc: iommu@lists.linux-foundation.org Cc: Christoph Hellwig Link: http://lkml.kernel.org/r/20170619235444.142270582@linutronix.de --- drivers/iommu/amd_iommu.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c index 590e1e8..503849d 100644 --- a/drivers/iommu/amd_iommu.c +++ b/drivers/iommu/amd_iommu.c @@ -4395,13 +4395,20 @@ static struct irq_chip amd_ir_chip = { int amd_iommu_create_irq_domain(struct amd_iommu *iommu) { - iommu->ir_domain = irq_domain_add_tree(NULL, &amd_ir_domain_ops, iommu); + struct fwnode_handle *fn; + + fn = irq_domain_alloc_named_id_fwnode("AMD-IR", iommu->index); + if (!fn) + return -ENOMEM; + iommu->ir_domain = irq_domain_create_tree(fn, &amd_ir_domain_ops, iommu); + irq_domain_free_fwnode(fn); if (!iommu->ir_domain) return -ENOMEM; iommu->ir_domain->parent = arch_get_ir_parent_domain(); - iommu->msi_domain = arch_create_msi_irq_domain(iommu->ir_domain); - + iommu->msi_domain = arch_create_remap_msi_irq_domain(iommu->ir_domain, + "AMD-IR-MSI", + iommu->index); return 0; }