From nobody Mon Feb 9 07:56:00 2026 Received: from SA9PR02CU001.outbound.protection.outlook.com (mail-southcentralusazon11013002.outbound.protection.outlook.com [40.93.196.2]) (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 08E7B313E27; Thu, 22 Jan 2026 17:19:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.93.196.2 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769102407; cv=fail; b=SJ6rw9oF5DthLI2cXWAGkXgBohLRChPIZ5ve4HKpHvNZP3/ChEg4fw8RRRo+mWkSve9FKMYouitbTzHJL80BGTjyrfh+w4uPLfWsCOdyFVdWqsrQquwfXDe3mmyVycBZYjk2Xx71u+J9JIfNYljcDfNYfIr8EsOpri4Mz1lQSCs= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769102407; c=relaxed/simple; bh=oCKxGaLLxf8fMQfw+IA9tQkIn485qQoviGEyUZwogd4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-ID:References: In-Reply-To:To:CC; b=WfaZsNpRnE2XIy1Hm4z8KnqLDFQVoc+pRQqE6THAQoSYAcEleVwxaW2QiWWf770xIlfOLiG+9ifRAqQNZ+VJhxv+e2n9p0uGjlR5UMkdoSbWe49t8iYWZm3qtrwMRpIOK8om5ZBBACZ7qaNAEg+lskt9PBbPh0703IC/4vE9wqI= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=b0AwVFe4; arc=fail smtp.client-ip=40.93.196.2 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="b0AwVFe4" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=LR4AanO5eHAttGrr7WFPPeQZxsW9V9B9ayi39f194b6ve6hItqE7ljp6qOWPUO2BZAlGbB8VO+moH+JEQY0LlxwTc2U3PDi/SICy6KvSdq7l0JORJ+uXzLyUsGnMDBjiqehb86Akj+5GGRBGg2y8q71+DZj/VNJX1Rkp3SiMD0xiyyH43B8MMrl7XyHnDUDzPfKUKrYRDbdnAunAoZWEBZpZKTzunoCKsVOSOcoWw+U80Q5qI+CEFoKYYRsJMepgA2PeMBidABJ1zdMlyId3u6hnV2M5jZkKg0WyPpv5v38MW6ynhoYGt31SboGZZMWw4ETq2P26O+G7YbqLLqavQw== 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=OhfSPfWOAwYOvyIZzuXMp0da32tHkG7iKwNzA5Mzx+8=; b=UgIOgLKKeIoBZfybQcom3mo6IJ7yddAx+X7dtjJa52/EJDQ+S5RXXl4SP6+HPdattMOXx/PyT6TJH+GanaHO1XGfEHYHSyXnDfBXHiTIOoJqvKGVV/h3hzx0yBremzdNdWP5Twj3EYYYpmMK0NApT73qnmgAWhs4pp8Tikl+munKIdTHhvEVwxOkxN8vNDQHXa88OCa9nWQyeNeoBrunLJe+20/0CDiYUKBiZgkYXGRgygkGhXjbUduisc2oLQg9j2xFSwLfnh4AZ6owTBuPzRVhMvKDgLXW6isxLnONcMaiAIwDQRQ6e/MOQwCYKrhRwSGNn2C7X5dW1DZVuGsUGw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 198.47.23.194) smtp.rcpttodomain=kernel.org smtp.mailfrom=ti.com; dmarc=pass (p=quarantine sp=none pct=100) action=none header.from=ti.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=OhfSPfWOAwYOvyIZzuXMp0da32tHkG7iKwNzA5Mzx+8=; b=b0AwVFe4Bn6mgURaHC6vGaPM3hYomfpPwPW6g7OJiEmfR2HMveMuinGwEIBnX8bgZcDXnaXNaqNOohyaTZliVC3ldgLnjHzwXqXNTuOCcAfU1UulVFX4KJtEST8qrYnduiarqSMgpL+nPpdH6SChpBjwhfWqDFtuWzJ0zYo2nK4= Received: from BN0PR07CA0014.namprd07.prod.outlook.com (2603:10b6:408:141::7) by MN2PR10MB4238.namprd10.prod.outlook.com (2603:10b6:208:1d3::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9542.9; Thu, 22 Jan 2026 17:19:47 +0000 Received: from BN1PEPF00005FFD.namprd05.prod.outlook.com (2603:10b6:408:141:cafe::9c) by BN0PR07CA0014.outlook.office365.com (2603:10b6:408:141::7) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.9542.10 via Frontend Transport; Thu, 22 Jan 2026 17:19:37 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 198.47.23.194) smtp.mailfrom=ti.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=ti.com; Received-SPF: Pass (protection.outlook.com: domain of ti.com designates 198.47.23.194 as permitted sender) receiver=protection.outlook.com; client-ip=198.47.23.194; helo=lewvzet200.ext.ti.com; pr=C Received: from lewvzet200.ext.ti.com (198.47.23.194) by BN1PEPF00005FFD.mail.protection.outlook.com (10.167.243.229) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9564.3 via Frontend Transport; Thu, 22 Jan 2026 17:19:47 +0000 Received: from DLEE207.ent.ti.com (157.170.170.95) by lewvzet200.ext.ti.com (10.4.14.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.20; Thu, 22 Jan 2026 11:19:46 -0600 Received: from DLEE213.ent.ti.com (157.170.170.116) by DLEE207.ent.ti.com (157.170.170.95) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.20; Thu, 22 Jan 2026 11:19:46 -0600 Received: from lelvem-mr05.itg.ti.com (10.180.75.9) by DLEE213.ent.ti.com (157.170.170.116) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.20 via Frontend Transport; Thu, 22 Jan 2026 11:19:46 -0600 Received: from psdkl-workstation0.dhcp.ti.com (psdkl-workstation0.dhcp.ti.com [172.24.234.127]) by lelvem-mr05.itg.ti.com (8.18.1/8.18.1) with ESMTP id 60MHJcoO912039; Thu, 22 Jan 2026 11:19:42 -0600 From: Aniket Limaye Date: Thu, 22 Jan 2026 22:49:13 +0530 Subject: [PATCH v3 1/2] dt-bindings: interrupt-controller: ti,sci-intr: Per-line interrupt-types Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-ID: <20260122-ul-driver-i2c-j722s-v3-1-4ec3478f3866@ti.com> References: <20260122-ul-driver-i2c-j722s-v3-0-4ec3478f3866@ti.com> In-Reply-To: <20260122-ul-driver-i2c-j722s-v3-0-4ec3478f3866@ti.com> To: Vignesh Raghavendra , , Nishanth Menon , Tero Kristo , Santosh Shilimkar , Thomas Gleixner , Rob Herring , Krzysztof Kozlowski , Conor Dooley CC: , , , , Aniket Limaye X-Mailer: b4 0.14.3 X-C2ProcessedOrg: 333ef613-75bf-4e12-a4b1-8e3623f5dcea X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BN1PEPF00005FFD:EE_|MN2PR10MB4238:EE_ X-MS-Office365-Filtering-Correlation-Id: 1502f9bc-fc3a-4f37-28e8-08de59da7150 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|36860700013|82310400026|376014; X-Microsoft-Antispam-Message-Info: =?utf-8?B?SEpJbWY4NW9uZExqTWdZbEV2ZmJzb1NzaU81L3RZN0pnaW5KR3RwazJMUTBG?= =?utf-8?B?SjFJSWFIS0JxaFl4bTlrcU8xZ3ZWb0I0UVBodmFQVkNaclNZZ1Fzb3VjR3lR?= =?utf-8?B?OVEwYkVwTzNCeEdLZmFsc3Jab2RaNUNoNGZTc0xoSG93SlpiUkR4VGZ1SCs2?= =?utf-8?B?eFpKNHRTWXBwYkpzWDFpa2tEektrbHR1ZDJERysvb1JtMnU1d09oM0Rsa1FO?= =?utf-8?B?VWFGRWpFYmZTZ05EQjBSVUVLTTRUR3dvTUtnSUdkQU5uZTIxajFFQlowQVRJ?= =?utf-8?B?cGdRbzRmcHh4d2ZRSzVDdk02alNKWmdjbmxXbUl6KzFVNFI5N0hua2lzb0pj?= =?utf-8?B?blp0WHNXT2RXVlRHTVhjMURRb2Y2OGFRNGZ5RUcvMlR0b1Nhb2dCTXlWNnRX?= =?utf-8?B?SGN6UlNpR3duSTVEbmVTR2czMXZ5eUhNY0pxR01ScjZJTG9kN3JsejQxVHVZ?= =?utf-8?B?ZVlNTk4xREY5NFpYMDY4ZzJ2d3J0UlpjV00zbTFadkp6Lyt4S21qV3lVQ0M2?= =?utf-8?B?ckV6V2xSYmpZWGdBa21XRlVsQUNWT21YUFFDeTlqZTJGQ1lnanZpS2w5TGNC?= =?utf-8?B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:NONE;SFS:(13230040)(1800799024)(36860700013)(82310400026)(376014);DIR:OUT;SFP:1101; X-OriginatorOrg: ti.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Jan 2026 17:19:47.0790 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1502f9bc-fc3a-4f37-28e8-08de59da7150 X-MS-Exchange-CrossTenant-Id: e5b49634-450b-4709-8abb-1e2b19b982b7 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=e5b49634-450b-4709-8abb-1e2b19b982b7;Ip=[198.47.23.194];Helo=[lewvzet200.ext.ti.com] X-MS-Exchange-CrossTenant-AuthSource: BN1PEPF00005FFD.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR10MB4238 Update the bindings to allow setting per-line interrupt-types. Some Interrupt Router instances can only work with a specific trigger type (edge or level), while others act as simple passthroughs that preserve the source interrupt type unchanged. Make "ti,intr-trigger-type" property optional, with its absence indicating that the router acts as a passthrough. When absent, "#interrupt-cells" must be 2 to allow each interrupt source to specify its trigger type per-line. Signed-off-by: Aniket Limaye Reviewed-by: Rob Herring (Arm) --- Changes in v3: - Avoid new redundant value IRQ_TYPE_DEFAULT for "ti,intr-trigger-type" when "#interrupt-cells"=3D=3D2. Instead, make this property optional and check for its absence to use the per-line interrupt-type setting. - Link to v2: https://lore.kernel.org/r/20260120-ul-driver-i2c-j722s-v2-1-832097c6b64f@ti= .com Changes in v2: - Reword Commit msg to better describe the patch - Link to v1: https://lore.kernel.org/r/20260116-ul-driver-i2c-j722s-v1-1-c28e8ba38a9e@ti= .com --- .../bindings/interrupt-controller/ti,sci-intr.yaml | 44 ++++++++++++++++++= +--- 1 file changed, 38 insertions(+), 6 deletions(-) diff --git a/Documentation/devicetree/bindings/interrupt-controller/ti,sci-= intr.yaml b/Documentation/devicetree/bindings/interrupt-controller/ti,sci-i= ntr.yaml index c99cc7323c71..8156ce6d2ab4 100644 --- a/Documentation/devicetree/bindings/interrupt-controller/ti,sci-intr.ya= ml +++ b/Documentation/devicetree/bindings/interrupt-controller/ti,sci-intr.ya= ml @@ -15,8 +15,7 @@ allOf: description: | The Interrupt Router (INTR) module provides a mechanism to mux M interrupt inputs to N interrupt outputs, where all M inputs are selectab= le - to be driven per N output. An Interrupt Router can either handle edge - triggered or level triggered interrupts and that is fixed in hardware. + to be driven per N output. =20 Interrupt Router +----------------------+ @@ -54,19 +53,28 @@ properties: $ref: /schemas/types.yaml#/definitions/uint32 enum: [1, 4] description: | - Should be one of the following. + Optional property - should be one of the following: 1 =3D If intr supports edge triggered interrupts. 4 =3D If intr supports level triggered interrupts. =20 + If this property is present, #interrupt-cells must be 1. + If this property is absent, #interrupt-cells must be 2 and interrupt + source must specify the trigger type in the second cell. + reg: maxItems: 1 =20 interrupt-controller: true =20 '#interrupt-cells': - const: 1 + enum: [1, 2] description: | - The 1st cell should contain interrupt router input hw number. + Number of cells in interrupt specifier. Depends on ti,intr-trigger-t= ype: + - If ti,intr-trigger-type is present: must be 1 + The 1st cell should contain interrupt router input hw number. + - If ti,intr-trigger-type is absent: must be 2 + The 1st cell should contain interrupt router input hw number. + The 2nd cell should contain interrupt trigger type (preserved by r= outer). =20 ti,interrupt-ranges: $ref: /schemas/types.yaml#/definitions/uint32-matrix @@ -82,9 +90,22 @@ properties: - description: | "limit" specifies the limit for translation =20 +if: + required: + - ti,intr-trigger-type +then: + properties: + '#interrupt-cells': + const: 1 + description: Interrupt ID only. Interrupt type is specified globally +else: + properties: + '#interrupt-cells': + const: 2 + description: Interrupt ID and corresponding interrupt type + required: - compatible - - ti,intr-trigger-type - interrupt-controller - '#interrupt-cells' - ti,sci @@ -105,3 +126,14 @@ examples: ti,sci-dev-id =3D <131>; ti,interrupt-ranges =3D <0 360 32>; }; + + - | + main_gpio_intr1: interrupt-controller1 { + compatible =3D "ti,sci-intr"; + interrupt-controller; + interrupt-parent =3D <&gic500>; + #interrupt-cells =3D <2>; + ti,sci =3D <&dmsc>; + ti,sci-dev-id =3D <131>; + ti,interrupt-ranges =3D <0 360 32>; + }; --=20 2.52.0 From nobody Mon Feb 9 07:56:00 2026 Received: from DM1PR04CU001.outbound.protection.outlook.com (mail-centralusazon11010068.outbound.protection.outlook.com [52.101.61.68]) (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 0B83431A044; Thu, 22 Jan 2026 17:20:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=52.101.61.68 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769102414; cv=fail; b=AJPtB2X0lF1RY4j7sfQyHJ0Vt2McUcGDtg33XnacXUi39tbzwnUd/IorDtJi9xdGKLGfJQCiNq/nScOMYJ/URS6DNlZN+p5IMY9asFO+qmdhzt0PJnzhLhPY+3cUqUmZ+5GQg4WRqd0080wXqrSkxKzjt2tBzbDaDhk+8iKTXYo= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769102414; c=relaxed/simple; bh=geoModA8WrR+gZD8T4GkzGa89s2zlEevJFB4EBsEjtY=; h=From:Date:Subject:MIME-Version:Content-Type:Message-ID:References: In-Reply-To:To:CC; b=p9J1frkmn/7KMXRBfS2xVzgRps405MBSrmf1O+wEWhGd0hl7eymfCtgTXeiHnajtrX3bwj3Omaq3e/D85ovXbIrgwb5Tn24WKtzbO0ZtAyPT7F4hGzlOqWBmeDYos2o72XqsTexDb+zzzVmtLq8pEtFt2YWu2LO5NDuiU3MEm10= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com; spf=pass smtp.mailfrom=ti.com; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b=gZRKmy+1; arc=fail smtp.client-ip=52.101.61.68 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=ti.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ti.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="gZRKmy+1" ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=uQ7yv3N6wfnJyLTfrChrKsfVhAP9qEFLXMVyVKAm+i0JpSlr0N7Cofjw3m90GPBxsfQWv6HACy6oQ/uCIBQOT4GKjJSw2JxFi93E7oYxHx71yDpTJHq/9qXc1dAh+rAwd1220r1U8y3P90gKmOf/rhuTj/xnSUWAvRXRJ1tHPhoukSJTX6KYOdamL0d1XcoeuhSr/OyOoqc8iN6xwNURleM684NlxObvyNdJNgnZPluLbyI3A6KwpC4zidvVPHlQy2AR5Wtqr2r+O2oxJE13SmRrIoLVHjfZM15G3QnGYg9y2zv+7u5cWemSNgpydw6J7p6LNoZA+UDjt0uGxCCRFg== 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=5yBuxPGDCpEphM/KZt/cMvZHfJnkc1tQPoLWsiBEtpw=; b=n6/4lGMnOuMZFFRo50r0dzi113yLRcvvkc0LxxYuIcFd6vtx3eWS7EezKUOinB9uLQ5zw4wrN28QI9u9WWdrcZ0bmwXPFbu3Oh/I8cTKsmYK59Ppr0p3527tDW3q7Cn5B2XX2Az2vv+sx/sZ/jMeM6lGKNamn3QLGCXxO0ZUMZ0MDq8ALY5kZJc9xj5oBuuUthsIkmqb0+m9rtASKpxINqI9CpPXUYpheLhluW0arkcV2KB2wo1pfUPIZ5lSwE0gCQ9m9qPxwRYoKVPL1VEZ/fbf2vUqwJsscxB0Pw1W/zW8HpKWPC3BK8ao/qrQuyLsVIBHj0ucqPPBinIt9tL9ZQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 198.47.21.195) smtp.rcpttodomain=kernel.org smtp.mailfrom=ti.com; dmarc=pass (p=quarantine sp=none pct=100) action=none header.from=ti.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5yBuxPGDCpEphM/KZt/cMvZHfJnkc1tQPoLWsiBEtpw=; b=gZRKmy+1xvJs6HesYsAvMtnq4RuPIs3korfDYe3uzgtTrVzMcUcnJuc+DfuyEbZJ+/WNUI9EwJGr3cJaCGequ4XRrHJk0UkbDlvUrOFN/L0/z3N0qy61lpgt4/UaPfOexRBRdtH+EDgSfEeKDzFVxw06Yq2CTK/ecnZmQZ72s/U= Received: from BY1P220CA0025.NAMP220.PROD.OUTLOOK.COM (2603:10b6:a03:5c3::12) by IA3PR10MB8164.namprd10.prod.outlook.com (2603:10b6:208:514::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9542.11; Thu, 22 Jan 2026 17:19:56 +0000 Received: from SJ5PEPF000001F1.namprd05.prod.outlook.com (2603:10b6:a03:5c3:cafe::e9) by BY1P220CA0025.outlook.office365.com (2603:10b6:a03:5c3::12) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.9542.11 via Frontend Transport; Thu, 22 Jan 2026 17:20:05 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 198.47.21.195) smtp.mailfrom=ti.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=ti.com; Received-SPF: Pass (protection.outlook.com: domain of ti.com designates 198.47.21.195 as permitted sender) receiver=protection.outlook.com; client-ip=198.47.21.195; helo=flwvzet201.ext.ti.com; pr=C Received: from flwvzet201.ext.ti.com (198.47.21.195) by SJ5PEPF000001F1.mail.protection.outlook.com (10.167.242.69) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9564.3 via Frontend Transport; Thu, 22 Jan 2026 17:19:55 +0000 Received: from DFLE200.ent.ti.com (10.64.6.58) by flwvzet201.ext.ti.com (10.248.192.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.20; Thu, 22 Jan 2026 11:19:50 -0600 Received: from DFLE208.ent.ti.com (10.64.6.66) by DFLE200.ent.ti.com (10.64.6.58) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.20; Thu, 22 Jan 2026 11:19:50 -0600 Received: from lelvem-mr05.itg.ti.com (10.180.75.9) by DFLE208.ent.ti.com (10.64.6.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.20 via Frontend Transport; Thu, 22 Jan 2026 11:19:50 -0600 Received: from psdkl-workstation0.dhcp.ti.com (psdkl-workstation0.dhcp.ti.com [172.24.234.127]) by lelvem-mr05.itg.ti.com (8.18.1/8.18.1) with ESMTP id 60MHJcoP912039; Thu, 22 Jan 2026 11:19:46 -0600 From: Aniket Limaye Date: Thu, 22 Jan 2026 22:49:14 +0530 Subject: [PATCH v3 2/2] irqchip/ti-sci-intr: Allow parsing interrupt-types per-line Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-ID: <20260122-ul-driver-i2c-j722s-v3-2-4ec3478f3866@ti.com> References: <20260122-ul-driver-i2c-j722s-v3-0-4ec3478f3866@ti.com> In-Reply-To: <20260122-ul-driver-i2c-j722s-v3-0-4ec3478f3866@ti.com> To: Vignesh Raghavendra , , Nishanth Menon , Tero Kristo , Santosh Shilimkar , Thomas Gleixner , Rob Herring , Krzysztof Kozlowski , Conor Dooley CC: , , , , Aniket Limaye X-Mailer: b4 0.14.3 X-C2ProcessedOrg: 333ef613-75bf-4e12-a4b1-8e3623f5dcea X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ5PEPF000001F1:EE_|IA3PR10MB8164:EE_ X-MS-Office365-Filtering-Correlation-Id: df893655-3f3d-445e-f59a-08de59da7618 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|1800799024|82310400026|36860700013; X-Microsoft-Antispam-Message-Info: =?utf-8?B?THpwYWMzSU9HK1RLT0NGOGt2NmQrUjdBTHEyVkJJeEl3Qmd6S0VOZUxWcjI1?= =?utf-8?B?M1pFbTB3S3lYVkk5bnhiSVBEZ0xyNklrNEdsYk9uYWlxZEdpMWpsaG9HR0x6?= =?utf-8?B?MHF1Ulc0bmZvcnJkUTZvdGVMQXBrSmViVkdyUU1sYjM1c2ZobC9EZnhGczdZ?= =?utf-8?B?R01KaGMwWDJtdXJzanAzUnpOZ1lHM1ZqNDNuby9UY2ExaVliNDQ3eURqTERn?= =?utf-8?B?MnNJbVFlbFBMY2Q0cS9HZkgzVzlsdGtoeVVnVTlQbWZBSnErSC9tQ1RJekVo?= =?utf-8?B?ZUg5WWxXL25XRS90VWNjRGNPY3ZaemJVb0dUWjAxRlVtTloxbmphMjZrWGdX?= =?utf-8?B?MklMR0xuOUVEdWEzUHFXTzgvV0hqN1ExQytlK1BYNXA4U01SWHBPN25OUnVq?= =?utf-8?B?dTV5bVpZN2tCK1RWUkgza1A4cVlwMVhSV05UeFlVS29JSWZUSUsvek5Gbngr?= =?utf-8?B?NVV3K2UwbExsN2VLZndZS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?= X-Forefront-Antispam-Report: CIP:198.47.21.195;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:flwvzet201.ext.ti.com;PTR:ErrorRetry;CAT:NONE;SFS:(13230040)(376014)(1800799024)(82310400026)(36860700013);DIR:OUT;SFP:1101; X-OriginatorOrg: ti.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Jan 2026 17:19:55.0885 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: df893655-3f3d-445e-f59a-08de59da7618 X-MS-Exchange-CrossTenant-Id: e5b49634-450b-4709-8abb-1e2b19b982b7 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=e5b49634-450b-4709-8abb-1e2b19b982b7;Ip=[198.47.21.195];Helo=[flwvzet201.ext.ti.com] X-MS-Exchange-CrossTenant-AuthSource: SJ5PEPF000001F1.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA3PR10MB8164 Some INTR router instances act as simple passthroughs that preserve the source interrupt type unchanged at the output line, rather than converting all interrupts to a fixed type. When interrupt sources are not homogeneous with respect to trigger type, the driver needs to read each source's interrupt type from DT and pass it unchanged to its interrupt parent. Add support to check for absence of "ti,intr-trigger-type" to indicate passthrough mode. When this property is absent, parse interrupt type per-line from the DT fwspec provided by the interrupt source. Else, use the global setting for all interrupt lines. Signed-off-by: Aniket Limaye --- Changes in v3: - Avoid new redundant value IRQ_TYPE_DEFAULT for "ti,intr-trigger-type" when "#interrupt-cells"=3D=3D2. Instead, make this property optional and check for its absence to use the per-line interrupt-type setting. - Link to v2: https://lore.kernel.org/r/20260120-ul-driver-i2c-j722s-v2-2-832097c6b64f@ti= .com Changes in v2: - Use correct Patch Subject prefix - Reword Commit msg to better describe the patch - Fix function argument alignment as per coding style - Fix variable declaration ordering as per coding style - Link to v1: https://lore.kernel.org/r/20260116-ul-driver-i2c-j722s-v1-2-c28e8ba38a9e@ti= .com --- drivers/irqchip/irq-ti-sci-intr.c | 49 ++++++++++++++++++++++++++++-------= ---- 1 file changed, 36 insertions(+), 13 deletions(-) diff --git a/drivers/irqchip/irq-ti-sci-intr.c b/drivers/irqchip/irq-ti-sci= -intr.c index 354613e74ad0..0c6065e66e6a 100644 --- a/drivers/irqchip/irq-ti-sci-intr.c +++ b/drivers/irqchip/irq-ti-sci-intr.c @@ -61,11 +61,22 @@ static int ti_sci_intr_irq_domain_translate(struct irq_= domain *domain, { struct ti_sci_intr_irq_domain *intr =3D domain->host_data; =20 - if (fwspec->param_count !=3D 1) - return -EINVAL; =20 - *hwirq =3D fwspec->param[0]; - *type =3D intr->type; + if (intr->type) { + /* Global interrupt-type */ + if (fwspec->param_count !=3D 1) + return -EINVAL; + + *hwirq =3D fwspec->param[0]; + *type =3D intr->type; + } else { + /* Per-Line interrupt-type */ + if (fwspec->param_count !=3D 2) + return -EINVAL; + + *hwirq =3D fwspec->param[0]; + *type =3D fwspec->param[1]; + } =20 return 0; } @@ -128,11 +139,12 @@ static void ti_sci_intr_irq_domain_free(struct irq_do= main *domain, * @domain: Pointer to the interrupt router IRQ domain * @virq: Corresponding Linux virtual IRQ number * @hwirq: Corresponding hwirq for the IRQ within this IRQ domain + * @hwirq_type: Corresponding hwirq trigger type for the IRQ within this I= RQ domain * * Returns intr output irq if all went well else appropriate error pointer. */ static int ti_sci_intr_alloc_parent_irq(struct irq_domain *domain, - unsigned int virq, u32 hwirq) + unsigned int virq, u32 hwirq, u32 hwirq_type) { struct ti_sci_intr_irq_domain *intr =3D domain->host_data; struct device_node *parent_node; @@ -156,11 +168,23 @@ static int ti_sci_intr_alloc_parent_irq(struct irq_do= main *domain, fwspec.param_count =3D 3; fwspec.param[0] =3D 0; /* SPI */ fwspec.param[1] =3D p_hwirq - 32; /* SPI offset */ - fwspec.param[2] =3D intr->type; + fwspec.param[2] =3D hwirq_type; } else { /* Parent is Interrupt Router */ - fwspec.param_count =3D 1; - fwspec.param[0] =3D p_hwirq; + u32 parent_trigger_type; + + if (!of_property_read_u32(parent_node, + "ti,intr-trigger-type", + &parent_trigger_type)) { + /* Parent has global trigger type */ + fwspec.param_count =3D 1; + fwspec.param[0] =3D p_hwirq; + } else { + /* Parent supports per-line trigger types */ + fwspec.param_count =3D 2; + fwspec.param[0] =3D p_hwirq; + fwspec.param[1] =3D hwirq_type; + } } =20 err =3D irq_domain_alloc_irqs_parent(domain, virq, 1, &fwspec); @@ -196,15 +220,15 @@ static int ti_sci_intr_irq_domain_alloc(struct irq_do= main *domain, void *data) { struct irq_fwspec *fwspec =3D data; + unsigned int hwirq_type; unsigned long hwirq; - unsigned int flags; int err, out_irq; =20 - err =3D ti_sci_intr_irq_domain_translate(domain, fwspec, &hwirq, &flags); + err =3D ti_sci_intr_irq_domain_translate(domain, fwspec, &hwirq, &hwirq_t= ype); if (err) return err; =20 - out_irq =3D ti_sci_intr_alloc_parent_irq(domain, virq, hwirq); + out_irq =3D ti_sci_intr_alloc_parent_irq(domain, virq, hwirq, hwirq_type); if (out_irq < 0) return out_irq; =20 @@ -250,8 +274,7 @@ static int ti_sci_intr_irq_domain_probe(struct platform= _device *pdev) ret =3D of_property_read_u32(dev_of_node(dev), "ti,intr-trigger-type", &intr->type); if (ret) { - dev_err(dev, "missing ti,intr-trigger-type property\n"); - return -EINVAL; + intr->type =3D IRQ_TYPE_NONE; } =20 intr->sci =3D devm_ti_sci_get_by_phandle(dev, "ti,sci"); --=20 2.52.0