From patchwork Fri Feb 17 11:58:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 2719 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pl1-f200.google.com (mail-pl1-f200.google.com [209.85.214.200]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 5E7EE3F07F for ; Fri, 17 Feb 2023 12:59:08 +0100 (CET) Received: by mail-pl1-f200.google.com with SMTP id h18-20020a170902f71200b0019af43e2fa6sf263457plo.4 for ; Fri, 17 Feb 2023 03:59:08 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1676635147; cv=pass; d=google.com; s=arc-20160816; b=Yhb5/9r+TZrLcnnoxkQ1U7NnlbFH5aAxFtFbte0+FtoHCgO/jmfCVILX97O4gmoOWP crHPGUg04erw9sO9fxs8veLVSCFfgdjY3Ntn/eC68dnEG5l6gG68euS6o+Sh1UTrgM5s N18t84Deylny6NGZjoQ1o0KtyCgjFQ0fPsDNQx4DDbMoHd/XUJoYGhWAVHjjreM2aNBF i1ZSmhNLYmnYcLQkNIbm8hs2pXBTJxIduSbDpn3ES1mQSNwAuFUUl/Biz/5e23QiCP5O BpmuQysUfMvxr7QpIAX9S31GYTBRNrysQ0vbP2406FxA3c/XBlUr43oOWwEQ24hZQjrS Nz3A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=4EiEUXNK8OsK7LWmXbo4vh6tw1NY6GcsLsSS50VYns0=; b=NAXw5fxFgQNNECgROVIecjp0ngqVSILtk4iC0tUo+B6uoXoZI+TPSZ8yi9SMaCPvB5 vsxVfHRJDbsRQOu5Eq8PAn8BHHlhBezA0b05P92LMOTGVO7XN48F77JWyVeRbDOXtSEV uJGs8CK+yFb/Thpka9WcPbQEZAMUIBntk89r9jV0qsi0tyHKvR7yXCvVuQ/D9m9M8PAb os4/0ERtI21lohgKGrdoGm2ZkyfvS1lRcaveZz1I6lrxh0nBqNq/dMmAVgkGNCzCCXfH A4cmkLNosrV8QNi+pwU1JgcXTvlopb088PoPsBBBlRZldFQG43hU5PAfjft8aIxF2V6n JedQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=lJELhyNe; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=4EiEUXNK8OsK7LWmXbo4vh6tw1NY6GcsLsSS50VYns0=; b=b7rfyC43d/3QjEiwA/fMtxVl6j4DE53JGKa1cfJ70xsEAsRcwswPpGU5t29G7a+Jpg Sh2P/FndJXyMh0871nq+/LqbM74hHUjaCL9ujfdzh27HXX9AJS5f0dJ5FxBTMeRDtNCU TmZqzHRmOFw0NsVgOnu2wGe10dplupDQdepBU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=list-unsubscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=4EiEUXNK8OsK7LWmXbo4vh6tw1NY6GcsLsSS50VYns0=; b=boAPVB01AAzH+/xIz8AqlscILHcYpApK0av4QiEjJ/sIGywIlkwYLJTMU0oDLzARQ9 15P77bFHDidocoPtN7PcYMGKqXxxnAPtGPdKkbSz7UQ0ujQuy90ZofKj1odMZGxhfubf vTpmMlCzK4o9xcDi0M2Du+p2c2XkfSh0NEbXUaEwophZoV9CC+xxTJN3nc3LnJE00iCr XAMR9IOaaUpTLZeEO6io8stgu2+bvDvSGRgzHfOPa/2cdx1uecYY97ePwenuJRFe1RVu Q65vPZRKKCM+JYCkM5uCHBZILV5zqY2C1H4mC2jQAvy+4rTj81lLhUkN0qUGQt0rbNoe 0OAw== X-Gm-Message-State: AO0yUKVydDIPIQgYlqNW0gB9Y6j0GSoWrb1AEoyYWAjW8g8c4rj+RyHF 5zKSEf74cnAjCk32mpUVSM9B8E7E X-Google-Smtp-Source: AK7set8jW7dzxAhwaz/2ckxrr3dznpYaj4la7OIaPVN4JQutnG/u7QNl6Axbt/icUI7v0XVDQr0baQ== X-Received: by 2002:a62:aa0d:0:b0:5a8:b093:ff67 with SMTP id e13-20020a62aa0d000000b005a8b093ff67mr153660pff.4.1676635147153; Fri, 17 Feb 2023 03:59:07 -0800 (PST) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a17:902:c103:b0:196:751e:4f6e with SMTP id 3-20020a170902c10300b00196751e4f6els1576077pli.10.-pod-prod-gmail; Fri, 17 Feb 2023 03:59:06 -0800 (PST) X-Received: by 2002:a17:902:f682:b0:199:2ee:6238 with SMTP id l2-20020a170902f68200b0019902ee6238mr795890plg.16.1676635146157; Fri, 17 Feb 2023 03:59:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676635146; cv=none; d=google.com; s=arc-20160816; b=vVpe8pQz3I0+XDmY9Q059oMTGVQimMGyoxjEjzSq/u+9nVes2I2D7400PGOBySEQVg kTvbiWT6u5JVjWnekpfCAtvyPDnPE/lF2/LRZqb4epLgzOo4DQZFMveR+HYx9cFtLXNI 8RatovbT1RVY/7US9XlTDdhSLijy3VWhrRdxuplZZs5CxWRAlk/GwQTraW2EyWBup5yN ZjOuQggXgQMZgQZG19DgUGeUMeEZ7C8yCWEW2ozQ8psr9AATHNj8L71bxhtbnk9Vg9qB jMpM8JAwIy7HjtSHdJhPFa8UjGLgGdKt8P79Ijt3iPcPhpMkGx9Exm0aN0CY8GUbfm+g BA1g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=j+JPnqZKvocXg8/fZ/5MxRnXgwp0mUaDPJt4v9EX4JQ=; b=E0xxvdTXoovH57mjNf6GxqknZDJ3kjyBtVZXyC/K6a7SVuo1izeMqCEc9z3vCpGCQt zc7ilBzlKW8W44Mh2E7Qrkq3oASsAs+9V//TEB6xAGUnV8/7lK8EkhTPlzEkZSeS9TO8 EAfcyFd5jHaMOlh8a9NPhPt309KFXa1b5ywvrdK0ku7iqxfCVz+Lm/8M6EZU/aMN37oc 2+PWRwxmfOiXZwaU82BPtkYtSOrsDVnKykHuSaViTkHTf8Gzr97WQhECexSZyM+f61lz OX8wROz3EEjySiBVCTmPV45D4zPKCqGSIewJ4p4fx5mm2fX6JT5RmpjtdV9/FJWuxN6+ 54WA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=lJELhyNe; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id b9-20020a170902d40900b0019a826eea48sor2002830ple.204.2023.02.17.03.59.06 for (Google Transport Security); Fri, 17 Feb 2023 03:59:06 -0800 (PST) Received-SPF: pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Received: by 2002:a17:902:f20a:b0:19a:743e:b152 with SMTP id m10-20020a170902f20a00b0019a743eb152mr1104204plc.63.1676635145779; Fri, 17 Feb 2023 03:59:05 -0800 (PST) Received: from localhost.localdomain ([183.83.141.79]) by smtp.gmail.com with ESMTPSA id ik15-20020a170902ab0f00b001991d6c6c64sm2989418plb.185.2023.02.17.03.59.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Feb 2023 03:59:05 -0800 (PST) From: Jagan Teki To: Kever Yang , Philipp Tomsich , Simon Glass Cc: u-boot@lists.denx.de, linux-amarula@amarulasolutions.com, Jagan Teki , FUKAUMI Naoki , Manoj Sai Subject: [PATCH v4 04/12] arm64: dts: rockchip: rk3566: Add Radxa Compute Module 3 IO Date: Fri, 17 Feb 2023 17:28:37 +0530 Message-Id: <20230217115845.75303-5-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230217115845.75303-1-jagan@amarulasolutions.com> References: <20230217115845.75303-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: jagan@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=lJELhyNe; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Radxa Compute Module 3(CM3) IO board an application board from Radxa and is compatible with Raspberry Pi CM4 IO form factor. Specification: - 1x HDMI, - 2x MIPI DSI - 2x MIPI CSI2 - 1x eDP - 1x PCIe card - 2x SATA - 2x USB 2.0 Host - 1x USB 3.0 - 1x USB 2.0 OTG - Phone jack - microSD slot - 40-pin GPIO expansion header - 12V DC Radxa CM3 needs to mount on top of this IO board in order to create complete Radxa CM3 IO board platform. linux-next commit for the same, commit <8f19828844f2> ("arm64: dts: rockchip: Fix compatible for Radxa CM3") Add support for Radxa CM3 IO Board. Co-developed-by: FUKAUMI Naoki Signed-off-by: FUKAUMI Naoki Co-developed-by: Manoj Sai Signed-off-by: Manoj Sai Signed-off-by: Jagan Teki Reviewed-by: Kever Yang --- arch/arm/dts/Makefile | 1 + arch/arm/dts/rk3566-radxa-cm3-io.dts | 272 +++++++++++++++++++++++++++ 2 files changed, 273 insertions(+) create mode 100644 arch/arm/dts/rk3566-radxa-cm3-io.dts diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile index 9d647b9639..037ffc09b1 100644 --- a/arch/arm/dts/Makefile +++ b/arch/arm/dts/Makefile @@ -165,6 +165,7 @@ dtb-$(CONFIG_ROCKCHIP_RK3399) += \ rk3399pro-rock-pi-n10.dtb dtb-$(CONFIG_ROCKCHIP_RK3568) += \ + rk3566-radxa-cm3-io.dtb \ rk3568-evb.dtb dtb-$(CONFIG_ROCKCHIP_RV1108) += \ diff --git a/arch/arm/dts/rk3566-radxa-cm3-io.dts b/arch/arm/dts/rk3566-radxa-cm3-io.dts new file mode 100644 index 0000000000..d89d5263cb --- /dev/null +++ b/arch/arm/dts/rk3566-radxa-cm3-io.dts @@ -0,0 +1,272 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +/* + * Copyright (c) 2022 Radxa Limited + * Copyright (c) 2022 Amarula Solutions(India) + */ + +/dts-v1/; +#include +#include "rk3566.dtsi" +#include "rk3566-radxa-cm3.dtsi" + +/ { + model = "Radxa Compute Module 3(CM3) IO Board"; + compatible = "radxa,cm3-io", "radxa,cm3", "rockchip,rk3566"; + + aliases { + mmc1 = &sdmmc0; + }; + + chosen: chosen { + stdout-path = "serial2:1500000n8"; + }; + + gmac1_clkin: external-gmac1-clock { + compatible = "fixed-clock"; + clock-frequency = <125000000>; + clock-output-names = "gmac1_clkin"; + #clock-cells = <0>; + }; + + hdmi-con { + compatible = "hdmi-connector"; + type = "a"; + + port { + hdmi_con_in: endpoint { + remote-endpoint = <&hdmi_out_con>; + }; + }; + }; + + leds { + compatible = "gpio-leds"; + + led-1 { + gpios = <&gpio4 RK_PA4 GPIO_ACTIVE_LOW>; + color = ; + function = LED_FUNCTION_ACTIVITY; + linux,default-trigger = "heartbeat"; + pinctrl-names = "default"; + pinctrl-0 = <&pi_nled_activity>; + }; + }; + + vcc5v0_usb30: vcc5v0-usb30-regulator { + compatible = "regulator-fixed"; + regulator-name = "vcc5v0_usb30"; + enable-active-high; + gpio = <&gpio3 RK_PC2 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&vcc5v0_usb30_en_h>; + regulator-always-on; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + vin-supply = <&vcc_sys>; + }; + + vcca1v8_image: vcca1v8-image-regulator { + compatible = "regulator-fixed"; + regulator-name = "vcca1v8_image"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + vin-supply = <&vcc_1v8_p>; + }; + + vdda0v9_image: vdda0v9-image-regulator { + compatible = "regulator-fixed"; + regulator-name = "vcca0v9_image"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <900000>; + regulator-max-microvolt = <900000>; + vin-supply = <&vdda_0v9>; + }; +}; + +&combphy1 { + status = "okay"; +}; + +&gmac1 { + assigned-clocks = <&cru SCLK_GMAC1_RX_TX>, <&cru SCLK_GMAC1>; + assigned-clock-parents = <&cru SCLK_GMAC1_RGMII_SPEED>, <&gmac1_clkin>; + assigned-clock-rates = <0>, <125000000>; + clock_in_out = "input"; + phy-handle = <&rgmii_phy1>; + phy-mode = "rgmii"; + pinctrl-names = "default"; + pinctrl-0 = <&gmac1m0_miim + &gmac1m0_tx_bus2 + &gmac1m0_rx_bus2 + &gmac1m0_rgmii_clk + &gmac1m0_rgmii_bus + &gmac1m0_clkinout>; + snps,reset-gpio = <&gpio4 RK_PC2 GPIO_ACTIVE_LOW>; + snps,reset-active-low; + /* Reset time is 20ms, 100ms for rtl8211f */ + snps,reset-delays-us = <0 20000 100000>; + tx_delay = <0x46>; + rx_delay = <0x2e>; + status = "okay"; +}; + +&hdmi { + avdd-0v9-supply = <&vdda0v9_image>; + avdd-1v8-supply = <&vcca1v8_image>; + status = "okay"; +}; + +&hdmi_in { + hdmi_in_vp0: endpoint { + remote-endpoint = <&vp0_out_hdmi>; + }; +}; + +&hdmi_out { + hdmi_out_con: endpoint { + remote-endpoint = <&hdmi_con_in>; + }; +}; + +&hdmi_sound { + status = "okay"; +}; + +&mdio1 { + rgmii_phy1: ethernet-phy@0 { + compatible="ethernet-phy-ieee802.3-c22"; + reg= <0x0>; + }; +}; + +&pinctrl { + gmac1 { + gmac1m0_miim: gmac1m0-miim { + rockchip,pins = + /* gmac1_mdcm0 */ + <3 RK_PC4 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_mdiom0 */ + <3 RK_PC5 3 &pcfg_pull_none_drv_level_15>; + }; + + gmac1m0_rx_bus2: gmac1m0-rx-bus2 { + rockchip,pins = + /* gmac1_rxd0m0 */ + <3 RK_PB1 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_rxd1m0 */ + <3 RK_PB2 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_rxdvcrsm0 */ + <3 RK_PB3 3 &pcfg_pull_none_drv_level_15>; + }; + + gmac1m0_tx_bus2: gmac1m0-tx-bus2 { + rockchip,pins = + /* gmac1_txd0m0 */ + <3 RK_PB5 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_txd1m0 */ + <3 RK_PB6 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_txenm0 */ + <3 RK_PB7 3 &pcfg_pull_none_drv_level_15>; + }; + + gmac1m0_rgmii_clk: gmac1m0-rgmii-clk { + rockchip,pins = + /* gmac1_rxclkm0 */ + <3 RK_PA7 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_txclkm0 */ + <3 RK_PA6 3 &pcfg_pull_none_drv_level_15>; + }; + + gmac1m0_rgmii_bus: gmac1m0-rgmii-bus { + rockchip,pins = + /* gmac1_rxd2m0 */ + <3 RK_PA4 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_rxd3m0 */ + <3 RK_PA5 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_txd2m0 */ + <3 RK_PA2 3 &pcfg_pull_none_drv_level_15>, + /* gmac1_txd3m0 */ + <3 RK_PA3 3 &pcfg_pull_none_drv_level_15>; + }; + + gmac1m0_clkinout: gmac1m0-clkinout { + rockchip,pins = + /* gmac1_mclkinoutm0 */ + <3 RK_PC0 3 &pcfg_pull_none_drv_level_15>; + }; + }; + + leds { + pi_nled_activity: pi-nled-activity { + rockchip,pins = <4 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; + + sdcard { + sdmmc_pwren: sdmmc-pwren { + rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; + + usb { + vcc5v0_usb30_en_h: vcc5v0-host-en-h { + rockchip,pins = <3 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; +}; + +&sdmmc0 { + bus-width = <4>; + cap-mmc-highspeed; + cap-sd-highspeed; + disable-wp; + vqmmc-supply = <&vccio_sd>; + pinctrl-names = "default"; + pinctrl-0 = <&sdmmc0_bus4 &sdmmc0_clk &sdmmc0_cmd &sdmmc0_det &sdmmc0_pwren>; + status = "okay"; +}; + +&uart2 { + status = "okay"; +}; + +&usb2phy0_host { + phy-supply = <&vcc5v0_usb30>; + status = "okay"; +}; + +&usb2phy1_host { + status = "okay"; +}; + +&usb2phy1_otg { + status = "okay"; +}; + +&usb_host0_ehci { + status = "okay"; +}; + +&usb_host1_xhci { + status = "okay"; +}; + +&vop { + assigned-clocks = <&cru DCLK_VOP0>, <&cru DCLK_VOP1>; + assigned-clock-parents = <&pmucru PLL_HPLL>, <&cru PLL_VPLL>; + status = "okay"; +}; + +&vop_mmu { + status = "okay"; +}; + +&vp0 { + vp0_out_hdmi: endpoint@ROCKCHIP_VOP2_EP_HDMI0 { + reg = ; + remote-endpoint = <&hdmi_in_vp0>; + }; +};