From nobody Thu Sep 11 23:17:30 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 250E8C001DE for ; Tue, 8 Aug 2023 15:58:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231297AbjHHP6h (ORCPT ); Tue, 8 Aug 2023 11:58:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36640 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229504AbjHHP5L (ORCPT ); Tue, 8 Aug 2023 11:57:11 -0400 Received: from TWMBX02.aspeed.com (mail.aspeedtech.com [211.20.114.72]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A67635BB4; Tue, 8 Aug 2023 08:43:59 -0700 (PDT) Received: from TWMBX02.aspeed.com (192.168.0.24) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 8 Aug 2023 23:42:44 +0800 Received: from localhost.localdomain (192.168.10.10) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 8 Aug 2023 23:42:44 +0800 From: Dylan Hung To: , , , , , , , , , , , , CC: , Subject: [PATCH 1/3] ARM: dts: pinctrl-aspeed-g6: Add I3C1 and I3C2 control pins Date: Tue, 8 Aug 2023 23:42:39 +0800 Message-ID: <20230808154241.749641-2-dylan_hung@aspeedtech.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230808154241.749641-1-dylan_hung@aspeedtech.com> References: <20230808154241.749641-1-dylan_hung@aspeedtech.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: Fail (TWMBX02.aspeed.com: domain of dylan_hung@aspeedtech.com does not designate 192.168.10.10 as permitted sender) receiver=TWMBX02.aspeed.com; client-ip=192.168.10.10; helo=localhost.localdomain; Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Add pinctrl support for the I3C1 and I3C2 pins. Signed-off-by: Dylan Hung --- arch/arm/boot/dts/aspeed/aspeed-g6-pinctrl.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/arch/arm/boot/dts/aspeed/aspeed-g6-pinctrl.dtsi b/arch/arm/boo= t/dts/aspeed/aspeed-g6-pinctrl.dtsi index 7cd4f075e325..289668f051eb 100644 --- a/arch/arm/boot/dts/aspeed/aspeed-g6-pinctrl.dtsi +++ b/arch/arm/boot/dts/aspeed/aspeed-g6-pinctrl.dtsi @@ -297,6 +297,16 @@ pinctrl_i2c9_default: i2c9_default { groups =3D "I2C9"; }; =20 + pinctrl_i3c1_default: i3c1_default { + function =3D "I3C1"; + groups =3D "I3C1"; + }; + + pinctrl_i3c2_default: i3c2_default { + function =3D "I3C2"; + groups =3D "I3C2"; + }; + pinctrl_i3c3_default: i3c3_default { function =3D "I3C3"; groups =3D "I3C3"; --=20 2.25.1 From nobody Thu Sep 11 23:17:30 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 3E693C001DB for ; Tue, 8 Aug 2023 16:00:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231531AbjHHQAQ (ORCPT ); Tue, 8 Aug 2023 12:00:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60974 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231271AbjHHP6g (ORCPT ); Tue, 8 Aug 2023 11:58:36 -0400 Received: from TWMBX02.aspeed.com (mail.aspeedtech.com [211.20.114.72]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8019E2709; Tue, 8 Aug 2023 08:44:19 -0700 (PDT) Received: from TWMBX02.aspeed.com (192.168.0.24) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 8 Aug 2023 23:42:45 +0800 Received: from localhost.localdomain (192.168.10.10) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 8 Aug 2023 23:42:45 +0800 From: Dylan Hung To: , , , , , , , , , , , , CC: , Subject: [PATCH 2/3] dt-bindings: i3c: ast2600: Add resets and reset-names Date: Tue, 8 Aug 2023 23:42:40 +0800 Message-ID: <20230808154241.749641-3-dylan_hung@aspeedtech.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230808154241.749641-1-dylan_hung@aspeedtech.com> References: <20230808154241.749641-1-dylan_hung@aspeedtech.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: Fail (TWMBX02.aspeed.com: domain of dylan_hung@aspeedtech.com does not designate 192.168.10.10 as permitted sender) receiver=TWMBX02.aspeed.com; client-ip=192.168.10.10; helo=localhost.localdomain; Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Add two reset lines to the AST2600 I3C controller: - core_rst: the reset line of the controller itself - global_rst: the reset line of the I3C global register block. Since all six I3C controllers in AST2600 share this global register block, the driver needs to handle this carefully. Generally, this reset line should only need to be de-asserted. Signed-off-by: Dylan Hung --- .../devicetree/bindings/i3c/aspeed,ast2600-i3c.yaml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/i3c/aspeed,ast2600-i3c.yaml = b/Documentation/devicetree/bindings/i3c/aspeed,ast2600-i3c.yaml index fcc3dbff9c9a..3166d6f3a39c 100644 --- a/Documentation/devicetree/bindings/i3c/aspeed,ast2600-i3c.yaml +++ b/Documentation/devicetree/bindings/i3c/aspeed,ast2600-i3c.yaml @@ -23,7 +23,12 @@ properties: maxItems: 1 =20 resets: - maxItems: 1 + maxItems: 2 + + reset-names: + items: + - const: core_rst + - const: global_rst =20 interrupts: maxItems: 1 @@ -48,6 +53,8 @@ required: - compatible - reg - clocks + - resets + - reset-names - interrupts - aspeed,global-regs =20 @@ -63,7 +70,8 @@ examples: #address-cells =3D <3>; #size-cells =3D <0>; clocks =3D <&syscon 0>; - resets =3D <&syscon 0>; + resets =3D <&syscon 40>, <&syscon 39>; + reset-names =3D "core_rst", "global_rst"; aspeed,global-regs =3D <&i3c_global 0>; pinctrl-names =3D "default"; pinctrl-0 =3D <&pinctrl_i3c1_default>; --=20 2.25.1 From nobody Thu Sep 11 23:17:30 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 186FBC001DB for ; Tue, 8 Aug 2023 16:01:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231596AbjHHQB2 (ORCPT ); Tue, 8 Aug 2023 12:01:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34366 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231472AbjHHP7f (ORCPT ); Tue, 8 Aug 2023 11:59:35 -0400 Received: from TWMBX03.aspeed.com (mail.aspeedtech.com [211.20.114.72]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0007661B1; Tue, 8 Aug 2023 08:44:32 -0700 (PDT) Received: from TWMBX02.aspeed.com (192.168.0.24) by TWMBX03.aspeed.com (192.168.0.62) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 8 Aug 2023 23:42:45 +0800 Received: from localhost.localdomain (192.168.10.10) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 8 Aug 2023 23:42:45 +0800 From: Dylan Hung To: , , , , , , , , , , , , CC: , Subject: [PATCH 3/3] i3c: ast2600: Add reset deassertion for global registers Date: Tue, 8 Aug 2023 23:42:41 +0800 Message-ID: <20230808154241.749641-4-dylan_hung@aspeedtech.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230808154241.749641-1-dylan_hung@aspeedtech.com> References: <20230808154241.749641-1-dylan_hung@aspeedtech.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Add missing reset deassertion of the I3C global control registers. Signed-off-by: Dylan Hung --- drivers/i3c/master/ast2600-i3c-master.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/drivers/i3c/master/ast2600-i3c-master.c b/drivers/i3c/master/a= st2600-i3c-master.c index 09ed19d489e9..5d9d060134e0 100644 --- a/drivers/i3c/master/ast2600-i3c-master.c +++ b/drivers/i3c/master/ast2600-i3c-master.c @@ -11,6 +11,7 @@ #include #include #include +#include =20 #include "dw-i3c-master.h" =20 @@ -128,6 +129,7 @@ static int ast2600_i3c_probe(struct platform_device *pd= ev) struct device_node *np =3D pdev->dev.of_node; struct of_phandle_args gspec; struct ast2600_i3c *i3c; + struct reset_control *rst; int rc; =20 i3c =3D devm_kzalloc(&pdev->dev, sizeof(*i3c), GFP_KERNEL); @@ -156,6 +158,13 @@ static int ast2600_i3c_probe(struct platform_device *p= dev) dev_err(&pdev->dev, "invalid sda-pullup value %d\n", i3c->sda_pullup); =20 + rst =3D devm_reset_control_get_shared(&pdev->dev, "global_rst"); + if (IS_ERR(rst)) { + dev_err(&pdev->dev, "missing of invalid reset entry"); + return PTR_ERR(rst); + } + reset_control_deassert(rst); + i3c->dw.platform_ops =3D &ast2600_i3c_ops; i3c->dw.ibi_capable =3D true; return dw_i3c_common_probe(&i3c->dw, pdev); --=20 2.25.1