From patchwork Mon Dec 5 18:25:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: tip-bot2 for Thomas Gleixner X-Patchwork-Id: 29838 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2409111wrr; Mon, 5 Dec 2022 10:27:35 -0800 (PST) X-Google-Smtp-Source: AA0mqf6ngEsH52QiPeZp5hF1N3jsTAMvGrrU8KjKI6tZK28YwmPZJWltL8TK+XJd58ehbLXAv428 X-Received: by 2002:a17:906:ce2b:b0:7c0:cc7e:c783 with SMTP id sd11-20020a170906ce2b00b007c0cc7ec783mr11205418ejb.133.1670264855268; Mon, 05 Dec 2022 10:27:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670264855; cv=none; d=google.com; s=arc-20160816; b=Fp1/tl+VC0yMaUS2vFfv7lIE0PGQflBICwGyWdBgk64eFBn2Lt2QIUGVAoZZ0Qv2E5 c3n5klLjU/1WdP633mmgxLgQ+7OLIuyx8hDT6N77h0cww2WSk1Hlty4BeVn4429MhEQT WIMNooWEdC901VzxQGb5rjmB+Y8PeUVnVIR/pW2/EQplYKQec+bOdBmwcKwrhVxQ3ebw x1r8OaMr2hrTpjbjVbRqPpoVjk+tu3av7vlTabheFY0qtiEV55RXcEZuFBUAbTZAW4bg fO7eYP0HoaB7RaDzXu2hNLMQR7iOe/N3w4fVB7SjSHQL1HSUkEmheVtV9+wTreQ4zxJS QjVQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=qtKHZ74nPCKhwCfX/AIwrExnVYjr6fc6kAlNCjlmqnk=; b=ARolxtTq1ZO98azrYaVT6Z3VCyUNm/ZAgumimsKKIA+xWkBRvRY62INjEUiu5IpMV8 8f+2qjH7kKCTGWuiZN2QGEJ+im+joXzlmmJopBrDKExPQJHIZVDdM46TXNTtzm9HPnMF wRjvMnoJ4dhSGbwR434aAux1n8zn24TMcbgq171aVJKtPfY32+WskGesUgo/AmuKdSbA eRCZnhz4033no1KMizWxNsXmvXStoxUgmtlubm+hq6YKXkEjymqOykW5W1D5kRDh47vU JIxurCoKdW+6u04ceXQIcpU59KkPnE4uZQKmzv2E0kO4E3k2Cq+AX4615eUhfgIOaMRm 2/pQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b="CVB/uqRJ"; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hv18-20020a17090760d200b007adac36e031si13585263ejc.442.2022.12.05.10.27.10; Mon, 05 Dec 2022 10:27:35 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b="CVB/uqRJ"; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233290AbiLES03 (ORCPT + 99 others); Mon, 5 Dec 2022 13:26:29 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39118 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232120AbiLESZS (ORCPT ); Mon, 5 Dec 2022 13:25:18 -0500 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3649A209A5; Mon, 5 Dec 2022 10:25:17 -0800 (PST) Date: Mon, 05 Dec 2022 18:25:13 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1670264713; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qtKHZ74nPCKhwCfX/AIwrExnVYjr6fc6kAlNCjlmqnk=; b=CVB/uqRJXb/3w27cQKUTzudgFgCJ6nNoVagJtTaZAY9Qq5RNIYZt74JVqQajKo+V4HmWMg mHuUHG7gcI2hSPG8L4HgZIbnSQQXFd/pNcubx1BDE4Awl6Io4lxto0LkzfN96mV1aOWzia r1AjyfoJRYj3iTdi/lfHVqjn4GO/Q8YC/PkbbgpZyWahLfF/RP+CmSb/99jIekg/MfjkWu dsTdBigeEOCzLwmUWdHQGFezGcFTttkPiQPOeHWEaADKtaxb35xFlsQ28FRh6qwIn0XYaS hKWUS4hOK8HlqkR7uDCa4fITKD6CqWd/PSs9aUlTXKagBHy1opGU2rydwv9/5Q== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1670264713; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qtKHZ74nPCKhwCfX/AIwrExnVYjr6fc6kAlNCjlmqnk=; b=nhbQxHaCRMrNEkGmN7OIk8p3XDMH/KCHPVpWcISA9IOMaHzeGHkya4ylw57KCjWKzLyFjo gDB/QvDUJ8rJPEDw== From: "tip-bot2 for Thomas Gleixner" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: irq/core] x86/apic/msi: Remove arch_create_remap_msi_irq_domain() Cc: Thomas Gleixner , Kevin Tian , Marc Zyngier , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20221124232326.267353814@linutronix.de> References: <20221124232326.267353814@linutronix.de> MIME-Version: 1.0 Message-ID: <167026471361.4906.8042825607190869798.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750422294254216103?= X-GMAIL-MSGID: =?utf-8?q?1751399640669964345?= The following commit has been merged into the irq/core branch of tip: Commit-ID: 3d81f920bf95dbf2911a87b9ca7e0167525ea325 Gitweb: https://git.kernel.org/tip/3d81f920bf95dbf2911a87b9ca7e0167525ea325 Author: Thomas Gleixner AuthorDate: Fri, 25 Nov 2022 00:26:12 +01:00 Committer: Thomas Gleixner CommitterDate: Mon, 05 Dec 2022 19:21:03 +01:00 x86/apic/msi: Remove arch_create_remap_msi_irq_domain() and related code which is not longer required now that the interrupt remap code has been converted to MSI parent domains. Signed-off-by: Thomas Gleixner Reviewed-by: Kevin Tian Acked-by: Marc Zyngier Link: https://lore.kernel.org/r/20221124232326.267353814@linutronix.de --- arch/x86/include/asm/irq_remapping.h | 4 +--- arch/x86/kernel/apic/msi.c | 42 +--------------------------- 2 files changed, 1 insertion(+), 45 deletions(-) diff --git a/arch/x86/include/asm/irq_remapping.h b/arch/x86/include/asm/irq_remapping.h index 7cc4943..7a2ed15 100644 --- a/arch/x86/include/asm/irq_remapping.h +++ b/arch/x86/include/asm/irq_remapping.h @@ -44,10 +44,6 @@ extern int irq_remapping_reenable(int); extern int irq_remap_enable_fault_handling(void); extern void panic_if_irq_remap(const char *msg); -/* Create PCI MSI/MSIx irqdomain, use @parent as the parent irqdomain. */ -extern struct irq_domain * -arch_create_remap_msi_irq_domain(struct irq_domain *par, const char *n, int id); - /* Get parent irqdomain for interrupt remapping irqdomain */ static inline struct irq_domain *arch_get_ir_parent_domain(void) { diff --git a/arch/x86/kernel/apic/msi.c b/arch/x86/kernel/apic/msi.c index d198da3..682f51a 100644 --- a/arch/x86/kernel/apic/msi.c +++ b/arch/x86/kernel/apic/msi.c @@ -277,7 +277,7 @@ void __init x86_create_pci_msi_domain(void) x86_pci_msi_default_domain = x86_init.irqs.create_pci_msi_domain(); } -/* Keep around for hyperV and the remap code below */ +/* Keep around for hyperV */ int pci_msi_prepare(struct irq_domain *domain, struct device *dev, int nvec, msi_alloc_info_t *arg) { @@ -291,46 +291,6 @@ int pci_msi_prepare(struct irq_domain *domain, struct device *dev, int nvec, } EXPORT_SYMBOL_GPL(pci_msi_prepare); -#ifdef CONFIG_IRQ_REMAP -static struct msi_domain_ops pci_msi_domain_ops = { - .msi_prepare = pci_msi_prepare, -}; - -static struct irq_chip pci_msi_ir_controller = { - .name = "IR-PCI-MSI", - .irq_unmask = pci_msi_unmask_irq, - .irq_mask = pci_msi_mask_irq, - .irq_ack = irq_chip_ack_parent, - .irq_retrigger = irq_chip_retrigger_hierarchy, - .flags = IRQCHIP_SKIP_SET_WAKE | - IRQCHIP_AFFINITY_PRE_STARTUP, -}; - -static struct msi_domain_info pci_msi_ir_domain_info = { - .flags = MSI_FLAG_USE_DEF_DOM_OPS | MSI_FLAG_USE_DEF_CHIP_OPS | - MSI_FLAG_MULTI_PCI_MSI | MSI_FLAG_PCI_MSIX, - .ops = &pci_msi_domain_ops, - .chip = &pci_msi_ir_controller, - .handler = handle_edge_irq, - .handler_name = "edge", -}; - -struct irq_domain *arch_create_remap_msi_irq_domain(struct irq_domain *parent, - const char *name, int id) -{ - struct fwnode_handle *fn; - struct irq_domain *d; - - fn = irq_domain_alloc_named_id_fwnode(name, id); - if (!fn) - return NULL; - d = pci_msi_create_irq_domain(fn, &pci_msi_ir_domain_info, parent); - if (!d) - irq_domain_free_fwnode(fn); - return d; -} -#endif - #ifdef CONFIG_DMAR_TABLE /* * The Intel IOMMU (ab)uses the high bits of the MSI address to contain the