Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2584242rwd; Fri, 26 May 2023 08:23:52 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7zSb65TKLiEU20vYU1+f/p4rcw8VeUnpiGaY8F2LQmJq0dl2SJoLOHRNCimQSFSTAqP/j7 X-Received: by 2002:a05:6a21:32a7:b0:10b:8024:d253 with SMTP id yt39-20020a056a2132a700b0010b8024d253mr3131134pzb.26.1685114631883; Fri, 26 May 2023 08:23:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685114631; cv=none; d=google.com; s=arc-20160816; b=pAkIDFkBTbasNIERck/izbK6u56KBx488cRYE4VwewrfXQY8eA/eAZKR2inlDIIBce x+d3wmkxlKwhwFD9k58sQvf9/Wbo3irj76ndPk7NfS4pjVwuuTxfBNHdqICCRdHBBApb C71BgcIIPffIrlrAEUpVc61/vgNgTwXo8+Q/C5Z/9HupLG915hKcFVIPP4P/ECiDb3yO 7KxzPo0f+ElDZzSezlmqQUBRyY/JFA3hlbx9BJBGt+BVYZT9df0DggcZOO9lJsetIhPM uSTgEbO5vcHawH/YRUrIFG7n2/W/h3p4NRnr5dduQuk3n4fOgJ5fj2o/8q4suaSD8JlH SWKA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from; bh=OvUg2fqbFut/joLqdm8dWy4qeO2OFcE5AybJ4ImuHyo=; b=QVJgthhnIZRm7uwQj97r/MbanymRriXggD3WsZD8x3ltySrqVD6yvAzA6RhCUzDhGM nIQsprvl5wyyeWIG4D37vdJvoXKMV37L4SCoET23PTif4ofMrkiVjg7R6GsbV/e1bE0D JflrUCKa8JVzHJNMzrGwbAJlmIUBNR1yJMtysTXQJigvljSAJN2+a7rO7ghcUz+LS2os EimqwTI0jBy3/yKWNVaC6syH16BfVfPFK0u+mRMoAeV/Mw3rNssur+CDTpg14eWlEM3t C02bVFoYXlxrrNElTO01+kmbGJr6WazRpHKDir8dvcpCv2oIhWk6OaDpBxCJb4WgfCYl 6XlA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x70-20020a638649000000b0053ef17140dfsi4045174pgd.861.2023.05.26.08.23.37; Fri, 26 May 2023 08:23:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231604AbjEZOyV (ORCPT + 99 others); Fri, 26 May 2023 10:54:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45856 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237366AbjEZOyR (ORCPT ); Fri, 26 May 2023 10:54:17 -0400 Received: from ex01.ufhost.com (ex01.ufhost.com [61.152.239.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D5F7F1A2; Fri, 26 May 2023 07:54:13 -0700 (PDT) Received: from EXMBX166.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX166", Issuer "EXMBX166" (not verified)) by ex01.ufhost.com (Postfix) with ESMTP id A8FD924E203; Fri, 26 May 2023 22:54:06 +0800 (CST) Received: from EXMBX168.cuchost.com (172.16.6.78) by EXMBX166.cuchost.com (172.16.6.76) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Fri, 26 May 2023 22:54:06 +0800 Received: from SD-Server.starfivetech.com (183.27.98.143) by EXMBX168.cuchost.com (172.16.6.78) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Fri, 26 May 2023 22:54:05 +0800 From: Walker Chen To: Mark Brown , Liam Girdwood , Claudiu Beznea , Jaroslav Kysela , Takashi Iwai , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Emil Renner Berthing , Hal Feng , Walker Chen CC: , , , Subject: [PATCH v5 3/3] riscv: dts: starfive: add the node and pins configuration for tdm Date: Fri, 26 May 2023 22:54:02 +0800 Message-ID: <20230526145402.450-4-walker.chen@starfivetech.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20230526145402.450-1-walker.chen@starfivetech.com> References: <20230526145402.450-1-walker.chen@starfivetech.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [183.27.98.143] X-ClientProxiedBy: EXCAS066.cuchost.com (172.16.6.26) To EXMBX168.cuchost.com (172.16.6.78) X-YovoleRuleAgent: yovoleflag X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add the tdm controller node and pins configuration of tdm for the StarFive JH7110 SoC. Signed-off-by: Walker Chen --- .../jh7110-starfive-visionfive-2.dtsi | 40 +++++++++++++++++++ arch/riscv/boot/dts/starfive/jh7110.dtsi | 21 ++++++++++ 2 files changed, 61 insertions(+) diff --git a/arch/riscv/boot/dts/starfive/jh7110-starfive-visionfive-2.dtsi b/arch/riscv/boot/dts/starfive/jh7110-starfive-visionfive-2.dtsi index 1155b97b593d..19b5954ee72d 100644 --- a/arch/riscv/boot/dts/starfive/jh7110-starfive-visionfive-2.dtsi +++ b/arch/riscv/boot/dts/starfive/jh7110-starfive-visionfive-2.dtsi @@ -214,6 +214,40 @@ slew-rate = <0>; }; }; + + tdm0_pins: tdm0-pins { + tdm0-pins-tx { + pinmux = ; + bias-pull-up; + drive-strength = <2>; + input-disable; + input-schmitt-disable; + slew-rate = <0>; + }; + + tdm0-pins-rx { + pinmux = ; + input-enable; + }; + + tdm0-pins-sync { + pinmux = ; + input-enable; + }; + + tdm0-pins-pcmclk { + pinmux = ; + input-enable; + }; + }; }; &uart0 { @@ -221,3 +255,9 @@ pinctrl-0 = <&uart0_pins>; status = "okay"; }; + +&tdm { + pinctrl-names = "default"; + pinctrl-0 = <&tdm0_pins>; + status = "okay"; +}; diff --git a/arch/riscv/boot/dts/starfive/jh7110.dtsi b/arch/riscv/boot/dts/starfive/jh7110.dtsi index 866313570a7e..cfda6fb0d91b 100644 --- a/arch/riscv/boot/dts/starfive/jh7110.dtsi +++ b/arch/riscv/boot/dts/starfive/jh7110.dtsi @@ -366,6 +366,27 @@ status = "disabled"; }; + tdm: tdm@10090000 { + compatible = "starfive,jh7110-tdm"; + reg = <0x0 0x10090000 0x0 0x1000>; + clocks = <&syscrg JH7110_SYSCLK_TDM_AHB>, + <&syscrg JH7110_SYSCLK_TDM_APB>, + <&syscrg JH7110_SYSCLK_TDM_INTERNAL>, + <&syscrg JH7110_SYSCLK_TDM_TDM>, + <&syscrg JH7110_SYSCLK_MCLK_INNER>, + <&tdm_ext>; + clock-names = "tdm_ahb", "tdm_apb", + "tdm_internal", "tdm", + "mclk_inner", "tdm_ext"; + resets = <&syscrg JH7110_SYSRST_TDM_AHB>, + <&syscrg JH7110_SYSRST_TDM_APB>, + <&syscrg JH7110_SYSRST_TDM_CORE>; + dmas = <&dma 20>, <&dma 21>; + dma-names = "rx","tx"; + #sound-dai-cells = <0>; + status = "disabled"; + }; + stgcrg: clock-controller@10230000 { compatible = "starfive,jh7110-stgcrg"; reg = <0x0 0x10230000 0x0 0x10000>; -- 2.17.1