From patchwork Mon May 13 11:45:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan (OSS)" X-Patchwork-Id: 13663371 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E6D49C25B75 for ; Mon, 13 May 2024 11:37:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Cc:To:Message-Id:Date: Subject:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=CY/Yd0DvbIiztRld3U2P6rZgDugWR0XyygkLjpzEUcU=; b=COpjhGAQxGEROw pVH/Qtt9dXfBD3qpHB8KqY5/SF3O0O5lo2oHZbJFoUozLskZKPa+xJPz9IW5y85kcY2fm4K+NlvtM C/ZGZPYIG8l86RS7JeDoHdo4f/wEmMnL4PcYZ3QuuDr/rTuX8P+ebLR75be4EH2MCNzGn5xDjAUGD pjyeZGNtkmcng4DFRCERZdCaUIEvqVp4cJXCTXfloXgUloq5E8+C2EGKdY4Aafe+0OAbKpX00k1pJ MVkdBxCS8yNMQXW/w/4UkAg/C0TULhoeyKhyYAQViaYn4vs8ggWrt2sLcGyVP+jFl4vhYjICraSL0 aYvjM/WpBId/QBgKpemw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1s6U00-0000000CgDf-2Eye; Mon, 13 May 2024 11:37:44 +0000 Received: from mail-db3eur04on061b.outbound.protection.outlook.com ([2a01:111:f400:fe0c::61b] helo=EUR04-DB3-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1s6Tzx-0000000CgC3-0Ipv for linux-arm-kernel@lists.infradead.org; Mon, 13 May 2024 11:37:42 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oRKl81BEim9Lsy4vJqB0ijK6GHQt/ysnbW6qc4ZBeKLUKaqxGfm73K94J61Mgov/O3cErENACdrnujTK2LxF46O6nDdq3BUWHCoHvje7R9yG231kcjnyV18C21FxxIrFm0yZsOF0+xyI4vR2o0fl1z3q2HldWtUnhsDDl99KtPT5fO1JdrKkBACL/+5gI9vJzw3N9ZAv8dCX0SGdiXp8psCGrVGjrM4RnoVTk4XfTfGtfNm3ststxZ/uhLMUl2lLi01NJ576vkzizgtyVoBz0f8/FIacQEBxJjZcTyToKrmx38m2l4oSXH5KOI8B68Gmz1O3xskUzlQ+AQaJ2u8Egw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=FE0zoqYXgn/S7dyRu8cpLHzsBHk1W1NnD7Uog2RpdGE=; b=c83mgBcO5lgy4Tol1eJtMCSdkoB2pUNoO0psNTQ2GHjoMvFeBdctzFBVn1u/pHGOvd/JVD2SFYrBKaHYFGRLOXeUmNGm/8GO0G2McRWMQV1VsLt8K/e3U45NrIwVG/ualCWy1nHweBUoSNKIGQOPTG+IIfwSsTQmHHck0m6p4p5IFqz8nfuxnSAwdYfW8bNM1nhKlhDZ2kepgxndFY2ltiuIg2cRESCiWuePoXRVf4KnmuIGeqKCfFp/0Cbz0xTVLmKebparz2bwTpV71SB+zwGV5tTqPyvDdKaHz+8Kg+S07K43bqN8cA7dhdQ+UW0SRm7QpluV9qT1Ie2PNb70tg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=FE0zoqYXgn/S7dyRu8cpLHzsBHk1W1NnD7Uog2RpdGE=; b=haTdEOv5VFnpHL890fCIocBxCe6QQhDkoMIwpNBF/TPq2t1ohGso29AYAtE1aBLM4h2l2VHqu9QU1SiIGGXFWaHr/KfbbkXR8DKzqFhyKnvCbVPasdglJLkFZrd7SUNznMBwSGgzM3guLWTtr8tV0IqwkloqnSprkPbMag4tohQ= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=oss.nxp.com; Received: from DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) by PR3PR04MB7386.eurprd04.prod.outlook.com (2603:10a6:102:85::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7544.55; Mon, 13 May 2024 11:37:29 +0000 Received: from DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::d30b:44e7:e78e:662d]) by DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::d30b:44e7:e78e:662d%4]) with mapi id 15.20.7544.052; Mon, 13 May 2024 11:37:29 +0000 From: "Peng Fan (OSS)" Subject: [PATCH v6 0/3] pinctrl: scmi: support i.MX95 OEM extensions Date: Mon, 13 May 2024 19:45:23 +0800 Message-Id: <20240513-pinctrl-scmi-oem-v3-v6-0-904975c99cc4@nxp.com> X-B4-Tracking: v=1; b=H4sIAFP9QWYC/33OTQ6CMBAF4KuYrq3pL6WuvIdxAe0gTaQlLSEYw t0tbNBETWbzJnnfzIwSRAcJnQ8zijC65ILPoTgekGkrfwfsbM6IESaIYCXunTdDfOBkOocDdHj kmDLKCeG0UsKi3OwjNG7a1Ost59alIcTndmTk6/a/l4dgsBUXFGqhwF781J9M6NCqjWIXJJHfB ZEFZbRudKlB19WnIN+FHz/ILBQNq2mhGkVrswvLsrwAk4untjgBAAA= To: Sudeep Holla , Cristian Marussi , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Linus Walleij , Dong Aisheng , Jacky Bai Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, imx@lists.linux.dev, linux-gpio@vger.kernel.org, Peng Fan X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1715600734; l=4600; i=peng.fan@nxp.com; s=20230812; h=from:subject:message-id; bh=ZDknhd9PRJU61G21qRUE3Hlk6trPRSU4JWdw1PsIP5I=; b=8imq305evS1sLly9eush0gXreWQj+er86Q7o3whbvYiTC8JMTJjZJDVQJb+ovJq+IFRBRAIY1 JBtGUcH9kiyBLs3iWbLPLua1LM4pdleu+4AjsLn0wdvErXzGMRasZIY X-Developer-Key: i=peng.fan@nxp.com; a=ed25519; pk=I4sJg7atIT1g63H7bb5lDRGR2gJW14RKDD0wFL8TT1g= X-ClientProxiedBy: SG2PR03CA0089.apcprd03.prod.outlook.com (2603:1096:4:7c::17) To DU0PR04MB9417.eurprd04.prod.outlook.com (2603:10a6:10:358::11) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU0PR04MB9417:EE_|PR3PR04MB7386:EE_ X-MS-Office365-Filtering-Correlation-Id: 593758ae-31ba-4b63-38e1-08dc734111a0 X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|366007|376005|7416005|52116005|1800799015|38350700005|921011; X-Microsoft-Antispam-Message-Info: =?utf-8?q?4rlT0crbwdqf8/+ESxYXm3pPbaDdAg3?= =?utf-8?q?cSsEy7G8Zd2egJR3/q6WrZYoNsv84cqzQgg5rWdmY6VMrJintiHFBjSqojTZNRWwW?= =?utf-8?q?w5zEZr3ES9dTtOiLfPlDBuBAw8mLRIHfP10G1TajOhpOgtB3W3YBwFpQpFeNGEF2f?= =?utf-8?q?N+IK8uNkrHy42ANGEXUoDs2nkGw/SV+Xy1WWtyM0+E2JvxtTISDsR4Avqipto3Jme?= =?utf-8?q?Em2n3Q9bCPdI8x35a6EN0E1vKYlK+LDfzl2Ie1UiSIBfjz3GNWzT7muv5LaYJPRh7?= =?utf-8?q?f63ViNR4sXAak4ViSoPC23jA9EZ4lCg9XroZXETE9lT4Ggn2TI3k50PNZBx4V2hXv?= =?utf-8?q?Nm15TyHmx7Ep1pEqZI0Z4SunSNPVh3/Qb8C/nVOtfiYkmwYK9ErtHOwMucaetqvmU?= =?utf-8?q?tNfNVJRgUtJhvGG7XomG8CUKjRT/m0RIFfhMlucuTqXhTSKM9pzDgfu/MIcX0VkpC?= =?utf-8?q?Eto6uKFqOYyXM1eUel2Rubtmu81D3UBgMuXt19ykInuugbNGnscKOCo/Z8zgaEnjJ?= =?utf-8?q?rvNY9muQMjGPORYAR4V0/Nwy1D0IRQNwPkqQc2mQoyJ8AdNhpUEkhRlT5cX1MVbg+?= =?utf-8?q?vkq3friZjMv2V/mu2nv0JyM6mQ9cu5AsHV3peBOEp+dYfCK+hiH0XWphyPcDXRBrq?= =?utf-8?q?+/m0S6MIZhmW9XJZw0jAaZK5z1t9QAoeG8C1+H6DBGT/KYMYc7L9eHfhoQk0O9nuY?= =?utf-8?q?H+di3ZYQEfc0snXRIJJsr+YdWmwrLSlF+QFYnriM7mg5hzWwlV5uJq6JqG9bBir0+?= =?utf-8?q?2eD6GbWNAgBe3dG6BMohSg08EhVo1J1jYCFwBpY5ZECOaliEqX7Z5w/SqRUUHlYCC?= =?utf-8?q?fY8BBVXltALJ5gcQNOzNfZfnJGc09SQ1s8UrFYs5hNO2lDXPs7cIEvni6lXhMMlYj?= =?utf-8?q?5EURxIpOXIeC5m8NoPzglHUZRMCcbdX7dfgyJ0bZSQN+d1dXMk3AZEMGj+SHfdFL4?= =?utf-8?q?Okk00cZkZSrCkA5lNhq11HnzZH2mO8+AVFMAKbOoZ7zamGCZ2RetXI3KWFYHXrJZr?= =?utf-8?q?5yD5AJgDCOmywNTBQPbP6ZHZddKVWjIoL6vVQ4CoNoGx6ArJMeDVxQOdDZoFOYVo5?= =?utf-8?q?5PypZLN58sQq4wU2nXTnJk0oeiO3RrFLBuJzXMw7fdX9mhpnPAzMn1srp3Iuc2/Cb?= =?utf-8?q?q5obp7inUZMIM/+TageBGOI38esWlwJO7GLngh2KxrPCKanMbFvKOZR9eHP1Tm2LY?= =?utf-8?q?b2EpktPQI8BNxE+Nap9ULzWzwBzXT2QQGm5gmoUHkd6GE703Vz6lmDBls=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DU0PR04MB9417.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(366007)(376005)(7416005)(52116005)(1800799015)(38350700005)(921011);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?7uNpDzUH6IRe/Qize0KplpUYjmD6?= =?utf-8?q?Lq+sDj0Ur4kppDel3p/lsuq3CMfS8W6eW2U9hYj4vQwxKEu+aTfTM6B827TH5IAWW?= =?utf-8?q?Ull31I10JudK/mNrWrrZzS1jHZmBLHxwCov4B9LQImCM0KqrFgnVSUlRECEXzMPVg?= =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q?8nQXq7HpXchkcJAAb6el/WqjwU4+zlF5K/XgIuus6V+BGcIZNJGpnt52Oq8Q0Ppum?= =?utf-8?q?Bu1UXCd6lQi2fX9HzfL4trD7OKyv+sHshiAVUbBd/H+QNqeuQe95yHdzDZQz582/u?= =?utf-8?q?sJ97BhUfC1xOsJk0mggltWRFYHgQFgCKzA82sTljRYDSq+nI187iBOoaQZfya7euW?= =?utf-8?q?OT/j5H4PWTQNZVqh/0Z2GGOlnwvULho6DdQRwgh2tLXFJgtFHL3u3PxTZqyn6UXfQ?= =?utf-8?q?jtPgXIs/6xyKyHCK34NBfNv/RJ+MXlmRK/yhZ0cW0a+2sZCDieS4bn+aEuMBeAO0M?= =?utf-8?q?Jwtx80/PN+IOikRt65P6KrzR7D9qWtBeCR4pSwCBUk+5n/OHOGO1MnYLzoxLX4NWL?= =?utf-8?q?URBXlcDXJhBhbLGmKOFWwWiS2A6LnTFTcw9QbBRPdPXAPnLlkYd3sz9Lg3XuDvSY2?= =?utf-8?q?bSPVpMKE+neS19cmV0LdscAvd07RA/ulK1hb+tknXwdc99yCeBucZXc/hEJMsiVyp?= =?utf-8?q?X1OYMl7LdvJF?= X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 593758ae-31ba-4b63-38e1-08dc734111a0 X-MS-Exchange-CrossTenant-AuthSource: DU0PR04MB9417.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 May 2024 11:37:28.7668 (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: PJh1hTA8qUARkf0vPxlZWaQFUASfmUrwqpZA7DWW0sQRagTXjuFVtwUUpfAG7mFN+ExMNk+MFOqE+yYvs/FkGg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PR3PR04MB7386 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240513_043741_320420_B1F76A8A X-CRM114-Status: GOOD ( 13.05 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Sudeep, Linus Is it possible for you to pick up this patchset earlier if no major comments? Thanks, Peng. ARM SCMI v3.2 Table 24 Pin Configuration Type and Enumerations: '192 -255 OEM specific units'. i.MX95 System Manager FW supports SCMI PINCTRL protocol, but it has zero functions, groups. So pinctrl-scmi.c could not be reused for i.MX95. Because nxp,pin-func, nxp,pin-conf properties are rejected by dt maintainers, so use generic property 'pinmux' which requires a new driver pinctrl-imx-scmi.c The node will be as below: pinctrl_usdhc1: usdhc1-pins { sd1-grp0 { pinmux = ; drive-strength = <0xe>; input-schmitt-enable; bias-pull-down; slew-rate = <0x3>; }; sd1-grp1 { pinmux = ; drive-strength = <0xe>; input-schmitt-enable; bias-pull-up; slew-rate = <0x3>; }; }; Signed-off-by: Peng Fan --- Changes in v6: - Per Andy comment to v4, drop imx_pin_group wrapper; assign sdev->handle to handle first, then check handle. - Rebased to next-20240513 - Link to v5: https://lore.kernel.org/r/20240508-pinctrl-scmi-oem-v3-v5-0-6f2b167f71bc@nxp.com Changes in v5: - Added Rob'r R-b in patch 1 after addressed the comments - Per Rob, use of_machine_compatible_match for patch 2 - Use of_machine_compatible_match for patch 3, and enable COMPILE_TEST - Link to v4: https://lore.kernel.org/r/20240505-pinctrl-scmi-oem-v3-v4-0-7c99f989e9ba@nxp.com Changes in v4: - Rebase to next-20240503 - Add pinctrl-scmi-imx.c itself get pins and scmi pinctrl structure to decouple pinctrl-scmi.c and pinctrl-scmi-imx.c, so drop patch 3,4,5. - Link to v3: https://lore.kernel.org/r/20240428-pinctrl-scmi-oem-v3-v3-0-eda341eb47ed@nxp.com Changes in v3: - patch 2,3,4,5 are new. - Rewrite the binding, drop nxp,pin-x properties, use generic properties as Rob commented. - Switch to using pinmux means pinctrl-scmi.c could not be reused, so add a new driver in patch 6 for i.MX95. But pinctrl_scmi_get_pins and scmi_pinctrl are exported for i.MX95 usage. - Link to v2: https://lore.kernel.org/r/20240418-pinctrl-scmi-oem-v1-v2-0-3a555a3c58c3@nxp.com Changes in v2: - Rename nxp,imx95-pinctrl.yaml to nxp,imx95-scmi-pinctrl.yaml and move to firmware - Merged patch [1,2]/3 v1 into patch 1/2 v2. - nxp,imx95-scmi-pinctrl.yaml only has patterProperties for subnode The pinctrl will be as below for i.MX95. pinctrl_usdhc1: usdhc1-pins { sd1cmd { pins = "sd1cmd"; nxp,func-id = <0>; nxp,pin-conf = <0x138e>; }; sd1data { pins = "sd1data"; nxp,func-id = <0>; nxp,pin-conf = <0x138e>; }; }; - Add pins enum, correct description. - Link to v1: https://lore.kernel.org/r/20240412-pinctrl-scmi-oem-v1-v1-0-704f242544c1@nxp.com --- Peng Fan (3): dt-bindings: firmware: arm,scmi: Add properties for i.MX95 Pinctrl OEM extensions pinctrl: scmi: add blocklist pinctrl: imx: support SCMI pinctrl protocol for i.MX95 .../devicetree/bindings/firmware/arm,scmi.yaml | 9 +- .../bindings/firmware/nxp,imx95-scmi-pinctrl.yaml | 41 ++ drivers/pinctrl/freescale/Kconfig | 9 + drivers/pinctrl/freescale/Makefile | 1 + drivers/pinctrl/freescale/pinctrl-imx-scmi.c | 579 +++++++++++++++++++++ drivers/pinctrl/pinctrl-scmi.c | 9 + 6 files changed, 645 insertions(+), 3 deletions(-) --- base-commit: ca45a28e860e3ed34cff0ce5211014d535bf6d6d change-id: 20240428-pinctrl-scmi-oem-v3-12130031a74d Best regards,