From patchwork Mon Dec 5 21:41:49 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: 29955 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2487492wrr; Mon, 5 Dec 2022 13:45:00 -0800 (PST) X-Google-Smtp-Source: AA0mqf7gCHVIGH2VjriHxOhKkGzv9Y3SkPg0ExsdrCRp6PkjicDAnbGRPOw6AYzCpzkVoeOU09eZ X-Received: by 2002:a05:6402:1f08:b0:461:d21a:c0f3 with SMTP id b8-20020a0564021f0800b00461d21ac0f3mr44214671edb.71.1670276700088; Mon, 05 Dec 2022 13:45:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670276700; cv=none; d=google.com; s=arc-20160816; b=WyF/q//NwyPf5fEDV6XBysYbu3xz3dx8bD//6hlFMKjyPafCKq2kTVlSYykscqsPMB NadRpqVUXVvEiiWI8T5YAkFPNToYeMwlcF60bTLGza/mLPoVmHgHN1HjRdEg12aXFhR5 XI0ZKf2T+uAecR26Us9fBNC1uiaO4XA0kp0A1ZgUlKtIuJ0MJQGxjIokPl7pTqdMoVOR dFXiL1H+t4Ge/vhZOjBlUXh4uQs2fiOjPJaDAdW87SnooZdo9I0BTT1cHsvJxo+CZ942 AusHG6iJnma4fr7GCi9UvFFN0YJSmJDZpTrnFuSgLCXrTlCI2JT5rB521sZTlyXPOMGY MFdw== 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=MLhMP5Asx5mSCrOl2a/7yOsTV/2KgEfBxWjPjSR9Fsc=; b=Xg1ILvfTVy2F+VI1lPk/epcrcWmWU2FHar712L4Q/pHNynV0RjvnwmckXgJJKhN82K jQSfJEtuiI2Iruloo5p92gu+Z7QU6U3xmJF1ROmbMDh2HpFTiXNCJPeFyOiXPNCLrta9 CfJYUFe7+IjhZkdgq/Uf8KvOgQnMc7lSvcuZXJuqAINpwLaOoIVFgTCX6yMeQvtRxPjk R+eUbBcTeUn0xWMBkYk5IPLKSEMzKQb7I9vWHHcQEZYYatO/oqZAbuLVE6gZ+viVQcmo RljQkB5sRShddHLA0KLAEErcoIQdRX7oRLNpiHLxdfnDFUV6j4rV4aKaaGCsBm1Tmlbc WxNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=KmgZVcNb; dkim=neutral (no key) header.i=@linutronix.de; 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 xg12-20020a170907320c00b007ae5b41855fsi10409744ejb.895.2022.12.05.13.44.34; Mon, 05 Dec 2022 13:45:00 -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=KmgZVcNb; dkim=neutral (no key) header.i=@linutronix.de; 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 S233311AbiLEVnS (ORCPT + 99 others); Mon, 5 Dec 2022 16:43:18 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41046 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233868AbiLEVlz (ORCPT ); Mon, 5 Dec 2022 16:41:55 -0500 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9BC2D2CE00; Mon, 5 Dec 2022 13:41:54 -0800 (PST) Date: Mon, 05 Dec 2022 21:41:49 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1670276509; 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=MLhMP5Asx5mSCrOl2a/7yOsTV/2KgEfBxWjPjSR9Fsc=; b=KmgZVcNbQJY5DGW8wQZ15wZa3ZDOIjAMJ5UKp4wNKB7r0HmsPlqv+JeRXkmTwpOXDwXqCw fZYxVRFsXkyPANMpu0RH/aOWULtiVrQ1r9NaSzAXv6k1FhMT0ivWasAQi6krVEP6OXYF27 BeDdbjMllgAd5QkRX7TdqjFwetmwEyozSBxK31ymYrTBHuRKi1iziCvxJ0luOq8+iESVCj +RGs4V1WWIhfQgub9fIwZyPc4mEkcwKTHYleqdb/txoQfDm0GolTJ+ZtmwQBiCsEUWAm4L 2gwKrMV2LveLAc0vJddUeh84HmZJIY9DDpv8sgls81noaKwhWYMLKqEXLJAaWA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1670276509; 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=MLhMP5Asx5mSCrOl2a/7yOsTV/2KgEfBxWjPjSR9Fsc=; b=dHvKe14zTf/+4TzUqk8cJCWx/y92LL9WsKBCeMQM3BRY/fSqevaW8j91rGYT3YbBoDEjC4 k/6fLILJ8RW+vuBA== 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] genirq/msi: Provide BUS_DEVICE_PCI_MSI[X] Cc: Thomas Gleixner , Kevin Tian , Marc Zyngier , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20221124232325.917219885@linutronix.de> References: <20221124232325.917219885@linutronix.de> MIME-Version: 1.0 Message-ID: <167027650962.4906.16480071733692228693.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?1750422776581462430?= X-GMAIL-MSGID: =?utf-8?q?1751412061035092217?= The following commit has been merged into the irq/core branch of tip: Commit-ID: bd141a3db40c877e01de8e981edb57c03199d876 Gitweb: https://git.kernel.org/tip/bd141a3db40c877e01de8e981edb57c03199d876 Author: Thomas Gleixner AuthorDate: Fri, 25 Nov 2022 00:26:02 +01:00 Committer: Thomas Gleixner CommitterDate: Mon, 05 Dec 2022 22:22:32 +01:00 genirq/msi: Provide BUS_DEVICE_PCI_MSI[X] Provide new bus tokens for the upcoming per device PCI/MSI and PCI/MSIX interrupt domains. Signed-off-by: Thomas Gleixner Reviewed-by: Kevin Tian Acked-by: Marc Zyngier Link: https://lore.kernel.org/r/20221124232325.917219885@linutronix.de --- include/linux/irqdomain_defs.h | 2 ++ kernel/irq/msi.c | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/include/linux/irqdomain_defs.h b/include/linux/irqdomain_defs.h index 69035b4..b3f4b7e 100644 --- a/include/linux/irqdomain_defs.h +++ b/include/linux/irqdomain_defs.h @@ -21,6 +21,8 @@ enum irq_domain_bus_token { DOMAIN_BUS_TI_SCI_INTA_MSI, DOMAIN_BUS_WAKEUP, DOMAIN_BUS_VMD_MSI, + DOMAIN_BUS_PCI_DEVICE_MSI, + DOMAIN_BUS_PCI_DEVICE_MSIX, }; #endif /* _LINUX_IRQDOMAIN_DEFS_H */ diff --git a/kernel/irq/msi.c b/kernel/irq/msi.c index ae58692..0749e66 100644 --- a/kernel/irq/msi.c +++ b/kernel/irq/msi.c @@ -1118,6 +1118,8 @@ static bool msi_check_reservation_mode(struct irq_domain *domain, switch(domain->bus_token) { case DOMAIN_BUS_PCI_MSI: + case DOMAIN_BUS_PCI_DEVICE_MSI: + case DOMAIN_BUS_PCI_DEVICE_MSIX: case DOMAIN_BUS_VMD_MSI: break; default: @@ -1143,6 +1145,8 @@ static int msi_handle_pci_fail(struct irq_domain *domain, struct msi_desc *desc, { switch(domain->bus_token) { case DOMAIN_BUS_PCI_MSI: + case DOMAIN_BUS_PCI_DEVICE_MSI: + case DOMAIN_BUS_PCI_DEVICE_MSIX: case DOMAIN_BUS_VMD_MSI: if (IS_ENABLED(CONFIG_PCI_MSI)) break;