Message ID | 20250404-ep-msi-v16-13-d4919d68c0d0@nxp.com |
---|---|
State | New |
Headers | show
Received: from DU2PR03CU002.outbound.protection.outlook.com (mail-northeuropeazon11012023.outbound.protection.outlook.com [52.101.66.23]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 26FB1222563; Fri, 4 Apr 2025 19:02:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=52.101.66.23 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1743793381; cv=fail; b=TLi9APqLqyaD03WvbheyDnxYgxfUt4E2x9YDS20ZtFQog71/5ZfAHnscYR91/57cYadNUOdWEnnI+htFBs/GHJ/cTUkC5bXWagdUKZJF985uQXxs3lxehycXABEusmeiiRtleZAfsCcF5ZjWKHX3iBsgUlFf6DlW1r5mgViaUzs= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1743793381; c=relaxed/simple; bh=E/+49PZzSike5Srwi1bFi+VTiZ02VK7QUYMJGqtvfmU=; h=From:Date:Subject:Content-Type:Message-Id:References:In-Reply-To: To:Cc:MIME-Version; b=VksOssQHsqS5uQrk1bYfWgRg5RxZ05PpMLrRsw5rDzv54dlDBPTThrQfdhxYd4e+7JXLdwVrv5XOZk4uhgXB60VqeBnse4h9zdWX6/5c4cPQfup4PSgSPNNh8dLPBaWCy57Loezb4sauBFJ77Vq5DaxBDozcVle804wRR5ceEJs= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; dkim=pass (2048-bit key) header.d=nxp.com header.i=@nxp.com header.b=XIGTob6p; arc=fail smtp.client-ip=52.101.66.23 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=nxp.com header.i=@nxp.com header.b="XIGTob6p" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=XAewzXo6EAyI/Lof4iUiG3uEK+wB725UmPQkpVuhJ6VzGlezEuXsSzod047tKZmXYH9V/oeI+0r3b44YmoRB82a7ojyxqCXsSxE4GZ92hXOu9LZUsDFCHX0c0Ff61xGsUnuGig8dS4Z9EJhd3mlRofd7QGTk/c6UR2YVDhfPZ7Qy7HSS7pthAZxXgeOS1/UkWUb/0WfjAXNY6OJKHQ27H/L87w5WKU8TmH7XjDM9XhGNBSrFQHZdZ2lG73CxITgnWTSZzgLrEfgdWnRB53PNmJ6gEVzn1PrQa4D5dYBaF8gTRYWUwnLmKzIKQEX8xdChVK5WWKlf7LBd/eoZwD0SJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=7Uw8VyfQPkoGAJ9vh4Z/t75FAVRHjabfWtBpwRAHpq0=; b=x2o8+ynvIhsmNWZYIm+YBhhSrk0wK7x2UL7oODpFdgCuLc+FIQL787LU/H1aNmH/Ujjad3Bkty7Vd7nF4iZoI59CdZmHjMkp2Qwfx2ONtVppOHdSiFxBjG2/atjB6s+8SkgYAHiVi5/PpanUO1YuEVZuqepeXhfffYIMUt1W0aV8dmUPNvERaqijdgVXL/gzmS7BWCEDAXiD6o9xykBoSrYExqZT5SOkdDXsbCQwD9DpdvNj0VmnqkbU8tqDeXpz9/Cd51d1EjOcOsbTbrTF2s2YNlprRnEsTFgrN2BwtX7QBiOiIYwc58++xgEB2tXOcSgk/x7/h1P42qaGjAjbog== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=7Uw8VyfQPkoGAJ9vh4Z/t75FAVRHjabfWtBpwRAHpq0=; b=XIGTob6pHcqzS6zBbq9PkxhEK4/I6qylToXa9eCNg2ucgVTG4s+K6Cw0IQtiaXivbucJxsM+qzTO0Gi5f6ArwcrFiO1q5PqiK0udZF99WJ4m3jLQmxl4vDoqaH41zyNmkJu0pO4LQpht73jtXAahzhrZFXMvgrDv8ymr1uzwUCCbCWfdtL7AC/4vAgFhKDtgqtFGaLMSmeiU+YcdFWAf8td0C6lBA0KhakyVgcLoVzv/yiT0RfsLvu+twcTIHkiOBxHYaKlFkAJhhqwMzwhPwJCAsCKmCK5hybvWaMXy02Te247ckQCp/53YJtzOe19SgbZ+Ezbrjmfv1tJ0rB6GdA== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) by AM7PR04MB6966.eurprd04.prod.outlook.com (2603:10a6:20b:109::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8534.44; Fri, 4 Apr 2025 19:02:56 +0000 Received: from PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06]) by PAXPR04MB9642.eurprd04.prod.outlook.com ([fe80::9126:a61e:341d:4b06%2]) with mapi id 15.20.8534.048; Fri, 4 Apr 2025 19:02:55 +0000 From: Frank Li <Frank.Li@nxp.com> Date: Fri, 04 Apr 2025 15:01:14 -0400 Subject: [PATCH v16 13/15] pci: imx6: Add helper function imx_pcie_add_lut_by_rid() Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20250404-ep-msi-v16-13-d4919d68c0d0@nxp.com> References: <20250404-ep-msi-v16-0-d4919d68c0d0@nxp.com> In-Reply-To: <20250404-ep-msi-v16-0-d4919d68c0d0@nxp.com> To: Kishon Vijay Abraham I <kishon@kernel.org>, "Rafael J. Wysocki" <rafael@kernel.org>, Thomas Gleixner <tglx@linutronix.de>, Anup Patel <apatel@ventanamicro.com>, Kishon Vijay Abraham I <kishon@kernel.org>, Marc Zyngier <maz@kernel.org>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, "Rafael J. Wysocki" <rafael@kernel.org>, Danilo Krummrich <dakr@kernel.org>, Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>, =?utf-8?q?Krzysz?= =?utf-8?q?tof_Wilczy=C5=84ski?= <kw@linux.com>, Kishon Vijay Abraham I <kishon@kernel.org>, Bjorn Helgaas <bhelgaas@google.com>, Arnd Bergmann <arnd@arndb.de>, Shuah Khan <shuah@kernel.org>, Richard Zhu <hongxing.zhu@nxp.com>, Lucas Stach <l.stach@pengutronix.de>, Lorenzo Pieralisi <lpieralisi@kernel.org>, Rob Herring <robh@kernel.org>, Shawn Guo <shawnguo@kernel.org>, Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix Kernel Team <kernel@pengutronix.de>, Fabio Estevam <festevam@gmail.com>, Krzysztof Kozlowski <krzk+dt@kernel.org>, Conor Dooley <conor+dt@kernel.org> Cc: Niklas Cassel <cassel@kernel.org>, dlemoal@kernel.org, jdmason@kudzu.us, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pci@vger.kernel.org, linux-kselftest@vger.kernel.org, imx@lists.linux.dev, devicetree@vger.kernel.org, Frank Li <Frank.Li@nxp.com> X-Mailer: b4 0.13-dev-e586c X-Developer-Signature: v=1; a=ed25519-sha256; t=1743793288; l=1816; i=Frank.Li@nxp.com; s=20240130; h=from:subject:message-id; bh=E/+49PZzSike5Srwi1bFi+VTiZ02VK7QUYMJGqtvfmU=; b=K0FBzefcMK/XQJRNJONk/zeUdL2/GAkAHHIO978ki/gcQN29bNfBGvKvTWM5g4b4XjqF1rcOr TrgMYLAgQwcAxUYFtpm/IX7nuursznbnDsx1VsVC6F9M5kO69q9EZNC X-Developer-Key: i=Frank.Li@nxp.com; a=ed25519; pk=I0L1sDUfPxpAkRvPKy7MdauTuSENRq+DnA+G4qcS94Q= X-ClientProxiedBy: PH8P222CA0011.NAMP222.PROD.OUTLOOK.COM (2603:10b6:510:2d7::35) To PAXPR04MB9642.eurprd04.prod.outlook.com (2603:10a6:102:240::14) Precedence: bulk X-Mailing-List: linux-kselftest@vger.kernel.org List-Id: <linux-kselftest.vger.kernel.org> List-Subscribe: <mailto:linux-kselftest+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kselftest+unsubscribe@vger.kernel.org> MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB9642:EE_|AM7PR04MB6966:EE_ X-MS-Office365-Filtering-Correlation-Id: ef8e54b0-cdee-460c-09a9-08dd73ab4ef2 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|366016|1800799024|376014|7416014|52116014|921020|38350700014; X-Microsoft-Antispam-Message-Info: =?utf-8?q?9TD65bHNovX/gZZgFf1bD5pyDd3DT1T?= =?utf-8?q?SInfL94v8upYQ65Fjtws5Pq/SyZh8syB4EGXexTwj8RAD9pGWxWqQZTWh1jyI/atz?= =?utf-8?q?WQ0I1dy/6fAAOiijYhKcqdukpgSRazNhOPOIkj3vTHMI4p0aDkvn5/5NAqp+Zya2M?= =?utf-8?q?pGww/yyONGKqU46n7uADu827oJr79octoVsk8XqLdncRvQ0qMdspJGC7vTIeViZ1x?= =?utf-8?q?ItMTcCryUw7gkSoUSpC9e0O4DOl4KbN6Ro2oyTDKvjSTs/TPtWEwwlqI50VYc2xOV?= =?utf-8?q?C84O3cPoelJ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uAmN42Pi5rSGMMy4QKfOVx+39IL11gwu3cqBAeLBB4Upmqy?= =?utf-8?q?BFBwzuoDBwgxaaxmya+aF6tl24NNLLL3K9dw0zKOPuR+jqO5aCXTL6hTibQ808tct?= =?utf-8?q?vWbv5ERZynQcCzIOzWjKhW6DchOYZolIBudTH1C4dKF7lVX97n1m5lgc8GfkwTraq?= =?utf-8?q?tIfp8PfQ84kkaOfH7kpC7eWGLvK+LFrbgVuVmbvrX+l5g6s1Q5gG6hEiAeP7VYkYz?= =?utf-8?q?Fs3WNrQsnAmb4DKNdKJEjjqldE/tMnylQ=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR04MB9642.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(366016)(1800799024)(376014)(7416014)(52116014)(921020)(38350700014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?6MDD3gpTJyUHChr88qLGaeh3+Mpx?= =?utf-8?q?LX5x5VaV9LiAL2sfIXMr8kFtClwaB6gy3zWyd2xduBStyYOpHaY4oiol5FxlEx/xE?= =?utf-8?q?qJJne+FlzEY6hN7H6g00B58MITfdnj6hc0/xahGZhiG0Ehm3KGoaQRATO2vHTCnbj?= =?utf-8?q?ismlA7Cwk5gBHzBsJSZp2+iZPmvug2vsWlNzcQ8EokZxxwoKJq1D5AcNH2qOKoR2B?= =?utf-8?q?vaJMu6UXfP5jzpPkCU1TufSyl9v2J6Cxk93czevMP/xJ0BtVUSRbM38TYiSq9EiS6?= =?utf-8?q?QR6FVFCFX2LqypCt1FUU/wm1BdIqQX6vJq664K7zrm1yyZxhQDoP6PW/gVYjBivn9?= =?utf-8?q?FFaTzoIcsdO58/DuS4pGcbjeh/ZSIIgRZDatwYVBHNEAJxolG9+38d2spfN6ZSVhV?= =?utf-8?q?45NMy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7rB/CF7bM/BZI8D2GWj56Fi/r1vb55NQ0wveaQ9t1gAS?= =?utf-8?q?P+Q34AmE5Yu+c/5VLEDhHzSopq6KbOkVWkecQkg6GYJ9jWVb0XHcRiPmS7GSfmCNC?= =?utf-8?q?hzuaJL0TNbnkjXoCzgtEUS5/D+USL8NVnXJB2ZaGdrjPtw+lfffQc6rPrsSh4/aJs?= =?utf-8?q?vl+lFJNSLI2373AKPNLqsDz+TFE/hYGkUiJQn8+goHfTS5QvmfBs4EL8=3D?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: ef8e54b0-cdee-460c-09a9-08dd73ab4ef2 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB9642.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Apr 2025 19:02:55.8983 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: KQ4UkLj+33eBTNUiSIJh/HPkh4+Jdgn9ne1ekIlAHmrLwqUE7CdPkYlSeA4Bx+vZwccEQwqRjyVMA66Lf5jy3A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM7PR04MB6966 |
Series |
[v16,01/15] platform-msi: Add msi_remove_device_irq_domain() in platform_device_msi_free_irqs_all()
|
expand
|
diff --git a/drivers/pci/controller/dwc/pci-imx6.c b/drivers/pci/controller/dwc/pci-imx6.c index 5f267dd261b51..d1b1365e7469e 100644 --- a/drivers/pci/controller/dwc/pci-imx6.c +++ b/drivers/pci/controller/dwc/pci-imx6.c @@ -1025,18 +1025,14 @@ static void imx_pcie_remove_lut(struct imx_pcie *imx_pcie, u16 rid) } } -static int imx_pcie_enable_device(struct pci_host_bridge *bridge, - struct pci_dev *pdev) +static int imx_pcie_add_lut_by_rid(struct imx_pcie *imx_pcie, u32 rid) { - struct imx_pcie *imx_pcie = to_imx_pcie(to_dw_pcie_from_pp(bridge->sysdata)); - u32 sid_i, sid_m, rid = pci_dev_id(pdev); + struct device *dev = imx_pcie->pci->dev; struct device_node *target; - struct device *dev; + u32 sid_i, sid_m; int err_i, err_m; u32 sid = 0; - dev = imx_pcie->pci->dev; - target = NULL; err_i = of_map_id(dev->of_node, rid, "iommu-map", "iommu-map-mask", &target, &sid_i); @@ -1111,6 +1107,13 @@ static int imx_pcie_enable_device(struct pci_host_bridge *bridge, return imx_pcie_add_lut(imx_pcie, rid, sid); } +static int imx_pcie_enable_device(struct pci_host_bridge *bridge, struct pci_dev *pdev) +{ + struct imx_pcie *imx_pcie = to_imx_pcie(to_dw_pcie_from_pp(bridge->sysdata)); + + return imx_pcie_add_lut_by_rid(imx_pcie, pci_dev_id(pdev)); +} + static void imx_pcie_disable_device(struct pci_host_bridge *bridge, struct pci_dev *pdev) {
Add helper function imx_pcie_add_lut_by_rid(), which will be used for Endpoint mode in the future. No functional change. Signed-off-by: Frank Li <Frank.Li@nxp.com> --- change from v14 to v16 - none change from v13 to v14 - new patch --- drivers/pci/controller/dwc/pci-imx6.c | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-)