Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp8521523rwr; Thu, 11 May 2023 02:24:19 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7GVm2IfsusFwcKRLLM7bXGfs/QS/aldlIWJOb6/mVYZelNcVt4Ugpkv7ATrhu+1sy2o7CL X-Received: by 2002:a05:6a20:54a2:b0:100:8592:9a7f with SMTP id i34-20020a056a2054a200b0010085929a7fmr18013435pzk.45.1683797059196; Thu, 11 May 2023 02:24:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683797059; cv=none; d=google.com; s=arc-20160816; b=mEKyeRmHpFNRNJOqAWm5yw4I3L1B6t4bQSQ77x0ao0XgPWKUzNt7b9E49hHvnTp+nQ JEXiGHuOgeMPhVH8L1yAhE4lNbdpFOEwviB+K8JbV4+3HpxcRwm0qqwMznhTEj5JTgew vkURtTeZtJu+pLKcyDAbXN2y2I1CTYA3+Z6SQL5zmTeS8aFklxPJhChupP1Y59Dy2gSK NtPOoUSi4iAfTq31BmbhopwzRYdNqVvUD12UevHaUrcNB7zZl3t7CFw9G6ofk5VBN8hN DAid8GjRCLvnVbjHKo+xa82leULYh4+Dhrqr/sBsRxilD3HkmTAWv5lyNItqOBkOxDR9 jGYQ== 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=HOhxbZpxlI22+IUaoCYhbDCwUnnzhiZ08dRm2VjATlG52tc0VjMNDSfel8fVx5dha8 1jzqewF3FQsR3RG+UwKCWXfqYpNOR/Stg7m0fW59njbOcomt0gpfGI3OE1K7VJnQGIDv 8leoAbcwoWuPrB2n/1sxQ45xmrQeO8aOG4QGplBLRWm7bH06GLTzKWqx+9AT7omfGVpi yb7eeYulYepTMpI+Xc9hhGJHbF/BAkDXKxoJiE+hZuW+fCdE2f4cuDuXpLdOEQURl6ut Rfwge7/O1Dqi0p3oijMvpSCCc0LlyUN525HvuSyi0STaYkV1oXAwbiAzqvVraHkAdH3C G9AA== 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 s30-20020a63925e000000b005303a26dbfbsi6149242pgn.728.2023.05.11.02.24.05; Thu, 11 May 2023 02:24:19 -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 S237327AbjEKJQL (ORCPT + 99 others); Thu, 11 May 2023 05:16:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40114 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237106AbjEKJQA (ORCPT ); Thu, 11 May 2023 05:16:00 -0400 Received: from ex01.ufhost.com (ex01.ufhost.com [61.152.239.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 617A57DB1; Thu, 11 May 2023 02:15:59 -0700 (PDT) Received: from EXMBX165.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX165", Issuer "EXMBX165" (not verified)) by ex01.ufhost.com (Postfix) with ESMTP id 21E8E24E272; Thu, 11 May 2023 17:15:53 +0800 (CST) Received: from EXMBX168.cuchost.com (172.16.6.78) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Thu, 11 May 2023 17:15:53 +0800 Received: from SD-Server.starfivetech.com (113.72.146.187) by EXMBX168.cuchost.com (172.16.6.78) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Thu, 11 May 2023 17:15:52 +0800 From: Walker Chen To: Mark Brown , Liam Girdwood , Claudiu Beznea , Jaroslav Kysela , Takashi Iwai , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Emil Renner Berthing , Walker Chen CC: , , , Subject: [PATCH v4 3/3] riscv: dts: starfive: add the node and pins configuration for tdm Date: Thu, 11 May 2023 17:15:49 +0800 Message-ID: <20230511091549.28003-4-walker.chen@starfivetech.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20230511091549.28003-1-walker.chen@starfivetech.com> References: <20230511091549.28003-1-walker.chen@starfivetech.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [113.72.146.187] X-ClientProxiedBy: EXCAS062.cuchost.com (172.16.6.22) 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