Received: by 2002:a05:6359:6284:b0:131:369:b2a3 with SMTP id se4csp5075889rwb; Tue, 8 Aug 2023 20:28:08 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGfdoUgZLpUvwlKjmDNzgWPC5g6R/zFbanTrR5K+DHJZgRhCEY7YPXIkU92ZPDA4D9Oq2dY X-Received: by 2002:aa7:d912:0:b0:522:1e2f:99db with SMTP id a18-20020aa7d912000000b005221e2f99dbmr1516512edr.5.1691551688219; Tue, 08 Aug 2023 20:28:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691551688; cv=none; d=google.com; s=arc-20160816; b=WSpQIpWwzrntt4M9SBGD3uyNr8eoya0aZQQpKbOIKkq5WuN5YPcM5ZhapeCjVYwWt9 lS2ld82fpQ/pQPm/VFLbTTLV5C9LgJCvYSfhU6NPQ5UiSUtzoZmv3105LxRlOE1elaWx TsHxNZzLgPVbaRahUl43a+kf9O+njX502+WPLu83D26UxQGJ+6G4FS/vCLJp9z7dEAym cjVEKQIodgsOCz7ZuzJnswIMKIkwCftpyilYTibMishECJCKPV3HZ123oMMWtALLGB2A lBzDglODTOB627FQoy6LAD4Z8xVkgzOMaIzjQsfv0qEEiCwT12hs+Ii2ys/+ztzxU51F VQRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=m+GS6zTHJC3nsDdt+poHvAax5dJeabgv8Tfe+rFn5os=; fh=HNft1qjYGTtm4ut+iSAbeLjVpAUBlSvCgiLgW/z78nw=; b=V9mTjXz65kqI3Zms5n7uRwa+mIC2gFXsEKwQ3iY4VSbzOpzb2wjNdUChoeowvQjRmE LC1axWCD6yFGc2u30gq6wzKfYsS8DkS3/9rLW9/Dmzi1GkiWwDT+1N3Yh2kccGHpRLD/ fcNs/hS3pjYXiINFp8VxihzWcoKxvDQcYgtNjjZ6J56tQQsmnig3A9gkL4aKnJop2uU9 f462v7B+2A/m5gBoymM5Qn85qQkgD2coJpZtmpCD8PzAJ2yvKt0FxP/VGV9TmhJxaSnF qu+vHQnUlTqLnU0WNdcehhelEuJXg9EaPav6Eqh+xS/Tmgldhbxq6ui4OWz9rKNX+jgD VK5w== 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 l19-20020aa7c313000000b005233887f44esi3702461edq.381.2023.08.08.20.27.44; Tue, 08 Aug 2023 20:28:08 -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 S230335AbjHIBj1 convert rfc822-to-8bit (ORCPT + 99 others); Tue, 8 Aug 2023 21:39:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40460 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229685AbjHIBjZ (ORCPT ); Tue, 8 Aug 2023 21:39:25 -0400 Received: from ex01.ufhost.com (ex01.ufhost.com [61.152.239.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6D0471982; Tue, 8 Aug 2023 18:39:22 -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 8134724E293; Wed, 9 Aug 2023 09:39:20 +0800 (CST) Received: from EXMBX068.cuchost.com (172.16.6.68) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Wed, 9 Aug 2023 09:39:20 +0800 Received: from williamqiu-virtual-machine.starfivetech.com (171.223.208.138) by EXMBX068.cuchost.com (172.16.6.68) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Wed, 9 Aug 2023 09:39:19 +0800 From: William Qiu To: , , CC: Emil Renner Berthing , Rob Herring , Krzysztof Kozlowski , Conor Dooley , William Qiu Subject: [PATCH v1 2/2] riscv: dts: starfive: Add mmc nodes on VisionFive 2 board Date: Wed, 9 Aug 2023 09:39:17 +0800 Message-ID: <20230809013917.81674-3-william.qiu@starfivetech.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230809013917.81674-1-william.qiu@starfivetech.com> References: <20230809013917.81674-1-william.qiu@starfivetech.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [171.223.208.138] X-ClientProxiedBy: EXCAS066.cuchost.com (172.16.6.26) To EXMBX068.cuchost.com (172.16.6.68) X-YovoleRuleAgent: yovoleflag Content-Transfer-Encoding: 8BIT X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS 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 mmc nodes for the StarFive JH7110 SoC. Set mmc0 node to emmc and set mmc1 node to sd. Signed-off-by: William Qiu Reviewed-by: Hal Feng --- .../jh7110-starfive-visionfive-2.dtsi | 96 +++++++++++++++++++ arch/riscv/boot/dts/starfive/jh7110.dtsi | 32 +++++++ 2 files changed, 128 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 d67e26b9c791..d79f94432b27 100644 --- a/arch/riscv/boot/dts/starfive/jh7110-starfive-visionfive-2.dtsi +++ b/arch/riscv/boot/dts/starfive/jh7110-starfive-visionfive-2.dtsi @@ -17,6 +17,8 @@ aliases { i2c2 = &i2c2; i2c5 = &i2c5; i2c6 = &i2c6; + mmc0 = &mmc0; + mmc1 = &mmc1; serial0 = &uart0; }; @@ -201,6 +203,35 @@ &i2c6 { status = "okay"; }; +&mmc0 { + max-frequency = <100000000>; + bus-width = <8>; + cap-mmc-highspeed; + mmc-ddr-1_8v; + mmc-hs200-1_8v; + non-removable; + cap-mmc-hw-reset; + post-power-on-delay-ms = <200>; + pinctrl-names = "default"; + pinctrl-0 = <&mmc0_pins>; + vmmc-supply = <&vcc_3v3>; + vqmmc-supply = <&emmc_vdd>; + status = "okay"; +}; + +&mmc1 { + max-frequency = <100000000>; + bus-width = <4>; + no-sdio; + no-mmc; + broken-cd; + cap-sd-highspeed; + post-power-on-delay-ms = <200>; + pinctrl-names = "default"; + pinctrl-0 = <&mmc1_pins>; + status = "okay"; +}; + &qspi { #address-cells = <1>; #size-cells = <0>; @@ -306,6 +337,71 @@ GPOEN_SYS_I2C6_DATA, }; }; + mmc0_pins: mmc0-0 { + rst-pins { + pinmux = ; + bias-pull-up; + drive-strength = <12>; + input-disable; + input-schmitt-disable; + slew-rate = <0>; + }; + + mmc-pins { + pinmux = , + , + , + , + , + , + , + , + , + ; + bias-pull-up; + drive-strength = <12>; + input-enable; + }; + }; + + mmc1_pins: mmc1-0 { + clk-pins { + pinmux = ; + bias-pull-up; + drive-strength = <12>; + input-disable; + input-schmitt-disable; + slew-rate = <0>; + }; + + mmc-pins { + pinmux = , + , + , + , + ; + bias-pull-up; + drive-strength = <12>; + input-enable; + input-schmitt-enable; + slew-rate = <0>; + }; + }; + spi0_pins: spi0-0 { mosi-pins { pinmux = ; }; + mmc0: mmc@16010000 { + compatible = "starfive,jh7110-mmc"; + reg = <0x0 0x16010000 0x0 0x10000>; + clocks = <&syscrg JH7110_SYSCLK_SDIO0_AHB>, + <&syscrg JH7110_SYSCLK_SDIO0_SDCARD>; + clock-names = "biu","ciu"; + resets = <&syscrg JH7110_SYSRST_SDIO0_AHB>; + reset-names = "reset"; + interrupts = <74>; + fifo-depth = <32>; + fifo-watermark-aligned; + data-addr = <0>; + starfive,sysreg = <&sys_syscon 0x14 0x1a 0x7c000000>; + status = "disabled"; + }; + + mmc1: mmc@16020000 { + compatible = "starfive,jh7110-mmc"; + reg = <0x0 0x16020000 0x0 0x10000>; + clocks = <&syscrg JH7110_SYSCLK_SDIO1_AHB>, + <&syscrg JH7110_SYSCLK_SDIO1_SDCARD>; + clock-names = "biu","ciu"; + resets = <&syscrg JH7110_SYSRST_SDIO1_AHB>; + reset-names = "reset"; + interrupts = <75>; + fifo-depth = <32>; + fifo-watermark-aligned; + data-addr = <0>; + starfive,sysreg = <&sys_syscon 0x9c 0x1 0x3e>; + status = "disabled"; + }; + gmac0: ethernet@16030000 { compatible = "starfive,jh7110-dwmac", "snps,dwmac-5.20"; reg = <0x0 0x16030000 0x0 0x10000>; -- 2.34.1