From nobody Thu Sep 18 14:11:35 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 45799C4332F for ; Mon, 5 Dec 2022 18:25:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232836AbiLESZa (ORCPT ); Mon, 5 Dec 2022 13:25:30 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39660 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232372AbiLESZO (ORCPT ); Mon, 5 Dec 2022 13:25:14 -0500 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6AF1220BFD; Mon, 5 Dec 2022 10:25:13 -0800 (PST) Date: Mon, 05 Dec 2022 18:25:10 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1670264711; 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=EQd2hGgB/yRhWx8RU8z9DPIWHZJG+3iAv+YE6tbXlM8=; b=yaCgfjWOHQZLAFdGOBmbN2ctOXS2xjhgmifyUMK+skpfhvh68INHWDevNsa2MrSfRmeWnp TEEWoGqrOG0hy37ptVG/zzGIKIl75ZrlFWd/tQvUCH37s7tNG1+M0vYooCgQfNhyr0LEMX nLmF4jfjpGcVtYWcQiNI+S+e3euJVectvxrgCV2mUwhnDY0arbiY4FwNpXxllk7C8PX0gZ 5SBRpW4Y3R1o6uzaQaXFkMpoymSitfgBm0XmUafHFkzMr5EVojJNIicp/RULT8bVFi1GhX p4gWa6WQCAvm3/wCanj+cmdkBqIA39UWFlKBxi6beG4L5V+ktHXfqlhmIbp/kQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1670264711; 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=EQd2hGgB/yRhWx8RU8z9DPIWHZJG+3iAv+YE6tbXlM8=; b=ofA3B6cL8zUWLeuHk2E1Cjnv6RCvL3S1W8CsM5tLEE4nSme44XJ0G8XmFy0CmhJZVheWGq yR9rUdxGQYPu00CQ== 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: Enable PCI/IMS Cc: Thomas Gleixner , Kevin Tian , Marc Zyngier , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20221124232327.022658817@linutronix.de> References: <20221124232327.022658817@linutronix.de> MIME-Version: 1.0 Message-ID: <167026471067.4906.13288838482564117896.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the irq/core branch of tip: Commit-ID: ddd98f1b7b57dad5ae5efbe54154722aa6368b11 Gitweb: https://git.kernel.org/tip/ddd98f1b7b57dad5ae5efbe54154722aa= 6368b11 Author: Thomas Gleixner AuthorDate: Fri, 25 Nov 2022 00:26:32 +01:00 Committer: Thomas Gleixner CommitterDate: Mon, 05 Dec 2022 19:21:04 +01:00 x86/apic/msi: Enable PCI/IMS Enable IMS in the domain init and allocation mapping code, but do not enable it on the vector domain as discussed in various threads on LKML. The interrupt remap domains can expand this setting like they do with PCI multi MSI. Signed-off-by: Thomas Gleixner Reviewed-by: Kevin Tian Acked-by: Marc Zyngier Link: https://lore.kernel.org/r/20221124232327.022658817@linutronix.de --- arch/x86/kernel/apic/msi.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/x86/kernel/apic/msi.c b/arch/x86/kernel/apic/msi.c index 682f51a..35d5b8f 100644 --- a/arch/x86/kernel/apic/msi.c +++ b/arch/x86/kernel/apic/msi.c @@ -184,6 +184,7 @@ static int x86_msi_prepare(struct irq_domain *domain, s= truct device *dev, alloc->type =3D X86_IRQ_ALLOC_TYPE_PCI_MSI; return 0; case DOMAIN_BUS_PCI_DEVICE_MSIX: + case DOMAIN_BUS_PCI_DEVICE_IMS: alloc->type =3D X86_IRQ_ALLOC_TYPE_PCI_MSIX; return 0; default: @@ -230,6 +231,10 @@ static bool x86_init_dev_msi_info(struct device *dev, = struct irq_domain *domain, case DOMAIN_BUS_PCI_DEVICE_MSI: case DOMAIN_BUS_PCI_DEVICE_MSIX: break; + case DOMAIN_BUS_PCI_DEVICE_IMS: + if (!(pops->supported_flags & MSI_FLAG_PCI_IMS)) + return false; + break; default: WARN_ON_ONCE(1); return false;