From patchwork Tue Aug 16 12:55:21 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan \(OSS\)" X-Patchwork-Id: 597636 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 CE4E7C2BB41 for ; Tue, 16 Aug 2022 12:54:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233669AbiHPMyL (ORCPT ); Tue, 16 Aug 2022 08:54:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45424 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233076AbiHPMyG (ORCPT ); Tue, 16 Aug 2022 08:54:06 -0400 Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05on2084.outbound.protection.outlook.com [40.107.22.84]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 09B43696D3; Tue, 16 Aug 2022 05:54:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YIFlE2HrT3Gkf3S13I/KTr+HMVx1m30fxby4oa21kBQIUfFXM0YyjcoFBQ+aVMh9SaHCKc0SEfMLqem/lk1Zn92TXrk0NsOYQV3OnzD26xXegJRRIlMD5/Gou5Z5rB2gYzXM8zt38wSKTtzm2ekZ+MSZhn30FNGD8FobuKT8+gAAjFU2U3S9woniHusxFizXLpU1+lteFwOTRcK3BE0EfSuMG+WWcx/g/Jwji4mT5DBcaDCOC0ldmhcQCQqIKOsZdQa6tRxiyP64ai4zOsARkTG0ythoT1Ma1jPO8B6Wo7HByqdQlTSh9Oe6L+jXT0FLgRwvBrJ57ZSylZYmMNefdQ== 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=LdaY/RqM3w3mSUnvQiRuCC2mLKvTQN8CuYVnhKckT84=; b=eBL37KaTHVRxjNACmTkpm+VJjizWn/+aH6ZlpcB7eEINcIqDrpyk7aVJbrzSkY4rOH33VwQ27R5wZd/4DX4G7jOTykRohcWejXjcM3Um7n13JB48zNTC8GPN0E67v6Ppcz/DABmrY22S8jjQeNNc2Q3y2pdyEGneQGfUHHge0C/E19r+MbOzRetWMQNnJqt8alPj2jV5rYJQCnDDpNKB0ajIL7wkwES+btjkR4zOT8j3BjP+nq/oUH5uKfMOrgLzkRPLsW7uJQ/d7nlkidqi5gMYuiTN3RexjkkjhDwVpw9tuUg+cwbHS3ybj4pALOZK3DxQInRWKGhD3mfhrbus9A== 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=LdaY/RqM3w3mSUnvQiRuCC2mLKvTQN8CuYVnhKckT84=; b=XdPwrlVllWhozTv/tEtwBBrCl3sni0TFfnJ7OiU0IXz+RKVGODuO8WEExAGC3hVeqVytPOM+XI1K/2eKzq+4QcEi4hzDJGNRkk39M5INHeM+6TeohDPghVo65RfWCIOyuIjtX6jj2YkD+PGTVnCxTOuZkzIMYPof31MCLbVTsDY= 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 DB8PR04MB6666.eurprd04.prod.outlook.com (2603:10a6:10:108::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5504.27; Tue, 16 Aug 2022 12:54:00 +0000 Received: from DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::3c6c:b7e6:a93d:d442]) by DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::3c6c:b7e6:a93d:d442%4]) with mapi id 15.20.5525.011; Tue, 16 Aug 2022 12:54:00 +0000 From: "Peng Fan (OSS)" To: aisheng.dong@nxp.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, linux-i2c@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, xiaoning.wang@nxp.com, Peng Fan , Krzysztof Kozlowski Subject: [PATCH V2 2/7] dt-bindings: i2c: i2c-imx-lpi2c: add ipg clk Date: Tue, 16 Aug 2022 20:55:21 +0800 Message-Id: <20220816125526.2978895-3-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220816125526.2978895-1-peng.fan@oss.nxp.com> References: <20220816125526.2978895-1-peng.fan@oss.nxp.com> X-ClientProxiedBy: SG2PR01CA0128.apcprd01.prod.exchangelabs.com (2603:1096:4:40::32) 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-Office365-Filtering-Correlation-Id: e8a69695-8a7d-4db6-de19-08da7f8663ca X-MS-TrafficTypeDiagnostic: DB8PR04MB6666:EE_ X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: lB4oPSmSae+fclMqyxKs0xa6oX6IjtukZKK/XRQ8vG8l6fv78MWfs2Uli1i0Qu0LaBl/ncQtOrlYXrGxnWXL/3HKf9AI+Ou70q4kWbZcbEWQyJ6ZcEgmeJeP+hF/0KCv8ozJHw4+vjsk5DAJhypx+siE3RoJdpSWZnH16Uj8uH8Sb8NnXsUfXYBPIWwZR7CYlt4Bq/wwPAx5Ex6wwbYgTbR8QbneWNGRGZYd3s5zcW2rPAl8gtX2x798cpyBw4nXATh+4dCmC19ZxXYFXV0s7NIS4EN0KLZ1eYXn8fgaGNaDDA/SwLZXoaVjC7s8/1QdGR57GQqCoSWq4VAA7Yg45v3mJOSDFs9CbUoTArspK0pSUITrtfhUKLAlluTHGbJSd9p5uWG10H/Id6UtGPI6hfqcyqRgZGeHSe36dAIR74Fm3SW6oxpCyHyx4JyfEvKsA6Lgl2LSvSo/cMD8dWXB40TmfO4WufXwDwwuaV/mEcGua4GruUjhrplVeELetHAKlj/j1prI6tvH1BKekAEhefw7JhUZmwpNx/g/jgHTXY7+tBV+YzjAEiK4EHjiNV5NlZcO52rR7o+gdH1Gfh8fznwZeWOjFJl/i8BLcPiqg19TdKBzuM6yr/M1JyktJtT4ZqyficBwvjW7gHv6vwUySEkz7lSzgXdjyvClUNzumMRZTpjIEuieZOxe5QfAxYJzP19Jx3aU7B2mQwu/knrl+9AnZ+F5qH0cyO3DtOQvFhXaPFZeYgjwMQtv91YhyUrgDophe65zCm8ryULkgYuPzcNyr0QRMBWsBISoDI0TVvlVxXaUFqaTYC148nrkHnuw 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:(13230016)(4636009)(376002)(346002)(136003)(39860400002)(366004)(396003)(8676002)(316002)(66476007)(54906003)(66556008)(66946007)(8936002)(38350700002)(5660300002)(7416002)(38100700002)(4326008)(2906002)(86362001)(478600001)(6666004)(6506007)(52116002)(41300700001)(6486002)(83380400001)(6512007)(2616005)(26005)(1076003)(186003); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: UCqCs+3b9pggWvu7emL8Zn+gvq2d7OAbJcXXYOwQa+Ed9gvBhPxECqGacGgcBUjuNdco9wD8N6LooaxPSl736jGhaUcHNHltcab2bUARFtB3QAsIyNA80S9YXN9iweqBs+NniiaNPJqAt05BtNwUWMLsmunSEaGGvX7Y5PQ3CNijGEhseLZw7EwpAL8f3tELQmVdieyPfXneRSJOApL+tR9fghaxfwziFg2FScT4MQ6X14S8Mjsy2/jadUasrmtAGPtV9l4L5jX7rX924STUSkhv+8kRNMzM3F7NA/nQlB5wv5UAwoBt12+pitoEsq7WC0ROcnqKnq2m4n6rLor6PNzenNqSM0wVzWuTE8GrhiFEQLi14CRNObdvq2kuM6KD2O/GkvzHuc6ty7hQ1p92eQkD7E5+3I4kNIWJ2VhEXI4/TgsbSiMiUOTJ+NUr7jpmWIhbWXrrpK1WoZmKusmmbuL2OYuAQYOibsCD+bi+i8f0dm71VSXu39hPDFsyE/JhmZBs9Ukg2gcsi2xgvRw1UdGm/2v0+OvGGVvOY62W4pOUYt0oreHWwyqVgOIrhGNC4eXAbFAg/DH2OjP+y1wO+25cQG2nK1/U8YpfbrGs6mvo1KLPqUAFhepap3LU+TQ0xCoifw+cOHZuE0D0Y+sLZXhkup0bHEbLD4YkMH7GzqvpKIjc7EnKvHnAGDnndXg0l6xh/qlW9ZfoXyNlUUQuMumiOQmfmhSaOgI68RwJfyDKK6hy3niE6Xynu+alZigXyw1NpWyK5Tq78xSO8i3rViuugAaVSOrsCKfDGV0yxd0p5pkxFC7ZRIaO7vsMgq7B9+Y2WgHquYZJQTSJpGmFqn8kEhgp83IltF5Pieubqg6BFyOdm9gLNViYsy/P5kS6DMa4mNRcnb4rYRz40/RjHuUn8sc4J02Xy8Zrb5q61pQWQB0E/mvsi7KCX8W2JPeogWtDMQAB8HCcxIE6cTn/pBjhqR7A7uRkSf3iy7r+q5PjtOJseN4ODi8nh+8x20AtYtUtm1+qxfTQrcKh9bp2LMLqZ3uqLBXAai4PtplkrJNmTSzjZVzCHp4GJSBJAMRS2K4HHPMiMQ5huJSbkACC4aDx1f8wUWv6UsMIMq5kcdlT55fsymbd0YkH0C7h8G3hW+VOIXKeMUiaZ2kY9O/MnUpdtwm1+5eozWlU5NNFCBR6wpO1+cBvbKE1wOw+Fu0AQ0d8avhW05mFZK6U2d2tucY4S8916/PDlEB1f+CZQuMrJKIe092B4uMUu31VQe3++MHM70t5ZQyZSdyDiINIjHNoOnLLblBtz4H9TlreYWrj/c35KVZoLq2nva3zMmNpI216NGRHJfT9Va0EJO3lXHzuFmCCF5SgkkTlFI6LhuyRhQhm+1dq0tXf3RNUl1pNOhcE3W2Q3VPN6EHozcggcGgIeo7+qlGLRHpVCXAirb10NKqyjgeuNARgrAlI8xbZb+/jeM/DOW6qG+hHGCU10tUvAjvxJbhMwMo40uTw/pG7RXrPftLgjQdpTQwoV6QMAT8t9JVcMrCKxREs1jUc7glWLKCzX2ziu38/Gus0mZn02CAL9tHHHasIAt0mbqDu X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: e8a69695-8a7d-4db6-de19-08da7f8663ca X-MS-Exchange-CrossTenant-AuthSource: DU0PR04MB9417.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Aug 2022 12:54:00.6050 (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: AO6Z+ObySA2ubCYT06gPaU6Y4rFIY4b5+dikW+9vZtFCQGD2cB4RdQ7CxYR2Ol3XULxCxn0DEU0k0u+JACpmYw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR04MB6666 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Peng Fan i.MX LPI2C actually requires dual clock: per clock and ipg clock, so add both. Signed-off-by: Peng Fan Reviewed-by: Krzysztof Kozlowski --- Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml b/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml index 529bea56d324..e42e35003eae 100644 --- a/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml +++ b/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml @@ -37,10 +37,12 @@ properties: clock-frequency: true clock-names: - maxItems: 1 + items: + - const: per + - const: ipg clocks: - maxItems: 1 + maxItems: 2 power-domains: maxItems: 1 @@ -63,5 +65,6 @@ examples: reg = <0x40A50000 0x10000>; interrupt-parent = <&intc>; interrupts = ; - clocks = <&clks IMX7ULP_CLK_LPI2C7>; + clocks = <&clks IMX7ULP_CLK_LPI2C7>, + <&clks IMX7ULP_CLK_NIC1_BUS_DIV>; }; From patchwork Tue Aug 16 12:55:24 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan \(OSS\)" X-Patchwork-Id: 597633 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 54200C25B0E for ; Tue, 16 Aug 2022 12:54:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234926AbiHPMyu (ORCPT ); Tue, 16 Aug 2022 08:54:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48114 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234976AbiHPMy1 (ORCPT ); Tue, 16 Aug 2022 08:54:27 -0400 Received: from EUR03-DBA-obe.outbound.protection.outlook.com (mail-dbaeur03on2046.outbound.protection.outlook.com [40.107.104.46]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 15B8672B5D; Tue, 16 Aug 2022 05:54:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WmA3bAKf2FqgVRDchXhPTvxGSEQFpdSFvBUTVoIvT+S5CCzGtOQ8U14YkHIadqJcXs7jSuQZCr2N0PdmlhzsAQuP83z53cKUb/Wh1nXktqfUpbJ9dg2ahM3GXPjV55zkLD3/tx3YrDss6b8KjcuhVKmVCgqDzj02/ZHDf66psu6j+yQSlwLY6W4gu8rz3Xd2QVNWMOty2i4JVv9mQJ6v2LdWkQMuwV9ab3efoL42+5uw1mlR3xjiqWfJZpP8VARpJWgEo6JnHAm5hNASmdmSd3vSts07HJ3G4ZXQu/hx699sd0LyJxIT83/PQLi82vXQINnFE1jJNt+rdhry8i/1+Q== 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=FNgSPifPVT3FOihHeEgcJJztqpzDyRC7Vp2xf41BsLM=; b=EtSa3Qh40BqGkCT97iVWWwngPrsNDZsEzUYN0s5X9oj5ma1wKTeFHTyO0f0CFT8hnjnalRFfgMrYmQMRhuGvuokMXK6uhCX04eiDACOoUyLuni6pDPEqlUCdrrFC1r4+yR8cgU1NrF7Bmb9uTXYZXgrlXKpByLbHFmQgFQGLHqfByq3Fb2npeIv5RAK7GeXV99pwLF+AuPPQutxv7KlWPonJR7pt495mppaUcE8kim+wS9oNfBhwBG+vqNMSS+dmKekOutpAvlXb8DOyvMDqK5BkNA7TDpFcaiNk2P6EQ+LDWxnvRAXa+4Kgop89gF3leUC6vreBumx8EdcO4SgKhg== 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=FNgSPifPVT3FOihHeEgcJJztqpzDyRC7Vp2xf41BsLM=; b=hIXVO1Kiz5Dl+ftBS98xbHnE08236fHW/6GDB63gAk7y1y9ElixdYtiz7COS1PaADJbI1h/lhP3jsRl8xbobS9Xer031fyj1zmcoh3p1LYfsDQw1qo54nrg9E1GVmOhefOQ+cLYZ4Jd/ZThAUKHX1rYjLK7XztWvWbb6laRBmTQ= 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 DB7PR04MB4060.eurprd04.prod.outlook.com (2603:10a6:5:23::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5504.28; Tue, 16 Aug 2022 12:54:14 +0000 Received: from DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::3c6c:b7e6:a93d:d442]) by DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::3c6c:b7e6:a93d:d442%4]) with mapi id 15.20.5525.011; Tue, 16 Aug 2022 12:54:14 +0000 From: "Peng Fan (OSS)" To: aisheng.dong@nxp.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, linux-i2c@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, xiaoning.wang@nxp.com, Peng Fan Subject: [PATCH V2 5/7] arm64: dts: imx8-ss-dma: add IPG clock for i2c Date: Tue, 16 Aug 2022 20:55:24 +0800 Message-Id: <20220816125526.2978895-6-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220816125526.2978895-1-peng.fan@oss.nxp.com> References: <20220816125526.2978895-1-peng.fan@oss.nxp.com> X-ClientProxiedBy: SG2PR01CA0128.apcprd01.prod.exchangelabs.com (2603:1096:4:40::32) 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-Office365-Filtering-Correlation-Id: e5f175f8-7a0e-453a-33a5-08da7f866bed X-MS-TrafficTypeDiagnostic: DB7PR04MB4060:EE_ X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: iHYFxd31K+qfoYaCKbrUDNFVKa9CgLxklWppw2PS6AiqgEl+JzIPsH5m6+bFQ9UeEYcZRSgrdkrq5gWx8VibnB1nC5p1yK12DgZRTdhpNxWAKhdm4bKKVPH/t2DODb3A+KXE0oEE81bRmZb7WJF/29YYDWqdWL6Yqgu9zsEoH+O73BcRmN6w/zhM/Nmv6LWgiXhKppb/USzXKZIx3hXIgeWluKgkqzx2etXPayf/qRAhLEOicOaRoKiLh0/z4EXyJ4XwEpBvRvhvgu658GmGsvO3bD5vL2VTHaDErUHlDxIpiE9/C7gTUMOeoXzMIV/kPWv2V0Amsyc6NSMnj5TSb9qTkM3UFTT4/RuX+z4mOTI+1adLZNhByichqgj+CRvK5UiLtzGYm5/ptwmI99C0DYIsIRVj71uY9gHUy8UA04npK3cX0qxuCffy4qMk/dEXoI9a4gG81oRBgAbxlpeFtc2jmEpisuuhnuGK0jSxEznGmJyzGB7cklPypqEW3f1FnoAqP9F3aT7VFzaYKDXZ4a0VKz0mF+O7hZSwxL+POpWfBsf13h/pbeLkhngBFPxmSt6r8vEuokiqJ9893wZNMnhR04B9WVR6DS0lfwgyrSNBegWCFhpzyYAIOVVWY19ShNbINvIJG/KWHLCYlVYZqxqMeMV8O2iP6/gOjx/MHnbD1BsgLaXsiMmlKAzvjRKmn4073a4ZiCGml5tEQP5S0u4B6OcvEbcEVm6te3T9bFXy7wDqV0L3vEcSfXr+tVCKpEY0rWIQxRHzxfJoCRfGI4bj3ZZdAZLa/bvr/pMTV6pVceuKUR2ZpYYqvhDGoV2b 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:(13230016)(4636009)(366004)(346002)(376002)(136003)(39860400002)(396003)(26005)(52116002)(186003)(1076003)(2616005)(5660300002)(7416002)(8936002)(6506007)(6512007)(6666004)(41300700001)(6486002)(478600001)(86362001)(83380400001)(316002)(2906002)(38100700002)(38350700002)(66476007)(4326008)(66556008)(66946007)(8676002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: /8JmsBYqNwvJVflWxcJVX48lG7CdwmqPUQt4sTikj4YynO1Fvs+Fznd6mUgHoxxPM7chCro56Tq273rPrka3ewJR7N87uEFMo+Lw8XxP8nCu97k92/eSsPk2rKQljWejYcdIth72i7nwsLvJZQwJhdtz7OWw/YSuxHZnyxuxmjDA3EFx5jSHNZ3r6F+m8sCRESyE4a7i3xM4L2YNGRSM/arw4uEbFzK2mI/xpDfhCqSXecqGQbapvQoUGrvpYx1TnD2r+OhKzshX2rW8rCpgweial45dopNoIsL1nNxmwHldVsAcXnplm21YLEZPZJA9o/C2x9D5sj1kPa1ywqkaGAcIvu9j8ikq46GM8myu40cm49gWiuJfRyupF6EPT6CsI/l7hRQOs3vSPFS7mmfzh/oblWG9GHv+tMKL68B3gEg42tkzlkBrybCZSLHkraE7fTkgO61KsGJlUFAaDf6go/N0Efml7vs/ZratlSuuBPj7ZSEAWAOArSyFDOFTwBk5k6RzKBHh6m8lT2te+65xZf8pLAhWKPgVyB/9OTJ1reFUYhEIPo0zX+Msq9C2m9SCxBoBW1nAm5Hyl7tLFdvL7MUQt0JoLGi3IZG3D38B5RlsH8/RRek4xND95SHJNSQhebATYxlImi5nswgQsJ4PT+Objxoeiex9jKLOxOhltIS8bDqiq+KsYsJP+DolTZ4eIIHq1NP+11xDlqfir/Vu5K+RISCwbJo5KZG9G5Ds2yrAUCs61cR/eN31VPsZGsURtskrNMLDury7Cpk42F4DkfSOcok//+QI8nvjCTa+FLS/rKCcwGWNJEvL3iPDKP0O4e+EiW7P7sYNW5MgI8dmMqfYrEmCO1h/p9gidR0Nk9Kax0f30D8md8NkR0c6RR4DekTNHELqoHbhsWpUdHwb/9B/69MIkmz9/nNfZYEvDIvqaWIXdNpdaSBuo7v+oUAuJT45otoMwcqxIOtqXfvXONMgtsv25vjUfvVh3RN8fjMT/N6InXC1aL075bMsIjVx5/RALNVTTHWTRZt8RL7Yfr4kAoebI52SJfyFS9jg84QvpSs97StG4egTd4KdH4xLuQdmeTAUDkb8LgtBxxBvjxxaVow04jPrxsys69D24NUDNae6hItJ9/FfknOVFBz2wB+2LHveF61VXZ6VBv9lwZVsR49RBLpVYkXOdxXTr1gwo0mYlGyfUWxGpAoppAGf6MBm5JO+cOkxWMGeYzCm17EBGrDK8/xLQP/wxw1nUyGPnKjpIRcurSe2AXa2BK0cI6A6b8FLYFeoYVO+l/SItOzXo46yd8V50e2EjSDQF7KDbJM02PkGvssCPKEvRfG9VGvMev7/v/Ezo3B3rKJSEJvN7i1uQb0KB19nHHzIMVJGxpOtzvRbUlgZZgHCWvWWEM9EUeC4Q+RGSh5eLYqLvxf7EtnWJsXXiMraKIgWI0dU8u1+XMLzTuJ3PY8cOSz9AYeQ1NDE1DPJ/hQ3fkAHPyOYwVATojkOfUnKxRUNFa2gjY+GZ6c029JtayQTJU4Xyn4qDaAzOZsITRhmUggxIOxdFJiQc6ZX3BaCvQQliuZJslQpEXacYmC3JzbEgKKX X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: e5f175f8-7a0e-453a-33a5-08da7f866bed X-MS-Exchange-CrossTenant-AuthSource: DU0PR04MB9417.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Aug 2022 12:54:14.2523 (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: s4j4Pn6awbrYJ+Np/RfuzBpT99FQJCPZQl89ZYF/k7htwDIieRSTazEMBUeVYvTkwyiNLvmC0hRIjaVaWAu0tA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB7PR04MB4060 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Peng Fan i.MX8 LPI2C requires both PER and IPG clock, so add the missed IPG clk. Signed-off-by: Peng Fan --- .../arm64/boot/dts/freescale/imx8-ss-dma.dtsi | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/imx8-ss-dma.dtsi b/arch/arm64/boot/dts/freescale/imx8-ss-dma.dtsi index 960a802b8b6e..d7b4229bb4a2 100644 --- a/arch/arm64/boot/dts/freescale/imx8-ss-dma.dtsi +++ b/arch/arm64/boot/dts/freescale/imx8-ss-dma.dtsi @@ -111,8 +111,9 @@ uart3_lpcg: clock-controller@5a490000 { i2c0: i2c@5a800000 { reg = <0x5a800000 0x4000>; interrupts = ; - clocks = <&i2c0_lpcg IMX_LPCG_CLK_0>; - clock-names = "per"; + clocks = <&i2c0_lpcg IMX_LPCG_CLK_0>, + <&i2c0_lpcg IMX_LPCG_CLK_4>; + clock-names = "per", "ipg"; assigned-clocks = <&clk IMX_SC_R_I2C_0 IMX_SC_PM_CLK_PER>; assigned-clock-rates = <24000000>; power-domains = <&pd IMX_SC_R_I2C_0>; @@ -122,8 +123,9 @@ i2c0: i2c@5a800000 { i2c1: i2c@5a810000 { reg = <0x5a810000 0x4000>; interrupts = ; - clocks = <&i2c1_lpcg IMX_LPCG_CLK_0>; - clock-names = "per"; + clocks = <&i2c1_lpcg IMX_LPCG_CLK_0>, + <&i2c1_lpcg IMX_LPCG_CLK_4>; + clock-names = "per", "ipg"; assigned-clocks = <&clk IMX_SC_R_I2C_1 IMX_SC_PM_CLK_PER>; assigned-clock-rates = <24000000>; power-domains = <&pd IMX_SC_R_I2C_1>; @@ -133,8 +135,9 @@ i2c1: i2c@5a810000 { i2c2: i2c@5a820000 { reg = <0x5a820000 0x4000>; interrupts = ; - clocks = <&i2c2_lpcg IMX_LPCG_CLK_0>; - clock-names = "per"; + clocks = <&i2c2_lpcg IMX_LPCG_CLK_0>, + <&i2c2_lpcg IMX_LPCG_CLK_4>; + clock-names = "per", "ipg"; assigned-clocks = <&clk IMX_SC_R_I2C_2 IMX_SC_PM_CLK_PER>; assigned-clock-rates = <24000000>; power-domains = <&pd IMX_SC_R_I2C_2>; @@ -144,8 +147,9 @@ i2c2: i2c@5a820000 { i2c3: i2c@5a830000 { reg = <0x5a830000 0x4000>; interrupts = ; - clocks = <&i2c3_lpcg IMX_LPCG_CLK_0>; - clock-names = "per"; + clocks = <&i2c3_lpcg IMX_LPCG_CLK_0>, + <&i2c3_lpcg IMX_LPCG_CLK_4>; + clock-names = "per", "ipg"; assigned-clocks = <&clk IMX_SC_R_I2C_3 IMX_SC_PM_CLK_PER>; assigned-clock-rates = <24000000>; power-domains = <&pd IMX_SC_R_I2C_3>; From patchwork Tue Aug 16 12:55:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peng Fan \(OSS\)" X-Patchwork-Id: 597632 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 50D06C3F6B0 for ; Tue, 16 Aug 2022 12:55:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233533AbiHPMzR (ORCPT ); Tue, 16 Aug 2022 08:55:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50484 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234897AbiHPMyt (ORCPT ); Tue, 16 Aug 2022 08:54:49 -0400 Received: from EUR03-DBA-obe.outbound.protection.outlook.com (mail-dbaeur03on2043.outbound.protection.outlook.com [40.107.104.43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 27D8379686; Tue, 16 Aug 2022 05:54:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=O765fRT0zzLLzK45Cpn6GWnR8u8Ga/Jb7pO6ZBuyYvnnbfMY9utLfYeANyjMM8gALP6gIamIEgKy4RasNQje5fVennD4byw6or+iaO6hTeE21dPCK4jqpYSeU/5RxeWIyp1IVF6BqGgjUjtUmWgk0q/2F/mKi2GpB/kb714Zyypm/GWcafiidnlg6OAYRQBS5uHChxbTwHfhfRmMAA8nh9noQbp5GCXaSHOkvFrrOeMwGlX32/gla9AF8Z5fapBYTx6uuJlB0uFwFUeiIPusGKHv7M0vvrV3N33RvD7PkiFUWv96V4tHwbtZD5CRksgwnmDEUDVlSlZhGGN5ssPSQg== 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=13xC/FLAgjMG4RnHFo4wqFkUuoylu9YQ8xGdgGpvQCc=; b=XzqelBnAGnEksFiw/DQZuAPyJr/dupveA/zWD313PrjkJrgltxx4EQh9IVoMIfWQTz32h0b41ZUSF8UtgTXEhDpVd/jWmNgV7Dw/XshsJ9b7qJEsKQEdI3s0N1RYjofeyxFUFlC4vsEmDHES3AHv5q0M8DXYDb1DcKvBQp5fr7gGpLBL5dLg9Y5HVMHu0js/xbHctLVfeM8Y+J9ZYZKgnpA8WSNY6ZkJQKozEH0gLx/CCdiIxQ7pXZ7+77ip8hkJ09GeIVidqpeifW4Lhdb/9eHFmNiT6Q/SVxTWb95wL4I/8/ScdSt5poUP9/OGGyq1tlSatAHzjiNrZe6CSs6x3Q== 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=13xC/FLAgjMG4RnHFo4wqFkUuoylu9YQ8xGdgGpvQCc=; b=gTwW7QMl2A0zSdgut6PFGX/K2lXpO2VhH31Jy5h9dhzzvgp6c1PWBS+pbxCMkbB3spTl/dDwtjaxcv0cYK91bA2FWUOY9tre76f7kG/az1bSbUox2XgfwIUyiDMpISOEtJgRUvyyBN2hUF82H9kLN6wZbMcZt+W+Yex+2l1gKTY= 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 DB7PR04MB4060.eurprd04.prod.outlook.com (2603:10a6:5:23::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5504.28; Tue, 16 Aug 2022 12:54:22 +0000 Received: from DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::3c6c:b7e6:a93d:d442]) by DU0PR04MB9417.eurprd04.prod.outlook.com ([fe80::3c6c:b7e6:a93d:d442%4]) with mapi id 15.20.5525.011; Tue, 16 Aug 2022 12:54:22 +0000 From: "Peng Fan (OSS)" To: aisheng.dong@nxp.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, shawnguo@kernel.org, s.hauer@pengutronix.de Cc: kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, linux-i2c@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, xiaoning.wang@nxp.com, Peng Fan Subject: [PATCH V2 7/7] i2c: imx-lpi2c: use bulk clk API Date: Tue, 16 Aug 2022 20:55:26 +0800 Message-Id: <20220816125526.2978895-8-peng.fan@oss.nxp.com> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220816125526.2978895-1-peng.fan@oss.nxp.com> References: <20220816125526.2978895-1-peng.fan@oss.nxp.com> X-ClientProxiedBy: SG2PR01CA0128.apcprd01.prod.exchangelabs.com (2603:1096:4:40::32) 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-Office365-Filtering-Correlation-Id: 527366ed-cb97-47cf-5c62-08da7f86710f X-MS-TrafficTypeDiagnostic: DB7PR04MB4060:EE_ X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: yhsIcccT+sSNZ5k24PAAyjX3Jovx30AxA1ejZzX8uoscYkx9dDvFTyKyR6rEo9Aed92JgudAHXfFxbdFvs2MGrlS9fQuqAM0kfWje7XHwhCHy5gvKeJ2f+fL0iprFMkcnPZBFOAXBZnD6fG/w/K9GaNIgbsIZ/YKwIg/RCg7Z4AxNXbKGjv9J8Kii0NMp3qpAAumAG7RKMEdE9At9L59nRJNheRJ5TBpsVoEQbURwHtL0cvJVlBayNQS59AR6HhxpyyFm3W09n81kXqFN1G2beIeiVtCf0Dj4P30HgzvrYrdTMB49wDD6pGdIpCF6XLb+f/JyQzJi39LLHHazxnZoXxUdmjKGke5xzFftlllgYLlkoMDTjLYXmTkV5A6GNNpCRnY0lNlceZoMk4ShHkTyTg0fgIME5YSS+R0+zm2a44l59KnRpXwuVLzEUjrqomZU1TTkOS0ctu8kSecXVDiwHIDw76OnhDtKvjp9N8RT5qh25WPkrWZEDj6RvRRGHkRlkqAnu3qxFEmZ8DTmKl8El6CLczBY+N3o5KvpQYHHpy7sPyIySnNhx2YD+4VQOwSNmVljeycZ0PzKK0L1QkzlnFDSKuYHzw2TNAOh4Ow0wp2CYhnsuHXnv+vGK2xK9BKhRDvi7peWfBKNth3n7dxKRkC2UVbXaYRZ+eJmPKWTTbkAd6SVI5YPeNc9q3HuuG5+F4BUdcsCOc3QA/WLH/h3HFjZ7JJ2ypeFpuek63MyUjQ7UuD/NEHF9h2dI+NQqUzc8Tlk8wEIJf0xFrkm3MGCRgl43pY8+/wGGPSXeHZdRZ5L35srE6hz+niQQp84xlB 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:(13230016)(4636009)(366004)(346002)(376002)(136003)(39860400002)(396003)(26005)(52116002)(186003)(1076003)(2616005)(5660300002)(7416002)(8936002)(6506007)(6512007)(41300700001)(6486002)(478600001)(86362001)(83380400001)(316002)(2906002)(38100700002)(38350700002)(66476007)(4326008)(66556008)(66946007)(8676002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Jd88vxQKZ8lqgdgOToGetHqwNReerEJ8KVWhs83Qv5CZ1PxXhUsDBj7vGEOhxbfShfI34E8qZ8WdGKjtP/tqWeQ/rXX8BgDlfwyvFH1kYFuShDcKv9JFnFuHBVYqkxJGbo5HaoEST3z4Yxkg2Vp5djWDq6NxpIg4oj9Lf5cib5m52CqqAJhb/07zJsvyb2FnAOXb1Pg/ekgnI71kp+3U5RYSfS6bw7GcAeF2wPRofpHSH8GPTBr1Ivf4u/0TvxOujgGQuInLZGeU+Z1vdAQiwooG1O36/Nk+FnJykbtc1RM9dsbliOY0BqC6JBL3irufQDFCz6t4GN9x6xsXRMhnWVLmfds3zNuW6lpaTLk010SWBhACUuinmUdprfb9BkgwaR/pLrYWDc4RNoyUwn1nWkWwfNWLHhgFxLUhF4T7FgS8/1JHh9AjMMjrZEqHk7jL6hFI4OjbCiReWYpZLUGDAJv4/yW0/N0T8mRXl18VzStcKNEG82BU02MdE2b/QVO9wlUM3MrrQr/4tpTxilomntIEg9+i9w7IXbmyW2WE0lrlxwKDgjKauLRv/Izxg1Puh6DsYP7kyhfL2et21hJ5SVqX1zHv0I1/tekhV5zx9S2ztWrfa1QRQEDrEEAXNYiWRwly5uhXbAU6lZRfIYs7ibXHgoujgy9AuqOqD57+aZUfe45FEu+adFyhhRrxcwkwYxBUaUBF/OxlhBx1vS9fCfrscYBgI2oyVQMdTqZnHEj5z1Df8oN6ARjKHNBjENn3FVGfPSOrgyOws2cy2LSY2RqsuEAtzZFlMhrqMKfJTlz6J0BO/MXUATOXaK6wM1ToIBfJ3ouMYKRQq6QcLDqx4s0zO37L8T7lL8ILZXpdtZ6kZWnKdIpFAWi/xCRsqvNuTfxgNQuD4ikUBd9JfjWCbsFZdQ+y7GmNNly0JBZg2IRGOADztN7XHW1HT1eI0p9FidAXfuUSNRZ3LXgJPGzsOUp1fkCiFBn1n53+R0kz2av21sQ5EhF2qOo99hqtnF1ZAZbmrIsRKdQaRzMvrdbwzyjuO6SocCkNSpwu7eHbXiGJ5E/rGQ7cRySbQDTk6t3TDLV3FBR4LA1yqWN446ZNPTrBinWVCfGcb03HI85MEL+IO/nVZwE9KWVW5bKWnubARipEodt0E8aNNCnw5bLE8e4dt+BWHF+I+ONg7QEORdZjlPhGXBqpR1K3jJPU1IJZhm6sTfjKKQYV64p9qI72Ve20r8QIvHSrL2Fe9Jw6ONUm4wjoJIkXMQn9qDblZ4X504d6uj43jXoZQLN3tyQ5zpvfnSeoqwjvx3xSXXIRC3l+zmNuEHOgHn15CX1MeETILePKQIEeADr+Xi0iA7oT/Tsw1h9MiSKOQknzOPTVT2bs4OVw7UxPUe8NtfRAyY+RiaczhC+hDls+P/Cu0eIudi9IpsRyi5x5PbqBvLOV9wNw+5z4JRDRQpqmaL5MMMMBcGCGpPV2tqhl59F/M4mv5Tp+rtI9kDMVfZvOXkkx+Kg+RsluzHMNsmNz24eSw35LOyEcDUA3D2WlVMtH0QzPsS7ThLMVwSzm3YAGI/a1V9D+sSMcE9UvhUhaaDLwmXbb X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 527366ed-cb97-47cf-5c62-08da7f86710f X-MS-Exchange-CrossTenant-AuthSource: DU0PR04MB9417.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Aug 2022 12:54:22.8335 (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: nnWSAwdOvwQdonEPOqX9D0GluO5H96Mq0MkIdQw74aIo4YBV17lOoXkJz3hWy23T2UK7yHGchBKkMGQP9EfxnQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB7PR04MB4060 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Peng Fan The current driver only support one clock, however LPI2C requires two clocks: PER and IPG. To make sure old dts could work with newer kernel, use bulk clk API. Signed-off-by: Peng Fan --- drivers/i2c/busses/i2c-imx-lpi2c.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/i2c/busses/i2c-imx-lpi2c.c b/drivers/i2c/busses/i2c-imx-lpi2c.c index b51ab3cad2b1..159c2dc792b1 100644 --- a/drivers/i2c/busses/i2c-imx-lpi2c.c +++ b/drivers/i2c/busses/i2c-imx-lpi2c.c @@ -94,7 +94,8 @@ enum lpi2c_imx_pincfg { struct lpi2c_imx_struct { struct i2c_adapter adapter; - struct clk *clk; + int num_clks; + struct clk_bulk_data *clks; void __iomem *base; __u8 *rx_buf; __u8 *tx_buf; @@ -207,7 +208,7 @@ static int lpi2c_imx_config(struct lpi2c_imx_struct *lpi2c_imx) lpi2c_imx_set_mode(lpi2c_imx); - clk_rate = clk_get_rate(lpi2c_imx->clk); + clk_rate = clk_get_rate(lpi2c_imx->clks[0].clk); if (lpi2c_imx->mode == HS || lpi2c_imx->mode == ULTRA_FAST) filt = 0; else @@ -561,11 +562,12 @@ static int lpi2c_imx_probe(struct platform_device *pdev) strscpy(lpi2c_imx->adapter.name, pdev->name, sizeof(lpi2c_imx->adapter.name)); - lpi2c_imx->clk = devm_clk_get(&pdev->dev, NULL); - if (IS_ERR(lpi2c_imx->clk)) { - dev_err(&pdev->dev, "can't get I2C peripheral clock\n"); - return PTR_ERR(lpi2c_imx->clk); + ret = devm_clk_bulk_get_all(&pdev->dev, &lpi2c_imx->clks); + if (ret < 0) { + dev_err(&pdev->dev, "can't get I2C peripheral clock, ret=%d\n", ret); + return ret; } + lpi2c_imx->num_clks = ret; ret = of_property_read_u32(pdev->dev.of_node, "clock-frequency", &lpi2c_imx->bitrate); @@ -582,11 +584,9 @@ static int lpi2c_imx_probe(struct platform_device *pdev) i2c_set_adapdata(&lpi2c_imx->adapter, lpi2c_imx); platform_set_drvdata(pdev, lpi2c_imx); - ret = clk_prepare_enable(lpi2c_imx->clk); - if (ret) { - dev_err(&pdev->dev, "clk enable failed %d\n", ret); + ret = clk_bulk_prepare_enable(lpi2c_imx->num_clks, lpi2c_imx->clks); + if (ret) return ret; - } pm_runtime_set_autosuspend_delay(&pdev->dev, I2C_PM_TIMEOUT); pm_runtime_use_autosuspend(&pdev->dev); @@ -633,7 +633,7 @@ static int __maybe_unused lpi2c_runtime_suspend(struct device *dev) { struct lpi2c_imx_struct *lpi2c_imx = dev_get_drvdata(dev); - clk_disable_unprepare(lpi2c_imx->clk); + clk_bulk_disable(lpi2c_imx->num_clks, lpi2c_imx->clks); pinctrl_pm_select_sleep_state(dev); return 0; @@ -645,7 +645,7 @@ static int __maybe_unused lpi2c_runtime_resume(struct device *dev) int ret; pinctrl_pm_select_default_state(dev); - ret = clk_prepare_enable(lpi2c_imx->clk); + ret = clk_bulk_prepare_enable(lpi2c_imx->num_clks, lpi2c_imx->clks); if (ret) { dev_err(dev, "failed to enable I2C clock, ret=%d\n", ret); return ret;