From patchwork Mon Mar 24 17:04:22 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Reichel X-Patchwork-Id: 14027553 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D4FB8C36002 for ; Mon, 24 Mar 2025 17:13:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=XWTHlJGOStfnnC8LJbESbz/djiHJ7q5c3ZSsnevyaJQ=; b=tyKu4csIMkiruE tCa1AGs63/BXDKlCQHFDquDBtVSZQUOyUq6niR5DG45As6RZ34fHTT1Xc4ga6//4X/oUTzxRSCkFB u0wdCycskgMVJXdXglTBH03CFuXcVEe0g8GK4QfoazACrnrvtetVT2QOhRgIZWWlu51KFkZLpj5NL FktuDN4OAOHrdXy41kD8I/P61/9xJaB2pVw/gwZjCIW2RYWc5l432RdHenvDOXNpQXz0Wqo9SSxp9 t1YNDmVlRykHy92JIaBiYblcqMFazX8HBUfrXikmsEB2Jkgwj9ctiKvQC1aQ3Ll4XdrwqEffzaH3G VZRJ18QN5fZGdSQKeRAQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1twlMQ-00000003lRl-3vxd; Mon, 24 Mar 2025 17:13:14 +0000 Received: from bali.collaboradmins.com ([2a01:4f8:201:9162::2]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1twlDt-00000003k2N-0DU7; Mon, 24 Mar 2025 17:04:30 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1742835863; bh=NcPJopNj4QkFL7RS7LVqktzn6/GCRQbuGX0pRkX8TIA=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=KvIyrkXjD1AqH24UsP+0/qiibVyXFwpBc+LY1/w6GIg0XBoP1YoQtWTien4bT499O oU9EStS6kAO+0luuoMJokjzOsINpTgLCY5Ctk1ykYpCfJJDgy67juhAr9ltylCjqGV y++JZZabIKxqj70NR2o20BXmnh9pCa/OL14KhRPYIL/KCsgk9U4xkeHxAkCF59Lw/E 5kfMNXQzM+2AZ4ZV2/8Bb3cP3l1eUcuAoDdR6oOVhiaagfOY2GH96Ks7kBqzh5/Btv Mb1wpOipEpUObxEkFhl7vHfaGiDVj6ndV5Pdne2gUAa8rKDUNJ2Giwc4L4gRq+jCEK z+0UrEhEp8SLQ== Received: from jupiter.universe (dyndsl-091-248-188-184.ewe-ip-backbone.de [91.248.188.184]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: sre) by bali.collaboradmins.com (Postfix) with ESMTPSA id 18B2617E0A80; Mon, 24 Mar 2025 18:04:23 +0100 (CET) Received: by jupiter.universe (Postfix, from userid 1000) id D647F480036; Mon, 24 Mar 2025 18:04:22 +0100 (CET) From: Sebastian Reichel Date: Mon, 24 Mar 2025 18:04:22 +0100 Subject: [PATCH 1/5] arm64: dts: rockchip: move rock 5b to include file MIME-Version: 1.0 Message-Id: <20250324-rock5bp-for-upstream-v1-1-6217edf15b19@kernel.org> References: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> In-Reply-To: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> To: Heiko Stuebner Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org, Sebastian Reichel X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=992; i=sre@kernel.org; h=from:subject:message-id; bh=NcPJopNj4QkFL7RS7LVqktzn6/GCRQbuGX0pRkX8TIA=; b=owJ4nAFtApL9kA0DAAoB2O7X88g7+poByyZiAGfhkJbrMXGmfQ2nwIyb2HseFcb3BZuRbFxhj lv3TZvWB0s134kCMwQAAQoAHRYhBO9mDQdGP4tyanlUE9ju1/PIO/qaBQJn4ZCWAAoJENju1/PI O/qaLzkP/AiLeIlniF7EV2ceuFniQbWROAgLHK5bQo4k/CkqYVE9NvW+ia54EEqwOENOB/Ro+VN +mFX8AvAtVOnqsn40lf9Xg+9dlJdZFvJaOCZLSNdscRBHujP/eu1COtwusr0A9Dwq4PD0cX4fd7 2XCvFiRtkLBwGFmfgaRqEgvu8yqLtD25/wnDF4zmkiA/C4A/GDL1GrQZZ8OWILvkNz2j96+w3ix Cxlf9HpZ5PcrLOhSxxaWZ93kj76sVRrYVSw/9qfqONTeHJjYktWjvGq2o1aL1M6dRifDYBq5agl ikazqgLAKcU3HLKdq+G+JWUjLKYEQUffaqENv3hmk/d2mQLQznwVAsiNLxKdPSaTAJSDYLxLZHL ScSw/LfWM89e8nbmbdbczScUn4G4HoJ8Krt9N4LlS4w+5Kkt/JOiyXBoyzWUBcpT6FJPhJdxFlv ZjZAOJZuWT+PYOTjoFDNr22IdB/w0U9Yq1iUbFHGhyQjbEJJKL2yvbJ+RU+OpCDbKrOz69+ZbP1 VZyhxxrzKaHg1YBFcTyEa3DA2mRUaSGLtpUSqZKKlHEocLIjw+2JsPB8Dp07y1Pp/1eutyfnA/0 m5pXeBEV7lPTd76F/5yLkGh2RTgHcHLBtJbU8VzFqeopg8teAo9cJozf8WeAopHSt6ULq7ZQnyS KeK/MncpkkgSh8JOybwYuGA== X-Developer-Key: i=sre@kernel.org; a=openpgp; fpr=EF660D07463F8B726A795413D8EED7F3C83BFA9A X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250324_100425_279779_311C986D X-CRM114-Status: GOOD ( 11.89 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org Radxa released some more boards, which are based on the original Rock 5B. Move its board description into an include file to avoid unnecessary duplication. NOTE: this should be merged with the following commit to ensure bisectability. The rename happens in a separete commit during development because git does not properly detect the rename when the original filename is reused in the same commit. This means 1. it's a lot harder to review the changes 2. it's a lot harder to rebase the patch series Signed-off-by: Sebastian Reichel --- arch/arm64/boot/dts/rockchip/{rk3588-rock-5b.dts => rk3588-rock-5b.dtsi} | 0 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi similarity index 100% rename from arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts rename to arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi From patchwork Mon Mar 24 17:04:23 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Reichel X-Patchwork-Id: 14027548 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 390C0C36002 for ; Mon, 24 Mar 2025 17:11:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=fkzCVumoVL03yBwONjXSkNg5cPaKnHErNAazOZr4neQ=; b=zkEJXGpu6S6Etp GuyzHzxx78xtAqd9l1r0YByv7Imyl6RjQC0iI4gDoV1eVWM7ZQgrpVf8mgn4yrJBBQu0DmoMRBlAj vXkzkieCtwAsj5FAikXplfKiwRccouS4KtPSVMAcp68MJo8TIoTUtxUvfVL4ParmuqRO7XBBao9a1 TmQrD9WWS38OEYC+4vH0pa0ZbA9nwyol+2vg75Iw3qcsDFmTWb0LNqYFMxtIjlIJLOVNVc8ru70no cDm8N5RNEasL5Oc5jnXRDJTWlCxCCXLrhhlcK7lk0oVRAmsTsT2P6p5MxAi9180riRuaFfb7FVGOg yMDOkmQJOMsWybktuPZg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1twlKj-00000003lIY-3lNA; Mon, 24 Mar 2025 17:11:29 +0000 Received: from bali.collaboradmins.com ([148.251.105.195]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1twlDs-00000003k2S-4AVi; Mon, 24 Mar 2025 17:04:28 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1742835863; bh=Z1D9b/aDklkV/w1jDdHJ0QT0NlOJuOAq6fuu6adnAX4=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=RCTRxrRtcqyjnzZbZJxyNPhS3zz0EDcj4dHkNReppdgRJmRS/TkTSpuITq+qifDQZ 21PMGBVLQ0N/yb30qqkzp1SALU5SkUUGr/GYptGL848tRW71dn38mk7sqZ2S1cYpwH CrxDpa3C2iW+tGku0eESeVxQMiZVfycnPOtbaTYFdOT4+PywpshGOoIS8Y3RoXOhUb 4OrvzVRG3Sl6w/CTqWtPuHt6TGA30GxoxKijZKB/fb2r1swbCuTF4tYHUp9jJEZMZc 0Dg41JeLlk7NDE2Mbak+m+Qw98uMnp0Ikz4skvSCHPu9sna4hOodLeJ8THRK5fDqnu QQPcFctnVxPSw== Received: from jupiter.universe (dyndsl-091-248-188-184.ewe-ip-backbone.de [91.248.188.184]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: sre) by bali.collaboradmins.com (Postfix) with ESMTPSA id 1B8A317E0B9D; Mon, 24 Mar 2025 18:04:23 +0100 (CET) Received: by jupiter.universe (Postfix, from userid 1000) id D779B480037; Mon, 24 Mar 2025 18:04:22 +0100 (CET) From: Sebastian Reichel Date: Mon, 24 Mar 2025 18:04:23 +0100 Subject: [PATCH 2/5] arm64: dts: rockchip: move rock 5b to include file MIME-Version: 1.0 Message-Id: <20250324-rock5bp-for-upstream-v1-2-6217edf15b19@kernel.org> References: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> In-Reply-To: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> To: Heiko Stuebner Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org, Sebastian Reichel X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=3778; i=sre@kernel.org; h=from:subject:message-id; bh=Z1D9b/aDklkV/w1jDdHJ0QT0NlOJuOAq6fuu6adnAX4=; b=owJ4nAFtApL9kA0DAAoB2O7X88g7+poByyZiAGfhkJZwAq2N9fnfh21CieN/Jfy7/q5h02WRO qr7EplupgmG5okCMwQAAQoAHRYhBO9mDQdGP4tyanlUE9ju1/PIO/qaBQJn4ZCWAAoJENju1/PI O/qaSMoQAJ0Tn5Do38EbDJ08eAFM6r9GiVzR0ma0pIDj7kdnFcgEZDTNWEQfsZn2HVgD7bnKUAZ 7U9j3odFs3HMmcc1HYHkx/iEUYvpc5sl+9i3YtivSEa0GK84dAJs1DrFlS+6hTvy3ATvAogGDp2 gn/tf2cPvLj5ZI/Qx1FT5nY50efyQ6NstPilFeioZLn/rNWAFqCf/udl2rLe1m7ovBvSnFunW3i rjqabbRwcKMRy9QLM9qvBSmrKqvxJnwlJP2GiGpvofNvoaxcj3sLe/bqKCL4w76RI4FuF9bVy/U Jzj/BFU3OCsWhxQ/qJLLch8JT55nxGkY1J8yBrZhxX7rVG8ftCCHbSjO8v3W2gHWRYRAhCrVZ6q O7eejooYeqKr/spWlm6J4UZ7cUbi+2xzLva9eM2jAXnKgdj4ls/rX4IS+SKlguLT/tp8CWGvN1p qvwxubRWO+ABDn6Bte1FtfkGJuzTb1K/kV4tHWpRjvL5Vxg1B847OJZBPb9hJDvYeFB4AvLu8jJ QdK9fk7YrHgH90sAjh90qoDFTutQjbg/uK6+Fae0i/bckBvWDtx/t2SYDdTRxYPS71pG6QlJ2cV 4uFMQ3OzlcYUTsFsAN7HSBh05F5Sc8fXcvZiaRgTnWpPow1xq2Nj9Tx/s87xz71B2g/Y2x0AEJ6 rGHx379F4nLA26Ndl1PE2VA== X-Developer-Key: i=sre@kernel.org; a=openpgp; fpr=EF660D07463F8B726A795413D8EED7F3C83BFA9A X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250324_100425_200002_1DF40802 X-CRM114-Status: GOOD ( 16.37 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org Radxa released some more boards, which are based on the original Rock 5B. Move its board description into an include file to avoid unnecessary duplication. NOTE: this should be merged with the previous commit to ensure bisectability. The rename happens in a separete commit during development because git does not properly detect the rename when the original filename is reused in the same commit. This means 1. it's a lot harder to review the changes 2. it's a lot harder to rebase the patch series Signed-off-by: Sebastian Reichel --- arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts | 52 ++++++++++++++++++++++++ arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi | 34 ---------------- 2 files changed, 52 insertions(+), 34 deletions(-) diff --git a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts new file mode 100644 index 0000000000000000000000000000000000000000..9407a7c9910ada1f6c803d2e15785a9cbd9bd655 --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts @@ -0,0 +1,52 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) + +/dts-v1/; + +#include "rk3588-rock-5b.dtsi" + +/ { + model = "Radxa ROCK 5B"; + compatible = "radxa,rock-5b", "rockchip,rk3588"; +}; + +&sdio { + max-frequency = <200000000>; + no-sd; + no-mmc; + non-removable; + bus-width = <4>; + cap-sdio-irq; + disable-wp; + keep-power-in-suspend; + wakeup-source; + sd-uhs-sdr12; + sd-uhs-sdr25; + sd-uhs-sdr50; + sd-uhs-sdr104; + vmmc-supply = <&vcc3v3_pcie2x1l0>; + vqmmc-supply = <&vcc_1v8_s3>; + pinctrl-names = "default"; + pinctrl-0 = <&sdiom0_pins>; + status = "okay"; +}; + +&uart6 { + pinctrl-names = "default"; + pinctrl-0 = <&uart6m1_xfer &uart6m1_ctsn &uart6m1_rtsn>; + status = "okay"; +}; + +&pinctrl { + usb { + vcc5v0_host_en: vcc5v0-host-en { + rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; +}; + +&vcc5v0_host { + enable-active-high; + gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&vcc5v0_host_en>; +}; diff --git a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi index d22068475c5dc6cb885f878f3f527a66edf1ba70..dccb8492f9f0632abd96c3dafc723e01491abad5 100644 --- a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi @@ -8,9 +8,6 @@ #include "rk3588.dtsi" / { - model = "Radxa ROCK 5B"; - compatible = "radxa,rock-5b", "rockchip,rk3588"; - aliases { mmc0 = &sdhci; mmc1 = &sdmmc; @@ -139,10 +136,6 @@ vcc5v0_host: regulator-vcc5v0-host { regulator-always-on; regulator-min-microvolt = <5000000>; regulator-max-microvolt = <5000000>; - enable-active-high; - gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_HIGH>; - pinctrl-names = "default"; - pinctrl-0 = <&vcc5v0_host_en>; vin-supply = <&vcc5v0_sys>; }; @@ -530,27 +523,6 @@ &sdmmc { status = "okay"; }; -&sdio { - max-frequency = <200000000>; - no-sd; - no-mmc; - non-removable; - bus-width = <4>; - cap-sdio-irq; - disable-wp; - keep-power-in-suspend; - wakeup-source; - sd-uhs-sdr12; - sd-uhs-sdr25; - sd-uhs-sdr50; - sd-uhs-sdr104; - vmmc-supply = <&vcc3v3_pcie2x1l0>; - vqmmc-supply = <&vcc_1v8_s3>; - pinctrl-names = "default"; - pinctrl-0 = <&sdiom0_pins>; - status = "okay"; -}; - &sfc { pinctrl-names = "default"; pinctrl-0 = <&fspim2_pins>; @@ -565,12 +537,6 @@ flash@0 { }; }; -&uart6 { - pinctrl-names = "default"; - pinctrl-0 = <&uart6m1_xfer &uart6m1_ctsn &uart6m1_rtsn>; - status = "okay"; -}; - &spi2 { status = "okay"; assigned-clocks = <&cru CLK_SPI2>; From patchwork Mon Mar 24 17:04:24 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Reichel X-Patchwork-Id: 14027541 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7B9A2C36002 for ; Mon, 24 Mar 2025 17:06:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ueaSBnXRGpHi36NYa+Na/U9WAoeUuRMNVzyvDpe/cMs=; b=w0BlUkHKZ1EIqg iI6QszB2dRWb7j/jMAiONkmY+hbHzT4ki0S14DPoUxTfqsQWheWCBELsFJCvqpTX5dkl+E6r+L/gT ZKNoAmlfRi5TH1Ujhnbzmqk5dQA0/50EaIHiVyI8kD4h+TwZm1g7mQi8ccOZp5e6aeXDa+IbXBXaa YJyYplv4HPZU4u3GccccC+3Ggcs14i25y+M5hxJqLz7EwxglHcBRJ/yL2nXyPp18CHaI5FgHb8Tar GV3ZG4icJKc9ukOelYUuTC3CmBjVzsW+V6e42q+4tUN6nMZEddvr7GA8j+iTIiUAxP3mHqHy18/Si Un6oWD9ZQ6GZkD5UcEaw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1twlFd-00000003kOC-1pMX; Mon, 24 Mar 2025 17:06:13 +0000 Received: from bali.collaboradmins.com ([148.251.105.195]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1twlDs-00000003k2M-4AF5; Mon, 24 Mar 2025 17:04:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1742835863; bh=KRP0aB0pusR6DQBo1puDDmnz/hEZTuxKlnUQvRPL9e4=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=qhcWTwB7Lw72A+2me8o8c+bw2ezh2TtX0zW8WGnP9szUu5+aLPcX9tYZxld1GLQFs BjzN/BHtK61M1mmOQOxR5TO0UmjaZFLR1Nww5xDHv2tWuG1/a6MXqsSfn7MXBznc1v GrCI2AIptqKFlw5ZZGtzN3JVEBfyuheZ+kRZwQq+1Hihm3EUq/4klWGwPKxgLOfhGy qpTAG5oaTRNXEJsIdcGLRW/9aY76TShdiLJAIOH52q5iKoFyIgD209XDOGAPcplAqb RoAeTqq2p+KLV5UfK2moqcLLu41THZrQnyoGKF5z59wvVjFtdgKZf2tB0ysSdiKWWG ioYwN8i+VCdyg== Received: from jupiter.universe (dyndsl-091-248-188-184.ewe-ip-backbone.de [91.248.188.184]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: sre) by bali.collaboradmins.com (Postfix) with ESMTPSA id 1DA8F17E0C37; Mon, 24 Mar 2025 18:04:23 +0100 (CET) Received: by jupiter.universe (Postfix, from userid 1000) id D89FE480038; Mon, 24 Mar 2025 18:04:22 +0100 (CET) From: Sebastian Reichel Date: Mon, 24 Mar 2025 18:04:24 +0100 Subject: [PATCH 3/5] dt-bindings: arm: rockchip: Add Radxa ROCK 5B+ MIME-Version: 1.0 Message-Id: <20250324-rock5bp-for-upstream-v1-3-6217edf15b19@kernel.org> References: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> In-Reply-To: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> To: Heiko Stuebner Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org, Sebastian Reichel X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=917; i=sre@kernel.org; h=from:subject:message-id; bh=KRP0aB0pusR6DQBo1puDDmnz/hEZTuxKlnUQvRPL9e4=; b=owJ4nAFtApL9kA0DAAoB2O7X88g7+poByyZiAGfhkJa5ha6/bzlUoT/H5amcvXsgWlJstfOTA B+/e6TTdOYmjokCMwQAAQoAHRYhBO9mDQdGP4tyanlUE9ju1/PIO/qaBQJn4ZCWAAoJENju1/PI O/qar/wQAKYdC1NWfYRLSF+z7pSP/dBf3sqEwevqmFHlNLJkmXJeFa5NTxxfvuwcX4vGn+sozlj VvYxkIk1VRb7evsbngaO8LYLdGqt3EGfgcHZFAGvA3X+pldhP5zWragTrkYA1Br2DGC0s/8I+xd 8dc++0XPVS6XvCucWxGdslvFehTSx/rjPP64DcZ/5lSJHzlIg3s2Jx8CXE7q+EOUBPkAAikUAKz jX+QWwrgF9IkP0VEcsy8pEyjMMs2aXi9tbnJW0Ci41tz9usgDuL9DbzHgMvrtToPQ4d0kyOKz7A iAL/GEZfkoilnzWAsAJ0spIiA9hP3lPoPerxu9nacOOgX75iD/wAZ8Iz17gtpJM1oKaR53m2MYN OQaN7U44NjwImIENC92Ncq4NELtMCvd5UwKv/G8FATswloGw4t1ynWxM87ZWh4QOPmcIDjK8JWh synW/ILzuBKif1a0PljfrgMuWqmrZJa6brU/bJmBxnD9sPYp6jslK4FbAgYJiygxkGaerb8tWdd BQjQYXUdU4qwU0TW4zjXFt8Jwhq9fIFsvIB5Ei6GGPWPDDubDO7hseeiGGyK6ivqhXBIyOVyeau cLwWqkMLQqZTbKoZh+AfMvRyzefmxpoUPG1tv2hzywI2ScSNpa8xbOkVsIEpXSPsoU/VlTpAEDo YRbUI/YM0GswTPeSGsfsv+w== X-Developer-Key: i=sre@kernel.org; a=openpgp; fpr=EF660D07463F8B726A795413D8EED7F3C83BFA9A X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250324_100425_193119_983C36B4 X-CRM114-Status: UNSURE ( 9.00 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org The Radxa ROCK 5B+ is an improved version of the ROCK 5B. Signed-off-by: Sebastian Reichel --- Documentation/devicetree/bindings/arm/rockchip.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Documentation/devicetree/bindings/arm/rockchip.yaml b/Documentation/devicetree/bindings/arm/rockchip.yaml index 650fb833d96ef67ea1bba33c0767777378a38fa7..fe1fe8fe52fa3594a0da8e0263cb46949436a021 100644 --- a/Documentation/devicetree/bindings/arm/rockchip.yaml +++ b/Documentation/devicetree/bindings/arm/rockchip.yaml @@ -946,6 +946,11 @@ properties: - const: radxa,rock-5b - const: rockchip,rk3588 + - description: Radxa ROCK 5B+ + items: + - const: radxa,rock-5b-plus + - const: rockchip,rk3588 + - description: Radxa ROCK 5C items: - const: radxa,rock-5c From patchwork Mon Mar 24 17:04:25 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Reichel X-Patchwork-Id: 14027547 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AE45AC36002 for ; Mon, 24 Mar 2025 17:09:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=HY+aOPHcWkG6IrITLYMxpA8wVs6uWtnRmDsvIFJBsl4=; b=Jq4YA6UebeJ4rw yc18m+HkhFKSIxlFbsfvkSxMTltDwcOeOc+vV5apV19J02Q8daX0NOS24E66eW8PnvXp/5Ozv6Wrg A/Kjv/gNQZZExnxMqcnidI8eP7B2eEqhLQ+44fvmAyCdmKVWpw3ZPXRPlPpR3KlztlKi9d0vtC1bR 1YY2WGfX7cmwMZFG41zQt56vWenFbK4EZKfkoBhUnGTBw4Kltom73GDnPTRNpeEPaGxBLFih7DI7A PVS5SXY9jkpp9mXvmbG3gVMj67NGSkFOVb7KXZPbUYPH88ZLCOl4bahqtkll4fgMeCmHeLD680Mku ji0Pu6mmL+Fba5e8kqnw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1twlJ2-00000003l0y-3hKr; Mon, 24 Mar 2025 17:09:44 +0000 Received: from bali.collaboradmins.com ([2a01:4f8:201:9162::2]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1twlDt-00000003k2P-0DOq; Mon, 24 Mar 2025 17:04:27 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1742835863; bh=0gLnYYOisV9YYhtXLBxrTYPVgD131atFQu3Y9z1S44o=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=QV8nQYO+jzLNvensNtcj6/LQdY9vARE3vSc1PSNfxkO/66mAPgmuRkkrD+bc93i5t rS3JXBHUe/rj/XZt3HHLagd9HWmdgJsZ1yrFch00R+5+hACrOO0MAgGB4QAPo9sKY5 g/SMEmjQY/13ELGaBfpF3DAhkT3NFXONo0VT+/gk4TDXSs3sOJG8YhgDnVlXcKV+15 DnyA66rP3cSZwQ2RBkUwYXb9FyqgzYrfV2T4Z0vc6mojYk4K0NyXFSBXITQuIkCgaZ FrfRHvOlJSfUyJljoW7RxpQhINxAaEDDIWj13gmq12ZpvvZ3v/2fAHekE3XyT48aec OEeOdUjcF1Ehw== Received: from jupiter.universe (dyndsl-091-248-188-184.ewe-ip-backbone.de [91.248.188.184]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: sre) by bali.collaboradmins.com (Postfix) with ESMTPSA id 1F9CB17E0C38; Mon, 24 Mar 2025 18:04:23 +0100 (CET) Received: by jupiter.universe (Postfix, from userid 1000) id D9D2E48003C; Mon, 24 Mar 2025 18:04:22 +0100 (CET) From: Sebastian Reichel Date: Mon, 24 Mar 2025 18:04:25 +0100 Subject: [PATCH 4/5] arm64: dts: rockchip: add Rock 5B+ MIME-Version: 1.0 Message-Id: <20250324-rock5bp-for-upstream-v1-4-6217edf15b19@kernel.org> References: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> In-Reply-To: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> To: Heiko Stuebner Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org, Sebastian Reichel X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=4423; i=sre@kernel.org; h=from:subject:message-id; bh=0gLnYYOisV9YYhtXLBxrTYPVgD131atFQu3Y9z1S44o=; b=owJ4nAFtApL9kA0DAAoB2O7X88g7+poByyZiAGfhkJbN2syahpd7q1NftmVTmOJ42npCvflWF gYQucPvSgCJS4kCMwQAAQoAHRYhBO9mDQdGP4tyanlUE9ju1/PIO/qaBQJn4ZCWAAoJENju1/PI O/qaZeIQAJV7JJ2sJ9TFjiFuBcEuVmsO8L6jg+YQbSmBAg8GprwIpT/OzdpY8z0mJe3rhXUHKHg TUiEVj9BPPpQZwSdFqw8EXh7BqmHJgE8hwxBtcAnQxzN6n2eTaaPAIQVscQfHBmIyXpEwIGarm6 i32ThHEWImpoE591c6sLSSVxOAKtkvhK/RdgrFHbOk/zbZI1HMaNYgKoxU3eYsQuD3EO9eL3bSM +LI3JlvSENfEBda9a6jMG/ofjwrwXQZgXACs+wMyZGqmgco9JdN6TyK9HswYaXtF53eFN2aeDZt VEia9Ll5i+Sj8YchDZbrhEkuq822YXPC6eRaTwfC5BH/3ZdSuShbmov7hrgMWjVTG4QpQPe2iUN xr6+CAt3XS8Pf2pFvejF3fZFhu3AZzJaUNVB88KtNKzdtPGY9HcWyJSVbUkf44DxpxL1h050kgK Jle7JAKOMqXWwUvwyRkRgOeZIgaYgv6Cy7F0A9ey9j7OaTiFp+HIr4/6fyaTmNfAP1F4OEu11QW udu2y5sq/ljFmegX3drKH/cuzsCTpgLd+jLPg0YyCQ4FIltfxlhTrKYBhPez14FFF4UWFjuK8JF EktSkuGcwrFA7QY64DEe4B7zCMJDXDzAAhYqNsHtCR53B8JcKH9SJWXCK8KYHQDd+FSt2YSZvS9 w7APpf3Dcw7EzVdglxt8eKw== X-Developer-Key: i=sre@kernel.org; a=openpgp; fpr=EF660D07463F8B726A795413D8EED7F3C83BFA9A X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250324_100425_439171_711B297C X-CRM114-Status: GOOD ( 15.46 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org Add ROCK 5B+, which is an improved version of the ROCK 5B with the following changes: * Memory LPDDR4X -> LPDDR5 * HDMI input connector size * eMMC socket -> onboard * M.2 E-Key is replaced by onboard RTL8852BE WLAN/BT * M.2 M-Key 1x4 lanes is replaced by 2x2 lanes * Added M.2 B-Key for USB connected WWAN modules (untested) * Add second camera port (not yet supported in upstream Linux) * Add dedicated USB-C port for device power (no impact in DT; the existing port has not been changed and the new port is handled by CH224D standalone chip) Signed-off-by: Sebastian Reichel --- arch/arm64/boot/dts/rockchip/Makefile | 1 + .../boot/dts/rockchip/rk3588-rock-5b-plus.dts | 113 +++++++++++++++++++++ 2 files changed, 114 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile index 3e8771ef69ba1c1428117cc2ae29b84e13523e21..6525329fcf060aeb89382d184ca4c6c5c1d07088 100644 --- a/arch/arm64/boot/dts/rockchip/Makefile +++ b/arch/arm64/boot/dts/rockchip/Makefile @@ -164,6 +164,7 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-rock-5-itx.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-rock-5b.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-rock-5b-pcie-ep.dtbo dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-rock-5b-pcie-srns.dtbo +dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-rock-5b-plus.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-tiger-haikou.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-toybrick-x0.dtb dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3588-turing-rk1.dtb diff --git a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b-plus.dts b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b-plus.dts new file mode 100644 index 0000000000000000000000000000000000000000..74c7b6502e4dda4b774f43c704ebaee350703c0d --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b-plus.dts @@ -0,0 +1,113 @@ +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) + +/dts-v1/; + +#include "rk3588-rock-5b.dtsi" + +/ { + model = "Radxa ROCK 5B+"; + compatible = "radxa,rock-5b-plus", "rockchip,rk3588"; + + rfkill-wwan { + compatible = "rfkill-gpio"; + label = "rfkill-m2-wwan"; + radio-type = "wwan"; + shutdown-gpios = <&gpio3 RK_PA6 GPIO_ACTIVE_HIGH>; + }; + + vcc3v3_4g: regulator-vcc3v3-4g { + compatible = "regulator-fixed"; + enable-active-high; + gpios = <&gpio1 RK_PD2 GPIO_ACTIVE_HIGH>; + /* pinctrl for the GPIO is requested by vcc3v3_pcie2x1l0 */ + regulator-name = "vcc3v3_4g"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + startup-delay-us = <50000>; + vin-supply = <&vcc5v0_sys>; + }; + + vcc3v3_wwan_pwr: regulator-vcc3v3-wwan { + compatible = "regulator-fixed"; + enable-active-high; + gpios = <&gpio2 RK_PB1 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&wwan_power_en>; + regulator-name = "vcc3v3_wwan_pwr"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + vin-supply = <&vcc3v3_4g>; + }; +}; + +&gpio0 { + wwan-disable2-n-hog { + gpios = ; + output-low; + line-name = "M.2 B-key W_DISABLE2#"; + gpio-hog; + }; +}; + +&gpio2 { + wwan-reset-n-hog { + gpios = ; + output-low; + line-name = "M.2 B-key RESET#"; + gpio-hog; + }; + + wwan-wake-n-hog { + gpios = ; + input; + line-name = "M.2 B-key WoWWAN#"; + gpio-hog; + }; +}; + +&pcie30phy { + data-lanes = <1 1 2 2>; +}; + +&pcie3x2 { + pinctrl-names = "default"; + pinctrl-0 = <&pcie3x2_rst>; + reset-gpios = <&gpio4 RK_PB0 GPIO_ACTIVE_HIGH>; + vpcie3v3-supply = <&vcc3v3_pcie30>; + status = "okay"; +}; + +&pcie3x4 { + num-lanes = <2>; +}; + +&pinctrl { + wwan { + wwan_power_en: wwan-pwr-en { + rockchip,pins = <2 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; + + pcie3 { + pcie3x2_rst: pcie3x2-rst { + rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; + + usb { + vcc5v0_host_en: vcc5v0-host-en { + rockchip,pins = <1 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>; + }; + }; +}; + +&vcc5v0_host { + enable-active-high; + gpio = <&gpio1 RK_PA1 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&vcc5v0_host_en>; +}; From patchwork Mon Mar 24 17:04:26 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Reichel X-Patchwork-Id: 14027554 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C2B51C36002 for ; Mon, 24 Mar 2025 17:15:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=zTF6br5b6lfZJboeodlNE8Jqb9gRtqnh8AFQ+6Z/3qw=; b=0qkhtLq9VF+qtY axORBF67UklmKKpZkI8E71oVmYGOtdOuRI6RnG3ngGpXxe2JAb87Edpbhu74vwd5/hp1ZvwZTgov4 UUUDbrH+i8KiLKm732sduBtc3peguyGJuxpjxkz5j+Bpx6lXjjC0tiqVoIS2MPI3LJTgaDyGrzuWL Jq0LyiYWGDqcnG5QJAKV44DCPzkjareFUSDjkQVcggBxr2eYtsOjDrzUzQjkAfBGWIDpabWqGdz+2 QCPQ2DB+5cMz1I2iRsW6jQ+zqKFEELPLEV3XqWISlZAMNsXQavfUpl/00ycRUUis5MTdpWZsXu3Ir SsBQjcET/F3f9XJfjXAQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1twlO7-00000003lbn-0GfN; Mon, 24 Mar 2025 17:14:59 +0000 Received: from bali.collaboradmins.com ([2a01:4f8:201:9162::2]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1twlDv-00000003k3q-2eNw; Mon, 24 Mar 2025 17:04:30 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1742835863; bh=YoQAz5gy7VoClsPSkqwMktmtJTGxobd9i9vU73JymF8=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=AJsXmJg7AJZhin7aRMcQRR/B4F9Ec4CHcNlCp6/SVk2A9cHaMRWA6Rf0Fpobw5V0q cJFiAHn52ew3yF9KOI4xkwv05O0XDAHEsHjun/xvJBQnQcZuo4Ms2uXuEARnxc56mI 3Gz21l86bJErYZyY/Sq9dqwv6/QIl2AzyYce2nhQMFB6BdAgDSyxbuhssdbM74XCFy Xyy7ZgJCzghPTeZaIVlPYQiQuQ7cxPb/wfibYhPt7FB3e/CarWh1lK1KIsqxnuWKUT OZv3QtxrhVeY0IzisSJH4lX7KjYPsOnqTjzl3KlZ1R/VZMtutdfLS7AxRrbSewFcbk u0gH1nJM0Fv8g== Received: from jupiter.universe (dyndsl-091-248-188-184.ewe-ip-backbone.de [91.248.188.184]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: sre) by bali.collaboradmins.com (Postfix) with ESMTPSA id 740E717E0CA7; Mon, 24 Mar 2025 18:04:23 +0100 (CET) Received: by jupiter.universe (Postfix, from userid 1000) id DB1B548003D; Mon, 24 Mar 2025 18:04:22 +0100 (CET) From: Sebastian Reichel Date: Mon, 24 Mar 2025 18:04:26 +0100 Subject: [PATCH 5/5] arm64: dts: rockchip: add USB-C support for ROCK 5B and 5B+ MIME-Version: 1.0 Message-Id: <20250324-rock5bp-for-upstream-v1-5-6217edf15b19@kernel.org> References: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> In-Reply-To: <20250324-rock5bp-for-upstream-v1-0-6217edf15b19@kernel.org> To: Heiko Stuebner Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org, Sebastian Reichel X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=6611; i=sre@kernel.org; h=from:subject:message-id; bh=YoQAz5gy7VoClsPSkqwMktmtJTGxobd9i9vU73JymF8=; b=owJ4nAFtApL9kA0DAAoB2O7X88g7+poByyZiAGfhkJa4nVZH5iVIc41MF9PcWcJSSCFZG+XGs EkysRqVS2ii04kCMwQAAQoAHRYhBO9mDQdGP4tyanlUE9ju1/PIO/qaBQJn4ZCWAAoJENju1/PI O/qa7aoP/RzLBqxZBfmAZNUe4mKUi1QIFpWIKLBRss7o/SW4rnU0aIVZB8rKZnhoWjEFcXeutm+ ftxyeYWXgIwFtBgseOI43Eox+OboHCQCMk9dwSyk2RQJ6ad1nbDKRzr1anp+44CC6MQrSCrozRP WMDBX6bV/c+NBXNZY0qcY2GR1cl+jr/rWx4Mzf7eULK4QxIT+cny/E8cCIkbO0UsoxshMW9kFEj IHVbKMOIFunFDpbcRm3MWzA026iPUjftd+ysffTAI4qGREUwHpF2JUTzzHYQD6l+i+7u18LMZtt F3llZcbVhhcwf4xf3zQzm76h78ra4l+OSupdD8dUkEe1oFQzJ+pySkhIUXs6DoKqCh+6+Lm+2gi ZZshSeaWXuqdiE1vpZrUDbWi6SOlGmHQVLb41xl0Gw5/X0VUGyAQ6b6WfPqw57L7eFRXmedTrP6 5JudlUB/YD/L96AQHnmJRPwIK9lNn8VA66+U8iNbA65YwdUDlc0l5aN2So33ZuzUcOzYUJ25uza G/moe0hvAD/VxlXaTsh68iNVLcf2tKwi/+nMVBRwnEWeU5gRD6ckJRMN0szbApQZU3kXpB3sCYq xtBrdD2ExO4aeQb0V5LEad/4YsZotXzXeW4W7ANfrCDIiE21khH7HiCtPM4X3MfuzsZA9rEvSL4 PdDnz841urI9rKpqIt3koDQ== X-Developer-Key: i=sre@kernel.org; a=openpgp; fpr=EF660D07463F8B726A795413D8EED7F3C83BFA9A X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250324_100427_826069_75EB54C0 X-CRM114-Status: GOOD ( 19.78 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org Add hardware description for the USB-C port in the Radxa ROCK 5 Model B and B+. This describes the OHCI, EHCI and XHCI USB parts, but not yet the DisplayPort AltMode, since the bindings for that are not yet upstream. The fusb302 node is marked with status "fail" on ROCK 5B, since the board is usually powered through the USB-C port. Handling of errors can result in hard resets, which removed the bus power for some time resulting in a board reset. The main problem right now is that devices are supposed to interact with the power-supply within 5 seconds after the plug event according to the USB PD specification. This is more or less impossible to achieve when the kernel is the first software communicating with the power-supply. Upstream U-Boot with fusb302 support overrides the status for the fusb302 node to "okay". That way booting a kernel with the updated DT on an old U-Boot avoids a reset loop. This workaround is not needed for the ROCK 5B+, since fusb302 support landed in U-Boot before the board support gets upstreamed. Apart from that it also has a dedicated USB-C port with a standalone chip to supply the board power. Signed-off-by: Sebastian Reichel --- .../boot/dts/rockchip/rk3588-rock-5b-plus.dts | 4 + arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi | 137 +++++++++++++++++++++ 2 files changed, 141 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b-plus.dts b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b-plus.dts index 74c7b6502e4dda4b774f43c704ebaee350703c0d..70339920fd4951dff993a5799ae5db243f07bd6e 100644 --- a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b-plus.dts +++ b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b-plus.dts @@ -105,6 +105,10 @@ vcc5v0_host_en: vcc5v0-host-en { }; }; +&usbc0 { + status = "okay"; +}; + &vcc5v0_host { enable-active-high; gpio = <&gpio1 RK_PA1 GPIO_ACTIVE_HIGH>; diff --git a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi index dccb8492f9f0632abd96c3dafc723e01491abad5..5e119f167cd8ccbd08ff2a2d4955489730ab85fb 100644 --- a/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dtsi @@ -5,6 +5,7 @@ #include #include #include +#include #include "rk3588.dtsi" / { @@ -92,6 +93,15 @@ rfkill-bt { shutdown-gpios = <&gpio3 RK_PD5 GPIO_ACTIVE_HIGH>; }; + vcc12v_dcin: regulator-vcc12v-dcin { + compatible = "regulator-fixed"; + regulator-name = "vcc12v_dcin"; + regulator-always-on; + regulator-boot-on; + regulator-min-microvolt = <12000000>; + regulator-max-microvolt = <12000000>; + }; + vcc3v3_pcie2x1l0: regulator-vcc3v3-pcie2x1l0 { compatible = "regulator-fixed"; enable-active-high; @@ -146,6 +156,19 @@ vcc5v0_sys: regulator-vcc5v0-sys { regulator-boot-on; regulator-min-microvolt = <5000000>; regulator-max-microvolt = <5000000>; + vin-supply = <&vcc12v_dcin>; + }; + + vbus5v0_typec: vbus5v0-typec { + compatible = "regulator-fixed"; + enable-active-high; + gpio = <&gpio2 RK_PB6 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&vbus5v0_typec_en>; + regulator-name = "vbus5v0_typec"; + regulator-min-microvolt = <5000000>; + regulator-max-microvolt = <5000000>; + vin-supply = <&vcc5v0_sys>; }; vcc_1v1_nldo_s3: regulator-vcc-1v1-nldo-s3 { @@ -309,6 +332,67 @@ regulator-state-mem { }; }; +&i2c4 { + pinctrl-names = "default"; + pinctrl-0 = <&i2c4m1_xfer>; + status = "okay"; + + usbc0: usb-typec@22 { + compatible = "fcs,fusb302"; + reg = <0x22>; + interrupt-parent = <&gpio3>; + interrupts = ; + pinctrl-names = "default"; + pinctrl-0 = <&usbc0_int>; + vbus-supply = <&vbus5v0_typec>; + /* + * When the board is starting to send power-delivery messages + * too late (5 seconds according to the specification), the + * power-supply reacts with a hard-reset. That removes the + * power from VBUS for some time, which resets te whole board. + */ + status = "fail"; + + usb_con: connector { + compatible = "usb-c-connector"; + label = "USB-C"; + data-role = "dual"; + power-role = "sink"; + try-power-role = "sink"; + op-sink-microwatt = <1000000>; + sink-pdos = + , + ; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + usbc0_role_sw: endpoint { + remote-endpoint = <&dwc3_0_role_switch>; + }; + }; + + port@1 { + reg = <1>; + usbc0_orien_sw: endpoint { + remote-endpoint = <&usbdp_phy0_orientation_switch>; + }; + }; + + port@2 { + reg = <2>; + dp_altmode_mux: endpoint { + remote-endpoint = <&usbdp_phy0_dp_altmode_mux>; + }; + }; + }; + }; + }; +}; + &i2c6 { status = "okay"; @@ -486,6 +570,14 @@ usb { vcc5v0_host_en: vcc5v0-host-en { rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>; }; + + usbc0_int: usbc0-int { + rockchip,pins = <3 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>; + }; + + vbus5v0_typec_en: vbus5v0-typec-en { + rockchip,pins = <2 RK_PB6 RK_FUNC_GPIO &pcfg_pull_none>; + }; }; }; @@ -871,6 +963,14 @@ &uart2 { status = "okay"; }; +&u2phy0 { + status = "okay"; +}; + +&u2phy0_otg { + status = "okay"; +}; + &u2phy1 { status = "okay"; }; @@ -898,6 +998,29 @@ &u2phy3_host { status = "okay"; }; +&usbdp_phy0 { + mode-switch; + orientation-switch; + sbu1-dc-gpios = <&gpio4 RK_PA6 GPIO_ACTIVE_HIGH>; + sbu2-dc-gpios = <&gpio4 RK_PA7 GPIO_ACTIVE_HIGH>; + status = "okay"; + + port { + #address-cells = <1>; + #size-cells = <0>; + + usbdp_phy0_orientation_switch: endpoint@0 { + reg = <0>; + remote-endpoint = <&usbc0_orien_sw>; + }; + + usbdp_phy0_dp_altmode_mux: endpoint@1 { + reg = <1>; + remote-endpoint = <&dp_altmode_mux>; + }; + }; +}; + &usbdp_phy1 { status = "okay"; }; @@ -910,6 +1033,20 @@ &usb_host0_ohci { status = "okay"; }; +&usb_host0_xhci { + usb-role-switch; + status = "okay"; + + port { + #address-cells = <1>; + #size-cells = <0>; + + dwc3_0_role_switch: endpoint { + remote-endpoint = <&usbc0_role_sw>; + }; + }; +}; + &usb_host1_ehci { status = "okay"; };