Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp3492121ybl; Sun, 15 Dec 2019 11:01:18 -0800 (PST) X-Google-Smtp-Source: APXvYqwNX1C7ZBcypBcAxvYIxvdv2c2x+5cmgPrtED4oaTLL66pysbVqbk8liTI33YwCYo/pXdGm X-Received: by 2002:a05:6830:60f:: with SMTP id w15mr27830614oti.225.1576436478060; Sun, 15 Dec 2019 11:01:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576436478; cv=none; d=google.com; s=arc-20160816; b=Uw8GilvIC2RjXPSdiRL8VFjYLk2RhzjUNpZ+wvKFKXnM676kWQrKUbvUvpEMGz7ljU DL8/SA+VmL783pzCsTmrEoaR1r7UPRLep+ga2SOAlPxZcCxGUFlm2qTj+SsUqg91+Tm1 5x3QHYBS1+hkdhd53mePY19rW3Ytxg/JME/bE/e3ZtiW95eJ1qt5A47PLdDwCNqR3YhL UvPuyCnoydfNYpyoVl5vuHbkiV4jt3r4EtpMUyahTrT80tvyaozYL05icUjqt/gH8/NQ ZHZE7T5q8Obn7ADNGCuSVETMJElhIX5iL/G3HOdIPWXBhGxsLgCQLmwm5CCMHOCIOl3b MIZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=5zj0shl15ES5qDsvvytCNaNtROHrqNPVUl5RHKFbRRg=; b=Nq2iRsdaF6ZL/eySUdWR0aa28EOJvzNaztj82Py4O10Rj1wdV6EjCyXEi9sl6P0hpl MSKe+MtfmSSf9w7eqKJWg4XG3+XRD3E3QDq8GCtvPiCfQqrWG9d18xG+RgJgFTCK1PBY 5pJx4kwuR56qh4NHwJzzHwozPqpYpQaB1lnXVuBGDireSfwnR9QYEFeDVKLE3daHVuB5 tlZktZtCNMqbRwJl7/4747kzcoP9PjEEzY0YWwyuuSmBFSys9m24FGzPYC2+Re2AXY+B io8LXY69YCUjY+vHRAIMJvMRPO6b3GsBVOwSOyLfY6WZKDvPVJgXebBGRtFU44ZKplug hgTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@openedev.com header.s=default header.b=FJkY50FN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x2si9153916otk.66.2019.12.15.11.01.05; Sun, 15 Dec 2019 11:01:18 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@openedev.com header.s=default header.b=FJkY50FN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726346AbfLOTAY (ORCPT + 99 others); Sun, 15 Dec 2019 14:00:24 -0500 Received: from se15p.web-hosting.com ([198.54.122.235]:55939 "EHLO se15p.web-hosting.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1726146AbfLOTAY (ORCPT ); Sun, 15 Dec 2019 14:00:24 -0500 Received: from [68.65.123.203] (helo=server153.web-hosting.com) by se18.registrar-servers.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89) (envelope-from ) id 1igXp3-0000FJ-OY; Sun, 15 Dec 2019 09:36:54 -0800 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=openedev.com; s=default; h=Message-Id:Date:Subject:Cc:To:From:Sender: Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=5zj0shl15ES5qDsvvytCNaNtROHrqNPVUl5RHKFbRRg=; b=FJkY50FN2m1mnbbyqDgdU7qu7U vwNo3adf3NbikqyrqXeWGjTWToQCAYwTgQB3WnfCBkQkSROYtwoW9MISAGNaqPWDUw8k+UizS/vG5 Yc0Sr03b94CN1cLCNNxe5T40NZUguXDP7pDqJ83hdUJuBcOUIBhEj6ArdUy9exCdgqzoTNsQNrpAX 7IoNi1mNYQIcxRXHaKTSrqPa4/vCDWR+0D/fKKOs3DM5E8DAS2K6RKydg+EybxxhHC2WWt5MPDN5Q XP/v6f7ow0io94jj8cAh+4Qh5YvOO50e6HyBfTDm+4Ca8kuNO4GNPXu3Y+89PLgWPaElYd9eSHPic RdkQ0k3w==; Received: from [49.36.128.5] (port=59799 helo=localhost.localdomain) by server153.web-hosting.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.92) (envelope-from ) id 1igXoo-000nzF-Gg; Sun, 15 Dec 2019 12:36:39 -0500 From: Akash Gajjar To: heiko@sntech.de Cc: jagan@openedev.com, Akash Gajjar , Rob Herring , Mark Rutland , Douglas Anderson , Robin Murphy , Andy Yan , Nick Xie , Matthias Kaehlcke , Kever Yang , Markus Reichl , Tomeu Vizoso , Vivek Unune , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] arm64: dts: rockchip: add ROCK Pi S DTS support Date: Sun, 15 Dec 2019 23:03:08 +0530 Message-Id: <20191215173318.16385-1-akash@openedev.com> X-Mailer: git-send-email 2.17.1 X-OutGoing-Spam-Status: No, score=-1.0 X-Originating-IP: 68.65.123.203 X-SpamExperts-Domain: nctest.net X-SpamExperts-Username: whmcalls3 Authentication-Results: registrar-servers.com; auth=pass (login) smtp.auth=whmcalls3@nctest.net X-SpamExperts-Outgoing-Class: ham X-SpamExperts-Outgoing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Rsz0s8Db1PmgmzCcMa7ulPKQwljdxbXpCgbiKBsA+Ddi6m awf7qIPrXD/wjVs/n8fM5ydr4VRbSFCvnbggoY4Wvq8a9PDk3+iNqiYKhZaJO2iXygidb7xKf9ye n1ptsyeNpBLGYEQKJVyp/FQfUJeyh3UYNr1P8PrBEjUzBQOhtbGwOd/74O4hBSz/kkmPgL+fgIgu BWHJWcnjJ9Yw6nh4SabxNBlhRZKXVntiqJqwMz/WEzMRoKk+qdPdN+VHhkPkWFLLL/MajuTZZYrm IMPpJ01xNSLp8yK4HDX6CXKW1cjrmvSDyiGG9+F7gBuhhNiu6O9mcHFleJWRxdnH7qtGkGOZyOYN g9LcQCKZJyjZYhbcjZvoDgYD3LnUviLybo/lpLC3HHASJNUmoOHSoqgqxfHmWRkdQL1gXJvwL5op HNLdfid/oune33LSDO2jwIIX2HH6/Xaa2YE7nuBo2iwEIN3pGn5OoRY51umiSqH1CKu9nM8fKghZ uFuu++HSP4Hpd2sDdKgNSxpke6tG5/V0WQwo339q0aZI3qbhXsaDdLgW9bry4KJcrxSUzWDT2Gb/ yQXL5tP3WJd7sb8yEkSOtPpidAKWF8gSL91Ajw1AlIFKkYk= X-Report-Abuse-To: spam@se16.registrar-servers.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ROCK Pi S is RK3308 based SBC from radxa.com. ROCK Pi S has a, - 256MB/512MB DDR3 RAM - SD, NAND flash (optional on board 1/2/4/8Gb) - 100MB ethernet, PoE (optional) - Onboard 802.11 b/g/n wifi + Bluetooth 4.0 Module - USB2.0 Type-A HOST x1 - USB3.0 Type-C OTG x1 - 26-pin expansion header - USB Type-C DC 5V Power Supply This patch enables - Console - NAND Flash - SD Card Signed-off-by: Akash Gajjar --- .../devicetree/bindings/arm/rockchip.yaml | 5 + arch/arm64/boot/dts/rockchip/Makefile | 1 + .../boot/dts/rockchip/rk3308-rock-pi-S.dts | 221 ++++++++++++++++++ 3 files changed, 227 insertions(+) create mode 100644 arch/arm64/boot/dts/rockchip/rk3308-rock-pi-S.dts diff --git a/Documentation/devicetree/bindings/arm/rockchip.yaml b/Documentation/devicetree/bindings/arm/rockchip.yaml index d9847b306b83..48d40c928d45 100644 --- a/Documentation/devicetree/bindings/arm/rockchip.yaml +++ b/Documentation/devicetree/bindings/arm/rockchip.yaml @@ -422,6 +422,11 @@ properties: - const: radxa,rockpi4 - const: rockchip,rk3399 + - description: Radxa ROCK Pi S + items: + - const: radxa,rockpis + - const: rockchip,rk3308 + - description: Radxa Rock2 Square items: - const: radxa,rock2-square diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile index 48fb631d5451..cc9e8c824980 100644 --- a/arch/arm64/boot/dts/rockchip/Makefile +++ b/arch/arm64/boot/dts/rockchip/Makefile @@ -2,6 +2,7 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += px30-evb.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3308-evb.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3308-roc-cc.dtb +dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3308-rock-pi-S.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-a1.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-evb.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-rock64.dtb diff --git a/arch/arm64/boot/dts/rockchip/rk3308-rock-pi-S.dts b/arch/arm64/boot/dts/rockchip/rk3308-rock-pi-S.dts new file mode 100644 index 000000000000..e5fae451c631 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3308-rock-pi-S.dts @@ -0,0 +1,221 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +/* + * Copyright (c) 2019 Akash Gajjar + * Copyright (c) 2019 Jagan Teki + */ + +/dts-v1/; +#include "rk3308.dtsi" + +/ { + model = "Radxa ROCK Pi S"; + compatible = "radxa,rockpis", "rockchip,rk3308"; + + chosen { + stdout-path = "serial0:1500000n8"; + }; + + leds { + compatible = "gpio-leds"; + pinctrl-names = "default"; + pinctrl-0 = <&green_led_gio>, <&heartbeat_led_gpio>; + + green-led { + label = "rockpis:green:power"; + gpios = <&gpio0 RK_PA6 GPIO_ACTIVE_HIGH>; + linux,default-trigger = "default-on"; + default-state = "on"; + }; + + blue-led { + label = "rockpis:blue:user"; + gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_HIGH>; + default-state = "on"; + linux,default-trigger = "heartbeat"; + }; + }; + + sdio_pwrseq: sdio-pwrseq { + compatible = "mmc-pwrseq-simple"; + pinctrl-names = "default"; + pinctrl-0 = <&wifi_enable_h>; + reset-gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_LOW>; + }; + + vcc5v0_sys: vcc5v0-sys { + compatible = "regulator-fixed"; + regulator-name = "vcc5v0_sys"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + }; + + vdd_core: vdd-core { + compatible = "pwm-regulator"; + pwms = <&pwm0 0 5000 1>; + regulator-name = "vdd_core"; + regulator-min-microvolt = <827000>; + regulator-max-microvolt = <1340000>; + regulator-init-microvolt = <1015000>; + regulator-settling-time-up-us = <250>; + regulator-always-on; + regulator-boot-on; + vin-supply = <&vcc5v0_sys>; + }; + + vdd_log: vdd-log { + compatible = "regulator-fixed"; + regulator-name = "vdd_log"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1050000>; + regulator-max-microvolt = <1050000>; + vin-supply = <&vcc5v0_sys>; + }; + + vcc_ddr: vcc-ddr { + compatible = "regulator-fixed"; + regulator-name = "vcc_ddr"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1500000>; + regulator-max-microvolt = <1500000>; + vin-supply = <&vcc5v0_sys>; + }; + + vcc_1v8: vcc-1v8 { + compatible = "regulator-fixed"; + regulator-name = "vcc_1v8"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + vin-supply = <&vcc_io>; + }; + + vcc_io: vcc-io { + compatible = "regulator-fixed"; + regulator-name = "vcc_io"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <&vcc5v0_sys>; + }; + + vcc5v0_otg: vcc5v0-otg { + compatible = "regulator-fixed"; + regulator-name = "vcc5v0_otg"; + regulator-always-on; + gpio = <&gpio0 RK_PC5 GPIO_ACTIVE_HIGH>; + enable-active-high; + pinctrl-names = "default"; + pinctrl-0 = <&otg_vbus_drv>; + vin-supply = <&vcc5v0_sys>; + }; +}; + +&cpu0 { + cpu-supply = <&vdd_core>; +}; + +&emmc { + bus-width = <4>; + cap-mmc-highspeed; + mmc-hs200-1_8v; + supports-sd; + disable-wp; + non-removable; + num-slots = <1>; + vin-supply = <&vcc_io>; + status = "okay"; +}; + +&i2c1 { + status = "okay"; +}; + +&sdmmc { + bus-width = <4>; + cap-mmc-highspeed; + cap-sd-highspeed; + max-frequeency = <150000000>; + supports-sd; + disable-wp; + num-slots = <1>; + pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_det &sdmmc_bus4>; + card-detect-delay = <800>; + status = "okay"; +}; + +&spi2 { + status = "okay"; + max-freq = <10000000>; +}; + +&pinctrl { + pinctrl-names = "default"; + pinctrl-0 = <&rtc_32k>; + + leds { + green_led_gio: green-led-gpio { + rockchip,pins = <0 RK_PA6 RK_FUNC_GPIO &pcfg_pull_none>; + }; + + heartbeat_led_gpio: heartbeat-led-gpio { + rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; + + usb { + otg_vbus_drv: otg-vbus-drv { + rockchip,pins = <0 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; + + sdio-pwrseq { + wifi_enable_h: wifi-enable-h { + rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>; + }; + + wifi_host_wake: wifi-host-wake { + rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_down>; + }; + }; +}; + +&pwm0 { + status = "okay"; + pinctrl-0 = <&pwm0_pin_pull_down>; +}; + +&saradc { + vref-supply = <&vcc_1v8>; + status = "okay"; +}; + +&sdio { + #address-cells = <1>; + #size-cells = <0>; + bus-width = <4>; + max-frequency = <1000000>; + cap-sd-highspeed; + cap-sdio-irq; + supports-sdio; + keep-power-in-suspend; + mmc-pwrseq = <&sdio_pwrseq>; + non-removable; + sd-uhs-sdr104; + status = "okay"; +}; + +&uart0 { + status = "okay"; +}; + +&uart4 { + pinctrl-names = "default"; + pinctrl-0 = <&uart4_xfer &uart4_rts &uart4_cts>; + status = "okay"; +}; -- 2.17.1