mirror of
https://github.com/Fishwaldo/build.git
synced 2025-07-23 21:39:02 +00:00
Removed default-sample-phase property for base rk322x-box device tree Enabled spdif out for rk322x-current and -dev flavours Removed reserved node in device tree, u-boot v2020.10 and OPTEE autoconfigure reserved zones automatically
2967 lines
88 KiB
Diff
2967 lines
88 KiB
Diff
From 2e3fedafa307db03549840de3f5e342f09fb5c45 Mon Sep 17 00:00:00 2001
|
||
From: =?UTF-8?q?=C5=81ukasz=20Stelmach?= <l.stelmach@samsung.com>
|
||
Date: Thu, 13 Aug 2020 22:41:23 +0200
|
||
Subject: [PATCH] dmaengine: pl330: fix instruction dump formatting
|
||
MIME-Version: 1.0
|
||
Content-Type: text/plain; charset=UTF-8
|
||
Content-Transfer-Encoding: 8bit
|
||
|
||
Instruction dump uses two printk() in a row to print one instruction. Use
|
||
KERN_CONT to prevent breaking the output in the middle.
|
||
|
||
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
|
||
Link: https://lore.kernel.org/r/20200813204123.19044-1-l.stelmach@samsung.com
|
||
Signed-off-by: Vinod Koul <vkoul@kernel.org>
|
||
(cherry picked from commit 112ec61b212200d378963cbafdd736a62e9ddaec)
|
||
---
|
||
drivers/dma/pl330.c | 2 +-
|
||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
||
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
|
||
index 5274a0704d96..106f47298f9e 100644
|
||
--- a/drivers/dma/pl330.c
|
||
+++ b/drivers/dma/pl330.c
|
||
@@ -255,7 +255,7 @@ enum pl330_byteswap {
|
||
static unsigned cmd_line;
|
||
#define PL330_DBGCMD_DUMP(off, x...) do { \
|
||
printk("%x:", cmd_line); \
|
||
- printk(x); \
|
||
+ printk(KERN_CONT x); \
|
||
cmd_line += off; \
|
||
} while (0)
|
||
#define PL330_DBGMC_START(addr) (cmd_line = addr)
|
||
|
||
From 3bb4e2c068270e9c910e3a3b7bec8b0225e2d442 Mon Sep 17 00:00:00 2001
|
||
From: Jagan Teki <jagan@amarulasolutions.com>
|
||
Date: Wed, 19 Aug 2020 00:15:05 +0530
|
||
Subject: [PATCH] arm64: dts: rockchip: Fix power routing to support POE on
|
||
rk3399-roc-pc
|
||
|
||
When POE used, the current power routing is failing to power-up
|
||
the PMIC regulators which cause Linux boot hangs.
|
||
|
||
This patch is trying to update the power routing in order to
|
||
support Type C0 and POE powering methods.
|
||
|
||
As per the schematics, sys_12v is a common output power regulator
|
||
when type c and POE power being used. sys_12v is supplied by dc_12v
|
||
which is supplied from MP8859 in type c0 power routing and sys_12v
|
||
is supplied by MP8009 PoE PD in POE power supply routing.
|
||
|
||
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
|
||
Tested-by: Suniel Mahesh <sunil@amarulasolutions.com>
|
||
Link: https://lore.kernel.org/r/20200818184505.30064-1-jagan@amarulasolutions.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit bd77d0ad7a698f5e04edf02328d11e808a71d87c)
|
||
---
|
||
.../boot/dts/rockchip/rk3399-roc-pc-mezzanine.dts | 18 ++++++++++++++++--
|
||
arch/arm64/boot/dts/rockchip/rk3399-roc-pc.dtsi | 12 ++++++++++--
|
||
2 files changed, 26 insertions(+), 4 deletions(-)
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-roc-pc-mezzanine.dts b/arch/arm64/boot/dts/rockchip/rk3399-roc-pc-mezzanine.dts
|
||
index 2acb3d500fb9..754627d97144 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3399-roc-pc-mezzanine.dts
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-roc-pc-mezzanine.dts
|
||
@@ -11,6 +11,16 @@
|
||
model = "Firefly ROC-RK3399-PC Mezzanine Board";
|
||
compatible = "firefly,roc-rk3399-pc-mezzanine", "rockchip,rk3399";
|
||
|
||
+ /* MP8009 PoE PD */
|
||
+ poe_12v: poe-12v {
|
||
+ compatible = "regulator-fixed";
|
||
+ regulator-name = "poe_12v";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <12000000>;
|
||
+ regulator-max-microvolt = <12000000>;
|
||
+ };
|
||
+
|
||
vcc3v3_ngff: vcc3v3-ngff {
|
||
compatible = "regulator-fixed";
|
||
regulator-name = "vcc3v3_ngff";
|
||
@@ -22,7 +32,7 @@
|
||
regulator-boot-on;
|
||
regulator-min-microvolt = <3300000>;
|
||
regulator-max-microvolt = <3300000>;
|
||
- vin-supply = <&dc_12v>;
|
||
+ vin-supply = <&sys_12v>;
|
||
};
|
||
|
||
vcc3v3_pcie: vcc3v3-pcie {
|
||
@@ -34,10 +44,14 @@
|
||
pinctrl-0 = <&vcc3v3_pcie_en>;
|
||
regulator-min-microvolt = <3300000>;
|
||
regulator-max-microvolt = <3300000>;
|
||
- vin-supply = <&dc_12v>;
|
||
+ vin-supply = <&sys_12v>;
|
||
};
|
||
};
|
||
|
||
+&sys_12v {
|
||
+ vin-supply = <&poe_12v>;
|
||
+};
|
||
+
|
||
&pcie_phy {
|
||
status = "okay";
|
||
};
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-roc-pc.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-roc-pc.dtsi
|
||
index b85ec31cd283..e7a459fa4322 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3399-roc-pc.dtsi
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-roc-pc.dtsi
|
||
@@ -110,6 +110,14 @@
|
||
regulator-max-microvolt = <5000000>;
|
||
};
|
||
|
||
+ sys_12v: sys-12v {
|
||
+ compatible = "regulator-fixed";
|
||
+ regulator-name = "sys_12v";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ vin-supply = <&dc_12v>;
|
||
+ };
|
||
+
|
||
/* switched by pmic_sleep */
|
||
vcc1v8_s3: vcca1v8_s3: vcc1v8-s3 {
|
||
compatible = "regulator-fixed";
|
||
@@ -141,7 +149,7 @@
|
||
regulator-boot-on;
|
||
regulator-min-microvolt = <3300000>;
|
||
regulator-max-microvolt = <3300000>;
|
||
- vin-supply = <&dc_12v>;
|
||
+ vin-supply = <&sys_12v>;
|
||
};
|
||
|
||
vcca_0v9: vcca-0v9 {
|
||
@@ -186,7 +194,7 @@
|
||
regulator-boot-on;
|
||
regulator-min-microvolt = <5000000>;
|
||
regulator-max-microvolt = <5000000>;
|
||
- vin-supply = <&dc_12v>;
|
||
+ vin-supply = <&sys_12v>;
|
||
};
|
||
|
||
vdd_log: vdd-log {
|
||
|
||
From 9d3c764ef494a805ed623e81e7485d5fc3f57a97 Mon Sep 17 00:00:00 2001
|
||
From: Johan Jonker <jbx6244@gmail.com>
|
||
Date: Tue, 18 Aug 2020 16:37:27 +0200
|
||
Subject: [PATCH] arm64: dts: rockchip: change spdif fallback compatible on
|
||
rk3308
|
||
|
||
A test with the command below shows that the compatible string
|
||
|
||
"rockchip,rk3308-spdif", "rockchip,rk3328-spdif"
|
||
|
||
is already in use, but is not added to a document.
|
||
The current fallback string "rockchip,rk3328-spdif" points to a data
|
||
set enum RK_SPDIF_RK3366 in rockchip_spdif.c that is not used both
|
||
in the mainline as in the manufacturer kernel.
|
||
(Of the enum only RK_SPDIF_RK3288 is used.)
|
||
So if the properties don't change we might as well use the first SoC
|
||
in line as fallback string and add the description for rk3308 as:
|
||
|
||
"rockchip,rk3308-spdif", "rockchip,rk3066-spdif"
|
||
|
||
make ARCH=arm64 dtbs_check
|
||
DT_SCHEMA_FILES=Documentation/devicetree/bindings/sound/rockchip-spdif.yaml
|
||
|
||
Signed-off-by: Johan Jonker <jbx6244@gmail.com>
|
||
Link: https://lore.kernel.org/r/20200818143727.5882-2-jbx6244@gmail.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit bc1f9bff0629a15e3de1ef106ac03cba930227dd)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/rk3308.dtsi | 2 +-
|
||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3308.dtsi b/arch/arm64/boot/dts/rockchip/rk3308.dtsi
|
||
index e8b754d415d8..2560b98771ca 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3308.dtsi
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3308.dtsi
|
||
@@ -574,7 +574,7 @@
|
||
};
|
||
|
||
spdif_tx: spdif-tx@ff3a0000 {
|
||
- compatible = "rockchip,rk3308-spdif", "rockchip,rk3328-spdif";
|
||
+ compatible = "rockchip,rk3308-spdif", "rockchip,rk3066-spdif";
|
||
reg = <0x0 0xff3a0000 0x0 0x1000>;
|
||
interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>;
|
||
clocks = <&cru SCLK_SPDIF_TX>, <&cru HCLK_SPDIFTX>;
|
||
|
||
From a87e7be5beb9646557e70f0b42c558d418ba16ce Mon Sep 17 00:00:00 2001
|
||
From: Jagan Teki <jagan@amarulasolutions.com>
|
||
Date: Fri, 7 Aug 2020 15:18:23 +0530
|
||
Subject: [PATCH] dt-bindings: arm: rockchip: Update ROCKPi 4 binding
|
||
|
||
ROCKPi 4 has 3 variants of hardware platforms called
|
||
ROCKPi 4A, 4B, and 4C.
|
||
|
||
- ROCKPi 4A has no Wif/BT.
|
||
- ROCKPi 4B has AP6256 Wifi/BT, PoE.
|
||
- ROCKPi 4C has AP6256 Wifi/BT, PoE, miniDP, USB Host enabled
|
||
GPIO pin change compared to 4B, 4C
|
||
|
||
So, update the existing ROCKPi 4 binding to support
|
||
ROCKPi 4A/B/C hardware platforms.
|
||
|
||
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
|
||
Acked-by: Rob Herring <robh@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200807094826.12019-1-jagan@amarulasolutions.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 75a0a65a301f557bf0306d7983f8cf31ac91de56)
|
||
---
|
||
Documentation/devicetree/bindings/arm/rockchip.yaml | 6 +++++-
|
||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||
|
||
diff --git a/Documentation/devicetree/bindings/arm/rockchip.yaml b/Documentation/devicetree/bindings/arm/rockchip.yaml
|
||
index db2e35796795..7025d00c06cc 100644
|
||
--- a/Documentation/devicetree/bindings/arm/rockchip.yaml
|
||
+++ b/Documentation/devicetree/bindings/arm/rockchip.yaml
|
||
@@ -430,8 +430,12 @@ properties:
|
||
- const: radxa,rock
|
||
- const: rockchip,rk3188
|
||
|
||
- - description: Radxa ROCK Pi 4
|
||
+ - description: Radxa ROCK Pi 4A/B/C
|
||
items:
|
||
+ - enum:
|
||
+ - radxa,rockpi4a
|
||
+ - radxa,rockpi4b
|
||
+ - radxa,rockpi4c
|
||
- const: radxa,rockpi4
|
||
- const: rockchip,rk3399
|
||
|
||
|
||
From bb10faf3729a3982ba5a85b39b416116e315f642 Mon Sep 17 00:00:00 2001
|
||
From: Jagan Teki <jagan@amarulasolutions.com>
|
||
Date: Fri, 7 Aug 2020 15:18:24 +0530
|
||
Subject: [PATCH] arm64: dts: rockchip: Mark rock-pi-4 as rock-pi-4a dts
|
||
|
||
ROCKPi 4 has 3 variants of hardware platforms called
|
||
RockPI 4A, 4B, and 4C.
|
||
|
||
- ROCKPi 4A has no Wif/BT.
|
||
- ROCKPi 4B has AP6256 Wifi/BT, PoE.
|
||
- ROCKPi 4C has AP6256 Wifi/BT, PoE, miniDP, USB Host enabled
|
||
GPIO pin change compared to 4B, 4C
|
||
|
||
So move common nodes, properties into dtsi file and include
|
||
on respective variant dts files.
|
||
|
||
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
|
||
Link: https://lore.kernel.org/r/20200807094826.12019-2-jagan@amarulasolutions.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit b5edb04673700125bfd1d13e6c14747b1ecba522)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/Makefile | 2 +-
|
||
.../{rk3399-rock-pi-4.dts => rk3399-rock-pi-4.dtsi} | 3 ---
|
||
arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4a.dts | 13 +++++++++++++
|
||
3 files changed, 14 insertions(+), 4 deletions(-)
|
||
rename arch/arm64/boot/dts/rockchip/{rk3399-rock-pi-4.dts => rk3399-rock-pi-4.dtsi} (99%)
|
||
create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4a.dts
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile
|
||
index b87b1f773083..42f9e1861461 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/Makefile
|
||
+++ b/arch/arm64/boot/dts/rockchip/Makefile
|
||
@@ -33,7 +33,7 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-pinebook-pro.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-puma-haikou.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-roc-pc.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-roc-pc-mezzanine.dtb
|
||
-dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4.dtb
|
||
+dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4a.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock960.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rockpro64-v2.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rockpro64.dtb
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dts b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi
|
||
similarity index 99%
|
||
rename from arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dts
|
||
rename to arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi
|
||
index 60f98a3e19d8..e163f438f836 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dts
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi
|
||
@@ -11,9 +11,6 @@
|
||
#include "rk3399-opp.dtsi"
|
||
|
||
/ {
|
||
- model = "Radxa ROCK Pi 4";
|
||
- compatible = "radxa,rockpi4", "rockchip,rk3399";
|
||
-
|
||
chosen {
|
||
stdout-path = "serial2:1500000n8";
|
||
};
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4a.dts b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4a.dts
|
||
new file mode 100644
|
||
index 000000000000..89f2af5e111d
|
||
--- /dev/null
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4a.dts
|
||
@@ -0,0 +1,13 @@
|
||
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||
+/*
|
||
+ * Copyright (c) 2019 Akash Gajjar <Akash_Gajjar@mentor.com>
|
||
+ * Copyright (c) 2019 Pragnesh Patel <Pragnesh_Patel@mentor.com>
|
||
+ */
|
||
+
|
||
+/dts-v1/;
|
||
+#include "rk3399-rock-pi-4.dtsi"
|
||
+
|
||
+/ {
|
||
+ model = "Radxa ROCK Pi 4A";
|
||
+ compatible = "radxa,rockpi4a", "radxa,rockpi4", "rockchip,rk3399";
|
||
+};
|
||
|
||
From 54123d61cf3af2ae6b27e264a40c058eba9716c2 Mon Sep 17 00:00:00 2001
|
||
From: Jagan Teki <jagan@amarulasolutions.com>
|
||
Date: Fri, 7 Aug 2020 15:18:25 +0530
|
||
Subject: [PATCH] arm64: dts: rockchip: Add Radxa ROCK Pi 4B support
|
||
|
||
RockPI 4B has AP6256 Wifi/BT, so enable them in 4B dts
|
||
instead of enable in common dtsi.
|
||
|
||
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
|
||
Link: https://lore.kernel.org/r/20200807094826.12019-3-jagan@amarulasolutions.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit c1075b7fcca81f58ebc5d723f07b23f84ae93daa)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/Makefile | 1 +
|
||
arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi | 23 ------------
|
||
arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4b.dts | 42 ++++++++++++++++++++++
|
||
3 files changed, 43 insertions(+), 23 deletions(-)
|
||
create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4b.dts
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile
|
||
index 42f9e1861461..8832d05c2571 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/Makefile
|
||
+++ b/arch/arm64/boot/dts/rockchip/Makefile
|
||
@@ -34,6 +34,7 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-puma-haikou.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-roc-pc.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-roc-pc-mezzanine.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4a.dtb
|
||
+dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4b.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock960.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rockpro64-v2.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rockpro64.dtb
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi
|
||
index e163f438f836..678a336010bf 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4.dtsi
|
||
@@ -584,17 +584,6 @@
|
||
pinctrl-names = "default";
|
||
pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>;
|
||
sd-uhs-sdr104;
|
||
- status = "okay";
|
||
-
|
||
- brcmf: wifi@1 {
|
||
- compatible = "brcm,bcm4329-fmac";
|
||
- reg = <1>;
|
||
- interrupt-parent = <&gpio0>;
|
||
- interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>;
|
||
- interrupt-names = "host-wake";
|
||
- pinctrl-names = "default";
|
||
- pinctrl-0 = <&wifi_host_wake_l>;
|
||
- };
|
||
};
|
||
|
||
&sdmmc {
|
||
@@ -663,18 +652,6 @@
|
||
&uart0 {
|
||
pinctrl-names = "default";
|
||
pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
|
||
- status = "okay";
|
||
-
|
||
- bluetooth {
|
||
- compatible = "brcm,bcm43438-bt";
|
||
- clocks = <&rk808 1>;
|
||
- clock-names = "ext_clock";
|
||
- device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
|
||
- host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
|
||
- shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
|
||
- pinctrl-names = "default";
|
||
- pinctrl-0 = <&bt_host_wake_l &bt_wake_l &bt_enable_h>;
|
||
- };
|
||
};
|
||
|
||
&uart2 {
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4b.dts b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4b.dts
|
||
new file mode 100644
|
||
index 000000000000..f0055ce2fda0
|
||
--- /dev/null
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4b.dts
|
||
@@ -0,0 +1,42 @@
|
||
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||
+/*
|
||
+ * Copyright (c) 2019 Akash Gajjar <Akash_Gajjar@mentor.com>
|
||
+ * Copyright (c) 2019 Pragnesh Patel <Pragnesh_Patel@mentor.com>
|
||
+ */
|
||
+
|
||
+/dts-v1/;
|
||
+#include "rk3399-rock-pi-4.dtsi"
|
||
+
|
||
+/ {
|
||
+ model = "Radxa ROCK Pi 4B";
|
||
+ compatible = "radxa,rockpi4b", "radxa,rockpi4", "rockchip,rk3399";
|
||
+};
|
||
+
|
||
+&sdio0 {
|
||
+ status = "okay";
|
||
+
|
||
+ brcmf: wifi@1 {
|
||
+ compatible = "brcm,bcm4329-fmac";
|
||
+ reg = <1>;
|
||
+ interrupt-parent = <&gpio0>;
|
||
+ interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>;
|
||
+ interrupt-names = "host-wake";
|
||
+ pinctrl-names = "default";
|
||
+ pinctrl-0 = <&wifi_host_wake_l>;
|
||
+ };
|
||
+};
|
||
+
|
||
+&uart0 {
|
||
+ status = "okay";
|
||
+
|
||
+ bluetooth {
|
||
+ compatible = "brcm,bcm43438-bt";
|
||
+ clocks = <&rk808 1>;
|
||
+ clock-names = "ext_clock";
|
||
+ device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
|
||
+ host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
|
||
+ shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
|
||
+ pinctrl-names = "default";
|
||
+ pinctrl-0 = <&bt_host_wake_l &bt_wake_l &bt_enable_h>;
|
||
+ };
|
||
+};
|
||
|
||
From a28e4816e96a5b6f565fbe71e8d333e541a54227 Mon Sep 17 00:00:00 2001
|
||
From: Jagan Teki <jagan@amarulasolutions.com>
|
||
Date: Fri, 7 Aug 2020 15:18:26 +0530
|
||
Subject: [PATCH] arm64: dts: rockchip: Add Radxa ROCK Pi 4C support
|
||
|
||
Rock PI 4C has AP6256 Wifi/BT, PoE, miniDP, USB Host enabled
|
||
GPIO pin change compared to 4B, 4C.
|
||
|
||
So, add or enable difference nodes/properties in 4C dts
|
||
by including common dtsi.
|
||
|
||
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
|
||
Link: https://lore.kernel.org/r/20200807094826.12019-4-jagan@amarulasolutions.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 93e0e8ce5fdf549f1715dad00bfbb21b2f69ba8e)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/Makefile | 1 +
|
||
arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4c.dts | 51 ++++++++++++++++++++++
|
||
2 files changed, 52 insertions(+)
|
||
create mode 100644 arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4c.dts
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile
|
||
index 8832d05c2571..02cdb3c4a6c1 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/Makefile
|
||
+++ b/arch/arm64/boot/dts/rockchip/Makefile
|
||
@@ -35,6 +35,7 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-roc-pc.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-roc-pc-mezzanine.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4a.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4b.dtb
|
||
+dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4c.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock960.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rockpro64-v2.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rockpro64.dtb
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4c.dts b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4c.dts
|
||
new file mode 100644
|
||
index 000000000000..4c7ebb1c5d2d
|
||
--- /dev/null
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-rock-pi-4c.dts
|
||
@@ -0,0 +1,51 @@
|
||
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||
+/*
|
||
+ * Copyright (c) 2019 Fuzhou Rockchip Electronics Co., Ltd
|
||
+ * Copyright (c) 2019 Radxa Limited
|
||
+ * Copyright (c) 2019 Amarula Solutions(India)
|
||
+ */
|
||
+
|
||
+/dts-v1/;
|
||
+#include "rk3399-rock-pi-4.dtsi"
|
||
+
|
||
+/ {
|
||
+ model = "Radxa ROCK Pi 4C";
|
||
+ compatible = "radxa,rockpi4c", "radxa,rockpi4", "rockchip,rk3399";
|
||
+};
|
||
+
|
||
+&sdio0 {
|
||
+ status = "okay";
|
||
+
|
||
+ brcmf: wifi@1 {
|
||
+ compatible = "brcm,bcm4329-fmac";
|
||
+ reg = <1>;
|
||
+ interrupt-parent = <&gpio0>;
|
||
+ interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>;
|
||
+ interrupt-names = "host-wake";
|
||
+ pinctrl-names = "default";
|
||
+ pinctrl-0 = <&wifi_host_wake_l>;
|
||
+ };
|
||
+};
|
||
+
|
||
+&uart0 {
|
||
+ status = "okay";
|
||
+
|
||
+ bluetooth {
|
||
+ compatible = "brcm,bcm43438-bt";
|
||
+ clocks = <&rk808 1>;
|
||
+ clock-names = "ext_clock";
|
||
+ device-wakeup-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>;
|
||
+ host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
|
||
+ shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
|
||
+ pinctrl-names = "default";
|
||
+ pinctrl-0 = <&bt_host_wake_l &bt_wake_l &bt_enable_h>;
|
||
+ };
|
||
+};
|
||
+
|
||
+&vcc5v0_host {
|
||
+ gpio = <&gpio3 RK_PD6 GPIO_ACTIVE_HIGH>;
|
||
+};
|
||
+
|
||
+&vcc5v0_host_en {
|
||
+ rockchip,pins = <3 RK_PD6 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+};
|
||
|
||
From c89d84dcef9b307af733aaaedbf1614b4b266341 Mon Sep 17 00:00:00 2001
|
||
From: Johan Jonker <jbx6244@gmail.com>
|
||
Date: Sat, 8 Aug 2020 18:06:17 +0200
|
||
Subject: [PATCH] dt-bindings: arm: rockchip: add Zkmagic A95X Z2 description
|
||
|
||
Add Zkmagic A95X Z2 description for a board with rk3318 processor.
|
||
|
||
Signed-off-by: Johan Jonker <jbx6244@gmail.com>
|
||
Acked-by: Rob Herring <robh@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200808160618.15445-3-jbx6244@gmail.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 0dc8c62c92d4df35a001b613ebe10f95e4ebf776)
|
||
---
|
||
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 7025d00c06cc..251c3ca22e1b 100644
|
||
--- a/Documentation/devicetree/bindings/arm/rockchip.yaml
|
||
+++ b/Documentation/devicetree/bindings/arm/rockchip.yaml
|
||
@@ -559,4 +559,9 @@ properties:
|
||
items:
|
||
- const: tronsmart,orion-r68-meta
|
||
- const: rockchip,rk3368
|
||
+
|
||
+ - description: Zkmagic A95X Z2
|
||
+ items:
|
||
+ - const: zkmagic,a95x-z2
|
||
+ - const: rockchip,rk3318
|
||
...
|
||
|
||
From a4d955617bdc633aa291642c54134dd30d0c1187 Mon Sep 17 00:00:00 2001
|
||
From: Johan Jonker <jbx6244@gmail.com>
|
||
Date: Sat, 8 Aug 2020 18:06:18 +0200
|
||
Subject: [PATCH] arm64: dts: rockchip: add rk3318 A95X Z2 board
|
||
|
||
The rk3318 A95X Z2 boards are sold as TV box.
|
||
No further documentation is given, but from the dts files
|
||
extracted it seems that the rk3318 processor is simulair
|
||
to the rk3328. This dts file contains only the basic nodes
|
||
that have support in the mainline kernel.
|
||
|
||
Features:
|
||
|
||
CPU: RK3318 Quad-Core Cortex-A53
|
||
GPU: Mali-450
|
||
RAM: 2/4GB DDR3
|
||
ROM: EMMC 16/32/64GB
|
||
HDMI: HDMI 2.0a for 4k@60Hz
|
||
Ethernet: 10/100M standard RJ-45
|
||
WiFi: 2.4G+5G WIFI, 802.11 b/g/n
|
||
Bluetooth: 4.0
|
||
1 x USB 3.0
|
||
1 x USB 2.0
|
||
1 x Micro SD card slot
|
||
1 x SPDIF
|
||
1 x AV
|
||
1 x DC IN
|
||
|
||
Signed-off-by: Johan Jonker <jbx6244@gmail.com>
|
||
Link: https://lore.kernel.org/r/20200808160618.15445-4-jbx6244@gmail.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 964ed0807b5f7b42b8a6ad48531ae9312e19599d)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/Makefile | 1 +
|
||
arch/arm64/boot/dts/rockchip/rk3318-a95x-z2.dts | 374 ++++++++++++++++++++++++
|
||
2 files changed, 375 insertions(+)
|
||
create mode 100644 arch/arm64/boot/dts/rockchip/rk3318-a95x-z2.dts
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile
|
||
index 02cdb3c4a6c1..d53efdf4cb5a 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) += rk3318-a95x-z2.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3326-odroid-go2.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-a1.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-evb.dtb
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3318-a95x-z2.dts b/arch/arm64/boot/dts/rockchip/rk3318-a95x-z2.dts
|
||
new file mode 100644
|
||
index 000000000000..30c73ef25370
|
||
--- /dev/null
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3318-a95x-z2.dts
|
||
@@ -0,0 +1,374 @@
|
||
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||
+
|
||
+/dts-v1/;
|
||
+#include <dt-bindings/input/input.h>
|
||
+#include "rk3328.dtsi"
|
||
+
|
||
+/ {
|
||
+ model = "A95X Z2";
|
||
+ compatible = "zkmagic,a95x-z2", "rockchip,rk3318";
|
||
+
|
||
+ chosen {
|
||
+ stdout-path = "serial2:1500000n8";
|
||
+ };
|
||
+
|
||
+ adc-keys {
|
||
+ compatible = "adc-keys";
|
||
+ io-channels = <&saradc 0>;
|
||
+ io-channel-names = "buttons";
|
||
+ keyup-threshold-microvolt = <1800000>;
|
||
+ poll-interval = <100>;
|
||
+
|
||
+ recovery {
|
||
+ label = "recovery";
|
||
+ linux,code = <KEY_VENDOR>;
|
||
+ press-threshold-microvolt = <17000>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ ir-receiver {
|
||
+ compatible = "gpio-ir-receiver";
|
||
+ gpios = <&gpio2 RK_PA2 GPIO_ACTIVE_LOW>;
|
||
+ pinctrl-0 = <&ir_int>;
|
||
+ pinctrl-names = "default";
|
||
+ };
|
||
+
|
||
+ leds {
|
||
+ compatible = "gpio-leds";
|
||
+ pinctrl-0 = <&cyx_led_pin>;
|
||
+ pinctrl-names = "default";
|
||
+
|
||
+ cyx_led: led-0 {
|
||
+ default-state = "on";
|
||
+ gpios = <&gpio2 RK_PC7 GPIO_ACTIVE_LOW>;
|
||
+ label = "CYX_LED";
|
||
+ };
|
||
+ };
|
||
+
|
||
+ sdio_pwrseq: sdio-pwrseq {
|
||
+ compatible = "mmc-pwrseq-simple";
|
||
+ pinctrl-0 = <&wifi_enable_h>;
|
||
+ pinctrl-names = "default";
|
||
+ reset-gpios = <&gpio1 RK_PC2 GPIO_ACTIVE_LOW>;
|
||
+ };
|
||
+
|
||
+ spdif-sound {
|
||
+ compatible = "simple-audio-card";
|
||
+ simple-audio-card,name = "SPDIF";
|
||
+
|
||
+ simple-audio-card,cpu {
|
||
+ sound-dai = <&spdif>;
|
||
+ };
|
||
+
|
||
+ simple-audio-card,codec {
|
||
+ sound-dai = <&spdif_out>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ spdif_out: spdif-out {
|
||
+ compatible = "linux,spdif-dit";
|
||
+ #sound-dai-cells = <0>;
|
||
+ };
|
||
+
|
||
+ /* Power tree */
|
||
+ vccio_1v8: vccio-1v8-regulator {
|
||
+ compatible = "regulator-fixed";
|
||
+ regulator-name = "vccio_1v8";
|
||
+ regulator-min-microvolt = <1800000>;
|
||
+ regulator-max-microvolt = <1800000>;
|
||
+ regulator-always-on;
|
||
+ };
|
||
+
|
||
+ vccio_3v3: vccio-3v3-regulator {
|
||
+ compatible = "regulator-fixed";
|
||
+ regulator-name = "vccio_3v3";
|
||
+ regulator-min-microvolt = <3300000>;
|
||
+ regulator-max-microvolt = <3300000>;
|
||
+ regulator-always-on;
|
||
+ };
|
||
+
|
||
+ vcc_otg_vbus: otg-vbus-regulator {
|
||
+ compatible = "regulator-fixed";
|
||
+ gpio = <&gpio0 RK_PA2 GPIO_ACTIVE_HIGH>;
|
||
+ pinctrl-0 = <&otg_vbus_drv>;
|
||
+ pinctrl-names = "default";
|
||
+ regulator-name = "vcc_otg_vbus";
|
||
+ regulator-min-microvolt = <5000000>;
|
||
+ regulator-max-microvolt = <5000000>;
|
||
+ enable-active-high;
|
||
+ };
|
||
+
|
||
+ vcc_sd: sdmmc-regulator {
|
||
+ compatible = "regulator-fixed";
|
||
+ gpio = <&gpio0 RK_PD6 GPIO_ACTIVE_LOW>;
|
||
+ pinctrl-0 = <&sdmmc0m1_pin>;
|
||
+ pinctrl-names = "default";
|
||
+ regulator-name = "vcc_sd";
|
||
+ regulator-min-microvolt = <3300000>;
|
||
+ regulator-max-microvolt = <3300000>;
|
||
+ vin-supply = <&vccio_3v3>;
|
||
+ };
|
||
+
|
||
+ vdd_arm: vdd-arm {
|
||
+ compatible = "pwm-regulator";
|
||
+ pwms = <&pwm0 0 5000 1>;
|
||
+ regulator-name = "vdd_arm";
|
||
+ regulator-min-microvolt = <950000>;
|
||
+ regulator-max-microvolt = <1400000>;
|
||
+ regulator-settling-time-up-us = <250>;
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ };
|
||
+
|
||
+ vdd_log: vdd-log {
|
||
+ compatible = "pwm-regulator";
|
||
+ pwms = <&pwm1 0 5000 1>;
|
||
+ regulator-name = "vdd_log";
|
||
+ regulator-min-microvolt = <900000>;
|
||
+ regulator-max-microvolt = <1300000>;
|
||
+ regulator-settling-time-up-us = <250>;
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ };
|
||
+};
|
||
+
|
||
+&analog_sound {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&codec {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&cpu0 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu2 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu3 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu0_opp_table {
|
||
+ opp-1200000000 {
|
||
+ status = "disabled";
|
||
+ };
|
||
+
|
||
+ opp-1296000000 {
|
||
+ status = "disabled";
|
||
+ };
|
||
+};
|
||
+
|
||
+&emmc {
|
||
+ bus-width = <8>;
|
||
+ cap-mmc-highspeed;
|
||
+ non-removable;
|
||
+ pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_bus8>;
|
||
+ pinctrl-names = "default";
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&gmac2phy {
|
||
+ assigned-clock-parents = <&cru SCLK_MAC2PHY_SRC>;
|
||
+ assigned-clock-rate = <50000000>;
|
||
+ assigned-clocks = <&cru SCLK_MAC2PHY>;
|
||
+ clock_in_out = "output";
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&gpu {
|
||
+ mali-supply = <&vdd_log>;
|
||
+};
|
||
+
|
||
+&hdmi {
|
||
+ ddc-i2c-scl-high-time-ns = <9625>;
|
||
+ ddc-i2c-scl-low-time-ns = <10000>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&hdmiphy {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&hdmi_sound {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&i2s0 {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&i2s1 {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&io_domains {
|
||
+ pmuio-supply = <&vccio_3v3>;
|
||
+ vccio1-supply = <&vccio_3v3>;
|
||
+ vccio2-supply = <&vccio_1v8>;
|
||
+ vccio3-supply = <&vccio_3v3>;
|
||
+ vccio4-supply = <&vccio_1v8>;
|
||
+ vccio5-supply = <&vccio_3v3>;
|
||
+ vccio6-supply = <&vccio_3v3>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&pinctrl {
|
||
+ ir {
|
||
+ ir_int: ir-int {
|
||
+ rockchip,pins = <2 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ leds {
|
||
+ cyx_led_pin: cyx-led-pin {
|
||
+ rockchip,pins = <2 RK_PC7 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ pwm0 {
|
||
+ pwm0_pin_pull_up: pwm0-pin-pull-up {
|
||
+ rockchip,pins = <2 RK_PA4 1 &pcfg_pull_up>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ pwm1 {
|
||
+ pwm1_pin_pull_up: pwm1-pin-pull-up {
|
||
+ rockchip,pins = <2 RK_PA5 1 &pcfg_pull_up>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ sdio-pwrseq {
|
||
+ wifi_enable_h: wifi-enable-h {
|
||
+ rockchip,pins = <1 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ sdmmc1 {
|
||
+ clk_32k_out: clk-32k-out {
|
||
+ rockchip,pins = <1 RK_PD4 1 &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ usb {
|
||
+ host_vbus_drv: host-vbus-drv {
|
||
+ rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+
|
||
+ otg_vbus_drv: otg-vbus-drv {
|
||
+ rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+};
|
||
+
|
||
+&pwm0 {
|
||
+ pinctrl-0 = <&pwm0_pin_pull_up>;
|
||
+ pinctrl-names = "active";
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&pwm1 {
|
||
+ pinctrl-0 = <&pwm1_pin_pull_up>;
|
||
+ pinctrl-names = "active";
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&saradc {
|
||
+ vref-supply = <&vccio_1v8>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&sdio {
|
||
+ bus-width = <4>;
|
||
+ cap-sd-highspeed;
|
||
+ cap-sdio-irq;
|
||
+ keep-power-in-suspend;
|
||
+ max-frequency = <125000000>;
|
||
+ mmc-pwrseq = <&sdio_pwrseq>;
|
||
+ non-removable;
|
||
+ pinctrl-0 = <&sdmmc1_bus4 &sdmmc1_cmd &sdmmc1_clk &clk_32k_out>;
|
||
+ pinctrl-names = "default";
|
||
+ sd-uhs-sdr104;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&sdmmc {
|
||
+ bus-width = <4>;
|
||
+ cap-sd-highspeed;
|
||
+ pinctrl-0 = <&sdmmc0_clk &sdmmc0_cmd &sdmmc0_dectn &sdmmc0_bus4>;
|
||
+ pinctrl-names = "default";
|
||
+ vmmc-supply = <&vcc_sd>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&spdif {
|
||
+ pinctrl-0 = <&spdifm0_tx>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&soc_crit {
|
||
+ temperature = <115000>; /* millicelsius */
|
||
+};
|
||
+
|
||
+&target {
|
||
+ temperature = <105000>; /* millicelsius */
|
||
+};
|
||
+
|
||
+&threshold {
|
||
+ temperature = <90000>; /* millicelsius */
|
||
+};
|
||
+
|
||
+&tsadc {
|
||
+ rockchip,hw-tshut-temp = <120000>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&u2phy {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&u2phy_host {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&u2phy_otg {
|
||
+ phy-supply = <&vcc_otg_vbus>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&uart0 {
|
||
+ pinctrl-0 = <&uart0_xfer &uart0_cts>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&uart2 {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&usb20_otg {
|
||
+ dr_mode = "host";
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&usb_host0_ehci {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&usb_host0_ohci {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&vop {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&vop_mmu {
|
||
+ status = "okay";
|
||
+};
|
||
|
||
From 739bf33933935649816771290e0f7e87ed9dcd44 Mon Sep 17 00:00:00 2001
|
||
From: Johan Jonker <jbx6244@gmail.com>
|
||
Date: Thu, 13 Aug 2020 20:17:11 +0200
|
||
Subject: [PATCH] arm64: dts: rockchip: fix cpu-supply for rk3328-evb
|
||
|
||
The property cpu-supply should be added to each cpu separately,
|
||
so fix that for rk3328-evb.
|
||
|
||
Signed-off-by: Johan Jonker <jbx6244@gmail.com>
|
||
Link: https://lore.kernel.org/r/20200813181711.15906-1-jbx6244@gmail.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 4be8df7b3bcd46a75f7e297ef310234975a437d8)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/rk3328-evb.dts | 12 ++++++++++++
|
||
1 file changed, 12 insertions(+)
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3328-evb.dts b/arch/arm64/boot/dts/rockchip/rk3328-evb.dts
|
||
index 1969dab84138..a48767931af6 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3328-evb.dts
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3328-evb.dts
|
||
@@ -70,6 +70,18 @@
|
||
cpu-supply = <&vdd_arm>;
|
||
};
|
||
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu2 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu3 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
&emmc {
|
||
bus-width = <8>;
|
||
cap-mmc-highspeed;
|
||
|
||
From 4a30b39b5d073898b065e24af70688d0572bbacb Mon Sep 17 00:00:00 2001
|
||
From: Johan Jonker <jbx6244@gmail.com>
|
||
Date: Thu, 13 Aug 2020 20:02:41 +0200
|
||
Subject: [PATCH] ARM: dts: rockchip: update cpu supplies on rk3288
|
||
|
||
The use of cpu0-supply for cpu0 alone is deprecated,
|
||
so add cpu-supply to each cpu separately and
|
||
update all existing rk3288 boards that use this property.
|
||
|
||
Signed-off-by: Johan Jonker <jbx6244@gmail.com>
|
||
Link: https://lore.kernel.org/r/20200813180241.14660-1-jbx6244@gmail.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit b282ae0511cdb6f17cb5052de20288245a8ecd00)
|
||
---
|
||
arch/arm/boot/dts/rk3288-miqi.dts | 14 +++++++++++++-
|
||
arch/arm/boot/dts/rk3288-popmetal.dts | 14 +++++++++++++-
|
||
arch/arm/boot/dts/rk3288-r89.dts | 14 +++++++++++++-
|
||
arch/arm/boot/dts/rk3288-vyasa.dts | 14 +++++++++++++-
|
||
4 files changed, 52 insertions(+), 4 deletions(-)
|
||
|
||
diff --git a/arch/arm/boot/dts/rk3288-miqi.dts b/arch/arm/boot/dts/rk3288-miqi.dts
|
||
index 213c9eb84f76..8a3992105151 100644
|
||
--- a/arch/arm/boot/dts/rk3288-miqi.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-miqi.dts
|
||
@@ -81,7 +81,19 @@
|
||
};
|
||
|
||
&cpu0 {
|
||
- cpu0-supply = <&vdd_cpu>;
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu2 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu3 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
};
|
||
|
||
&emmc {
|
||
diff --git a/arch/arm/boot/dts/rk3288-popmetal.dts b/arch/arm/boot/dts/rk3288-popmetal.dts
|
||
index 6a51940398b5..160ed8b932fb 100644
|
||
--- a/arch/arm/boot/dts/rk3288-popmetal.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-popmetal.dts
|
||
@@ -103,7 +103,19 @@
|
||
};
|
||
|
||
&cpu0 {
|
||
- cpu0-supply = <&vdd_cpu>;
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu2 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu3 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
};
|
||
|
||
&emmc {
|
||
diff --git a/arch/arm/boot/dts/rk3288-r89.dts b/arch/arm/boot/dts/rk3288-r89.dts
|
||
index a258c7ae5329..e5ba901c7dcb 100644
|
||
--- a/arch/arm/boot/dts/rk3288-r89.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-r89.dts
|
||
@@ -91,7 +91,19 @@
|
||
};
|
||
|
||
&cpu0 {
|
||
- cpu0-supply = <&vdd_cpu>;
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu2 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu3 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
};
|
||
|
||
&gmac {
|
||
diff --git a/arch/arm/boot/dts/rk3288-vyasa.dts b/arch/arm/boot/dts/rk3288-vyasa.dts
|
||
index 1a20854a1317..aa50f8ed4ca0 100644
|
||
--- a/arch/arm/boot/dts/rk3288-vyasa.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-vyasa.dts
|
||
@@ -125,7 +125,19 @@
|
||
};
|
||
|
||
&cpu0 {
|
||
- cpu0-supply = <&vdd_cpu>;
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu2 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
+};
|
||
+
|
||
+&cpu3 {
|
||
+ cpu-supply = <&vdd_cpu>;
|
||
};
|
||
|
||
&emmc {
|
||
|
||
From 23f9077620fd1f450589387e5951d0db36d2f6d4 Mon Sep 17 00:00:00 2001
|
||
From: Johan Jonker <jbx6244@gmail.com>
|
||
Date: Thu, 13 Aug 2020 19:24:50 +0200
|
||
Subject: [PATCH] ARM: dts: rockchip: rk3066a: add label to cpu@1
|
||
|
||
Add label to cpu@1 for later use.
|
||
|
||
Signed-off-by: Johan Jonker <jbx6244@gmail.com>
|
||
Link: https://lore.kernel.org/r/20200813172451.13754-1-jbx6244@gmail.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 9ab4a7312bf31611f3a9c95470f15b3f2bcd83e3)
|
||
---
|
||
arch/arm/boot/dts/rk3066a.dtsi | 2 +-
|
||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
||
diff --git a/arch/arm/boot/dts/rk3066a.dtsi b/arch/arm/boot/dts/rk3066a.dtsi
|
||
index b599394d149d..252750c97f97 100644
|
||
--- a/arch/arm/boot/dts/rk3066a.dtsi
|
||
+++ b/arch/arm/boot/dts/rk3066a.dtsi
|
||
@@ -36,7 +36,7 @@
|
||
clock-latency = <40000>;
|
||
clocks = <&cru ARMCLK>;
|
||
};
|
||
- cpu@1 {
|
||
+ cpu1: cpu@1 {
|
||
device_type = "cpu";
|
||
compatible = "arm,cortex-a9";
|
||
next-level-cache = <&L2>;
|
||
|
||
From c9ab5671bc0bceac1179f1566daf964c12c4be03 Mon Sep 17 00:00:00 2001
|
||
From: Johan Jonker <jbx6244@gmail.com>
|
||
Date: Thu, 13 Aug 2020 19:24:51 +0200
|
||
Subject: [PATCH] ARM: dts: rockchip: update cpu supplies on rk3066a
|
||
|
||
The use of cpu0-supply for cpu0 alone is deprecated,
|
||
so add cpu-supply to each cpu separately and
|
||
update all existing rk3066a boards.
|
||
|
||
Signed-off-by: Johan Jonker <jbx6244@gmail.com>
|
||
Link: https://lore.kernel.org/r/20200813172451.13754-2-jbx6244@gmail.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 20e464c0f12a9b1930adb0365326037d5b060cee)
|
||
---
|
||
arch/arm/boot/dts/rk3066a-bqcurie2.dts | 6 +++++-
|
||
arch/arm/boot/dts/rk3066a-marsboard.dts | 6 +++++-
|
||
arch/arm/boot/dts/rk3066a-rayeager.dts | 6 +++++-
|
||
3 files changed, 15 insertions(+), 3 deletions(-)
|
||
|
||
diff --git a/arch/arm/boot/dts/rk3066a-bqcurie2.dts b/arch/arm/boot/dts/rk3066a-bqcurie2.dts
|
||
index 0a56a2f1bc4d..eba7a1344976 100644
|
||
--- a/arch/arm/boot/dts/rk3066a-bqcurie2.dts
|
||
+++ b/arch/arm/boot/dts/rk3066a-bqcurie2.dts
|
||
@@ -63,7 +63,11 @@
|
||
};
|
||
|
||
&cpu0 {
|
||
- cpu0-supply = <&vdd_arm>;
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
};
|
||
|
||
&i2c1 {
|
||
diff --git a/arch/arm/boot/dts/rk3066a-marsboard.dts b/arch/arm/boot/dts/rk3066a-marsboard.dts
|
||
index 7e01f6406a86..6b121658d93c 100644
|
||
--- a/arch/arm/boot/dts/rk3066a-marsboard.dts
|
||
+++ b/arch/arm/boot/dts/rk3066a-marsboard.dts
|
||
@@ -47,7 +47,11 @@
|
||
};
|
||
|
||
&cpu0 {
|
||
- cpu0-supply = <&vdd_arm>;
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
};
|
||
|
||
&i2c1 {
|
||
diff --git a/arch/arm/boot/dts/rk3066a-rayeager.dts b/arch/arm/boot/dts/rk3066a-rayeager.dts
|
||
index f9db6bb9fa11..309518403d86 100644
|
||
--- a/arch/arm/boot/dts/rk3066a-rayeager.dts
|
||
+++ b/arch/arm/boot/dts/rk3066a-rayeager.dts
|
||
@@ -128,7 +128,11 @@
|
||
};
|
||
|
||
&cpu0 {
|
||
- cpu0-supply = <&vdd_arm>;
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
};
|
||
|
||
&emac {
|
||
|
||
From 4b163a2456edff104e7c9e8d6852afb5aec99b7c Mon Sep 17 00:00:00 2001
|
||
From: Adrian Schmutzler <freifunk@adrianschmutzler.de>
|
||
Date: Sun, 30 Aug 2020 21:08:20 +0200
|
||
Subject: [PATCH] ARM: dts: rockchip: replace status value "ok" by "okay"
|
||
|
||
While the DT parser recognizes "ok" as a valid value for the
|
||
"status" property, it is actually mentioned nowhere. Use the
|
||
proper value "okay" instead, as done in the majority of files
|
||
already.
|
||
|
||
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
|
||
Link: https://lore.kernel.org/r/20200830190820.20583-1-freifunk@adrianschmutzler.de
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 0cf10e6f94335495f90fc62fb75d9569f6a603fb)
|
||
---
|
||
arch/arm/boot/dts/rk3288-evb.dtsi | 2 +-
|
||
arch/arm/boot/dts/rk3288-firefly-reload-core.dtsi | 2 +-
|
||
arch/arm/boot/dts/rk3288-firefly.dtsi | 2 +-
|
||
arch/arm/boot/dts/rk3288-miqi.dts | 2 +-
|
||
arch/arm/boot/dts/rk3288-popmetal.dts | 2 +-
|
||
arch/arm/boot/dts/rk3288-r89.dts | 2 +-
|
||
arch/arm/boot/dts/rk3288-rock2-square.dts | 2 +-
|
||
arch/arm/boot/dts/rk3288-tinker.dtsi | 2 +-
|
||
8 files changed, 8 insertions(+), 8 deletions(-)
|
||
|
||
diff --git a/arch/arm/boot/dts/rk3288-evb.dtsi b/arch/arm/boot/dts/rk3288-evb.dtsi
|
||
index 018802df4c0e..c4ca73b40d4a 100644
|
||
--- a/arch/arm/boot/dts/rk3288-evb.dtsi
|
||
+++ b/arch/arm/boot/dts/rk3288-evb.dtsi
|
||
@@ -247,7 +247,7 @@
|
||
pinctrl-0 = <&rgmii_pins>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&gpu {
|
||
diff --git a/arch/arm/boot/dts/rk3288-firefly-reload-core.dtsi b/arch/arm/boot/dts/rk3288-firefly-reload-core.dtsi
|
||
index 61435d8ee37b..36efa36b7190 100644
|
||
--- a/arch/arm/boot/dts/rk3288-firefly-reload-core.dtsi
|
||
+++ b/arch/arm/boot/dts/rk3288-firefly-reload-core.dtsi
|
||
@@ -61,7 +61,7 @@
|
||
snps,reset-gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_LOW>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&i2c0 {
|
||
diff --git a/arch/arm/boot/dts/rk3288-firefly.dtsi b/arch/arm/boot/dts/rk3288-firefly.dtsi
|
||
index e5c4fd4ea67e..7fb582302b32 100644
|
||
--- a/arch/arm/boot/dts/rk3288-firefly.dtsi
|
||
+++ b/arch/arm/boot/dts/rk3288-firefly.dtsi
|
||
@@ -191,7 +191,7 @@
|
||
snps,reset-gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_LOW>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&gpu {
|
||
diff --git a/arch/arm/boot/dts/rk3288-miqi.dts b/arch/arm/boot/dts/rk3288-miqi.dts
|
||
index 8a3992105151..cf54d5ffff2f 100644
|
||
--- a/arch/arm/boot/dts/rk3288-miqi.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-miqi.dts
|
||
@@ -120,7 +120,7 @@
|
||
snps,reset-gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_LOW>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&hdmi {
|
||
diff --git a/arch/arm/boot/dts/rk3288-popmetal.dts b/arch/arm/boot/dts/rk3288-popmetal.dts
|
||
index 160ed8b932fb..8c7376d64bc4 100644
|
||
--- a/arch/arm/boot/dts/rk3288-popmetal.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-popmetal.dts
|
||
@@ -161,7 +161,7 @@
|
||
pinctrl-0 = <&rgmii_pins>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&hdmi {
|
||
diff --git a/arch/arm/boot/dts/rk3288-r89.dts b/arch/arm/boot/dts/rk3288-r89.dts
|
||
index e5ba901c7dcb..55467bc30fa6 100644
|
||
--- a/arch/arm/boot/dts/rk3288-r89.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-r89.dts
|
||
@@ -119,7 +119,7 @@
|
||
pinctrl-0 = <&rgmii_pins>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&hdmi {
|
||
diff --git a/arch/arm/boot/dts/rk3288-rock2-square.dts b/arch/arm/boot/dts/rk3288-rock2-square.dts
|
||
index 3cca4d0f9b09..c4d1d142d8c6 100644
|
||
--- a/arch/arm/boot/dts/rk3288-rock2-square.dts
|
||
+++ b/arch/arm/boot/dts/rk3288-rock2-square.dts
|
||
@@ -156,7 +156,7 @@
|
||
};
|
||
|
||
&gmac {
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&hdmi {
|
||
diff --git a/arch/arm/boot/dts/rk3288-tinker.dtsi b/arch/arm/boot/dts/rk3288-tinker.dtsi
|
||
index 90e9be443fe6..9c1e38c54eae 100644
|
||
--- a/arch/arm/boot/dts/rk3288-tinker.dtsi
|
||
+++ b/arch/arm/boot/dts/rk3288-tinker.dtsi
|
||
@@ -137,7 +137,7 @@
|
||
snps,reset-delays-us = <0 10000 1000000>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&gpu {
|
||
|
||
From 26f3fea877d88bffe0cfbccafb3109a5b4700de9 Mon Sep 17 00:00:00 2001
|
||
From: Adrian Schmutzler <freifunk@adrianschmutzler.de>
|
||
Date: Sun, 30 Aug 2020 22:11:12 +0200
|
||
Subject: [PATCH] arm64: dts: rockchip: replace status value "ok" by "okay"
|
||
|
||
While the DT parser recognizes "ok" as a valid value for the
|
||
"status" property, it is actually mentioned nowhere. Use the
|
||
proper value "okay" instead, as done in the majority of files
|
||
already.
|
||
|
||
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
|
||
Link: https://lore.kernel.org/r/20200830201112.1934-1-freifunk@adrianschmutzler.de
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 9caff35d7eba8e15c996c694a282fd38b2ea345e)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi | 2 +-
|
||
arch/arm64/boot/dts/rockchip/rk3368-orion-r68-meta.dts | 2 +-
|
||
arch/arm64/boot/dts/rockchip/rk3368-r88.dts | 4 ++--
|
||
3 files changed, 4 insertions(+), 4 deletions(-)
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi b/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi
|
||
index 1c52f47c43a6..87fabc64cc39 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi
|
||
@@ -134,7 +134,7 @@
|
||
pinctrl-0 = <&rmii_pins>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&i2c0 {
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3368-orion-r68-meta.dts b/arch/arm64/boot/dts/rockchip/rk3368-orion-r68-meta.dts
|
||
index b058ce999e3b..ecce16ecc9c3 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3368-orion-r68-meta.dts
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3368-orion-r68-meta.dts
|
||
@@ -183,7 +183,7 @@
|
||
snps,reset-delays-us = <0 10000 1000000>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&i2c0 {
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3368-r88.dts b/arch/arm64/boot/dts/rockchip/rk3368-r88.dts
|
||
index 236ab0f1b206..2582fa4b90e2 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3368-r88.dts
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3368-r88.dts
|
||
@@ -167,7 +167,7 @@
|
||
pinctrl-0 = <&rmii_pins>;
|
||
tx_delay = <0x30>;
|
||
rx_delay = <0x10>;
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
};
|
||
|
||
&i2c0 {
|
||
@@ -198,7 +198,7 @@
|
||
};
|
||
|
||
&io_domains {
|
||
- status = "ok";
|
||
+ status = "okay";
|
||
|
||
audio-supply = <&vcc_io>;
|
||
gpio30-supply = <&vcc_io>;
|
||
|
||
From 28e7a5de4a188cb33017f93a025b3888bf09a74c Mon Sep 17 00:00:00 2001
|
||
From: Krzysztof Kozlowski <krzk@kernel.org>
|
||
Date: Fri, 28 Aug 2020 17:26:35 +0200
|
||
Subject: [PATCH] dmaengine: pl330: Simplify with dev_err_probe()
|
||
|
||
Common pattern of handling deferred probe can be simplified with
|
||
dev_err_probe(). Less code and the error value gets printed.
|
||
|
||
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200828152637.16903-1-krzk@kernel.org
|
||
Signed-off-by: Vinod Koul <vkoul@kernel.org>
|
||
(cherry picked from commit af53bef5636d92e81279f4a16f814f8dccf9bf89)
|
||
---
|
||
drivers/dma/pl330.c | 9 +++------
|
||
1 file changed, 3 insertions(+), 6 deletions(-)
|
||
|
||
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
|
||
index 106f47298f9e..bb27338ec1ae 100644
|
||
--- a/drivers/dma/pl330.c
|
||
+++ b/drivers/dma/pl330.c
|
||
@@ -3034,9 +3034,7 @@ pl330_probe(struct amba_device *adev, const struct amba_id *id)
|
||
|
||
pl330->rstc = devm_reset_control_get_optional(&adev->dev, "dma");
|
||
if (IS_ERR(pl330->rstc)) {
|
||
- if (PTR_ERR(pl330->rstc) != -EPROBE_DEFER)
|
||
- dev_err(&adev->dev, "Failed to get reset!\n");
|
||
- return PTR_ERR(pl330->rstc);
|
||
+ return dev_err_probe(&adev->dev, PTR_ERR(pl330->rstc), "Failed to get reset!\n");
|
||
} else {
|
||
ret = reset_control_deassert(pl330->rstc);
|
||
if (ret) {
|
||
@@ -3047,9 +3045,8 @@ pl330_probe(struct amba_device *adev, const struct amba_id *id)
|
||
|
||
pl330->rstc_ocp = devm_reset_control_get_optional(&adev->dev, "dma-ocp");
|
||
if (IS_ERR(pl330->rstc_ocp)) {
|
||
- if (PTR_ERR(pl330->rstc_ocp) != -EPROBE_DEFER)
|
||
- dev_err(&adev->dev, "Failed to get OCP reset!\n");
|
||
- return PTR_ERR(pl330->rstc_ocp);
|
||
+ return dev_err_probe(&adev->dev, PTR_ERR(pl330->rstc_ocp),
|
||
+ "Failed to get OCP reset!\n");
|
||
} else {
|
||
ret = reset_control_deassert(pl330->rstc_ocp);
|
||
if (ret) {
|
||
|
||
From da47d555261d41660af9d1071f22b044079d8aff Mon Sep 17 00:00:00 2001
|
||
From: Robin Murphy <robin.murphy@arm.com>
|
||
Date: Thu, 3 Sep 2020 21:25:53 +0100
|
||
Subject: [PATCH] dmaengine: pl330: Drop local dma_parms
|
||
|
||
Since commit f458488425f1 ("amba: Initialize dma_parms for amba
|
||
devices"), struct amba_device already provides a dma_parms structure,
|
||
so we can save allocating another one.
|
||
|
||
Signed-off-by: Robin Murphy <robin.murphy@arm.com>
|
||
Link: https://lore.kernel.org/r/c9e58882e33f22f9b0a6d65a5507e24004512148.1599164692.git.robin.murphy@arm.com
|
||
Signed-off-by: Vinod Koul <vkoul@kernel.org>
|
||
(cherry picked from commit 2fc3cad287c62c6477ab674e4430662b470c3a22)
|
||
---
|
||
drivers/dma/pl330.c | 5 -----
|
||
1 file changed, 5 deletions(-)
|
||
|
||
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
|
||
index bb27338ec1ae..000c3c4b4f7a 100644
|
||
--- a/drivers/dma/pl330.c
|
||
+++ b/drivers/dma/pl330.c
|
||
@@ -460,9 +460,6 @@ struct pl330_dmac {
|
||
/* DMA-Engine Device */
|
||
struct dma_device ddma;
|
||
|
||
- /* Holds info about sg limitations */
|
||
- struct device_dma_parameters dma_parms;
|
||
-
|
||
/* Pool of descriptors available for the DMAC's channels */
|
||
struct list_head desc_pool;
|
||
/* To protect desc_pool manipulation */
|
||
@@ -3151,8 +3148,6 @@ pl330_probe(struct amba_device *adev, const struct amba_id *id)
|
||
}
|
||
}
|
||
|
||
- adev->dev.dma_parms = &pl330->dma_parms;
|
||
-
|
||
/*
|
||
* This is the limit for transfers with a buswidth of 1, larger
|
||
* buswidths will have larger limits.
|
||
|
||
From 86d82ef8547894e41cfded4a7521c7dcb6f3dc54 Mon Sep 17 00:00:00 2001
|
||
From: Tuo Li <tuoli96@outlook.com>
|
||
Date: Mon, 7 Sep 2020 21:09:37 +0800
|
||
Subject: [PATCH] ALSA: rockchip_i2s: fix a possible divide-by-zero bug in
|
||
rockchip_i2s_hw_params()
|
||
|
||
The variable bclk_rate is checked in:
|
||
if (bclk_rate && mclk_rate % bclk_rate)
|
||
|
||
This indicates that bclk_rate can be zero.
|
||
If so, a divide-by-zero bug will occur:
|
||
div_bclk = mclk_rate / bclk_rate;
|
||
|
||
To fix this possible bug, the function returns -EINVAL when bclk_rate is
|
||
zero.
|
||
|
||
Signed-off-by: Tuo Li <tuoli96@outlook.com>
|
||
Link: https://lore.kernel.org/r/TY2PR04MB4029799E60A5BCAAD5B7B5BBB8280@TY2PR04MB4029.apcprd04.prod.outlook.com
|
||
Signed-off-by: Mark Brown <broonie@kernel.org>
|
||
(cherry picked from commit 375e2c352582442783178e6a33c279d6bc9354a2)
|
||
---
|
||
sound/soc/rockchip/rockchip_i2s.c | 2 +-
|
||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
||
diff --git a/sound/soc/rockchip/rockchip_i2s.c b/sound/soc/rockchip/rockchip_i2s.c
|
||
index d1438753edb4..593299675b8c 100644
|
||
--- a/sound/soc/rockchip/rockchip_i2s.c
|
||
+++ b/sound/soc/rockchip/rockchip_i2s.c
|
||
@@ -279,7 +279,7 @@ static int rockchip_i2s_hw_params(struct snd_pcm_substream *substream,
|
||
if (i2s->is_master_mode) {
|
||
mclk_rate = clk_get_rate(i2s->mclk);
|
||
bclk_rate = 2 * 32 * params_rate(params);
|
||
- if (bclk_rate && mclk_rate % bclk_rate)
|
||
+ if (bclk_rate == 0 || mclk_rate % bclk_rate)
|
||
return -EINVAL;
|
||
|
||
div_bclk = mclk_rate / bclk_rate;
|
||
|
||
From ddbd68d0a7bc4931238977a1a6b35741c77c550c Mon Sep 17 00:00:00 2001
|
||
From: Allen Pais <allen.lkml@gmail.com>
|
||
Date: Mon, 31 Aug 2020 16:05:27 +0530
|
||
Subject: [PATCH] dmaengine: pl330: convert tasklets to use new tasklet_setup()
|
||
API
|
||
|
||
In preparation for unconditionally passing the
|
||
struct tasklet_struct pointer to all tasklet
|
||
callbacks, switch to using the new tasklet_setup()
|
||
and from_tasklet() to pass the tasklet pointer explicitly.
|
||
|
||
Signed-off-by: Romain Perier <romain.perier@gmail.com>
|
||
Signed-off-by: Allen Pais <allen.lkml@gmail.com>
|
||
Link: https://lore.kernel.org/r/20200831103542.305571-21-allen.lkml@gmail.com
|
||
Signed-off-by: Vinod Koul <vkoul@kernel.org>
|
||
(cherry picked from commit ab2a98ae4105d805383f840c54fabbb6560e2fc7)
|
||
---
|
||
drivers/dma/pl330.c | 12 ++++++------
|
||
1 file changed, 6 insertions(+), 6 deletions(-)
|
||
|
||
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
|
||
index 000c3c4b4f7a..d98fb318dd2d 100644
|
||
--- a/drivers/dma/pl330.c
|
||
+++ b/drivers/dma/pl330.c
|
||
@@ -1573,9 +1573,9 @@ static void dma_pl330_rqcb(struct dma_pl330_desc *desc, enum pl330_op_err err)
|
||
tasklet_schedule(&pch->task);
|
||
}
|
||
|
||
-static void pl330_dotask(unsigned long data)
|
||
+static void pl330_dotask(struct tasklet_struct *t)
|
||
{
|
||
- struct pl330_dmac *pl330 = (struct pl330_dmac *) data;
|
||
+ struct pl330_dmac *pl330 = from_tasklet(pl330, t, tasks);
|
||
unsigned long flags;
|
||
int i;
|
||
|
||
@@ -1979,7 +1979,7 @@ static int pl330_add(struct pl330_dmac *pl330)
|
||
return ret;
|
||
}
|
||
|
||
- tasklet_init(&pl330->tasks, pl330_dotask, (unsigned long) pl330);
|
||
+ tasklet_setup(&pl330->tasks, pl330_dotask);
|
||
|
||
pl330->state = INIT;
|
||
|
||
@@ -2062,9 +2062,9 @@ static inline void fill_queue(struct dma_pl330_chan *pch)
|
||
}
|
||
}
|
||
|
||
-static void pl330_tasklet(unsigned long data)
|
||
+static void pl330_tasklet(struct tasklet_struct *t)
|
||
{
|
||
- struct dma_pl330_chan *pch = (struct dma_pl330_chan *)data;
|
||
+ struct dma_pl330_chan *pch = from_tasklet(pch, t, task);
|
||
struct dma_pl330_desc *desc, *_dt;
|
||
unsigned long flags;
|
||
bool power_down = false;
|
||
@@ -2172,7 +2172,7 @@ static int pl330_alloc_chan_resources(struct dma_chan *chan)
|
||
return -ENOMEM;
|
||
}
|
||
|
||
- tasklet_init(&pch->task, pl330_tasklet, (unsigned long) pch);
|
||
+ tasklet_setup(&pch->task, pl330_tasklet);
|
||
|
||
spin_unlock_irqrestore(&pl330->lock, flags);
|
||
|
||
|
||
From 1004f7a89c69a41e05bfb0e50b855192eb13def4 Mon Sep 17 00:00:00 2001
|
||
From: Krzysztof Kozlowski <krzk@kernel.org>
|
||
Date: Wed, 16 Sep 2020 18:17:40 +0200
|
||
Subject: [PATCH] clk: rockchip: rk3308: drop unused mux_timer_src_p
|
||
MIME-Version: 1.0
|
||
Content-Type: text/plain; charset=UTF-8
|
||
Content-Transfer-Encoding: 8bit
|
||
|
||
The parent names 'mux_timer_src_p' is not used:
|
||
|
||
In file included from drivers/clk/rockchip/clk-rk3308.c:13:0:
|
||
drivers/clk/rockchip/clk-rk3308.c:136:7: warning: ‘mux_timer_src_p’ defined but not used [-Wunused-const-variable=]
|
||
|
||
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200916161740.14173-6-krzk@kernel.org
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 816e87253dec6686d2ef1bc2d84e82f033555046)
|
||
---
|
||
drivers/clk/rockchip/clk-rk3308.c | 1 -
|
||
1 file changed, 1 deletion(-)
|
||
|
||
diff --git a/drivers/clk/rockchip/clk-rk3308.c b/drivers/clk/rockchip/clk-rk3308.c
|
||
index b0baf87a283e..5bf15f2a44b7 100644
|
||
--- a/drivers/clk/rockchip/clk-rk3308.c
|
||
+++ b/drivers/clk/rockchip/clk-rk3308.c
|
||
@@ -133,7 +133,6 @@ PNAME(mux_uart1_p) = { "clk_uart1_src", "dummy", "clk_uart1_frac" };
|
||
PNAME(mux_uart2_p) = { "clk_uart2_src", "dummy", "clk_uart2_frac" };
|
||
PNAME(mux_uart3_p) = { "clk_uart3_src", "dummy", "clk_uart3_frac" };
|
||
PNAME(mux_uart4_p) = { "clk_uart4_src", "dummy", "clk_uart4_frac" };
|
||
-PNAME(mux_timer_src_p) = { "xin24m", "clk_rtc32k" };
|
||
PNAME(mux_dclk_vop_p) = { "dclk_vop_src", "dclk_vop_frac", "xin24m" };
|
||
PNAME(mux_nandc_p) = { "clk_nandc_div", "clk_nandc_div50" };
|
||
PNAME(mux_sdmmc_p) = { "clk_sdmmc_div", "clk_sdmmc_div50" };
|
||
|
||
From 61d1828ae692430d8b032376bae59602398fdb36 Mon Sep 17 00:00:00 2001
|
||
From: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Date: Mon, 14 Sep 2020 10:22:20 +0800
|
||
Subject: [PATCH] clk: rockchip: Use clk_hw_register_composite instead of
|
||
clk_register_composite calls
|
||
|
||
clk_hw_register_composite it's already exported.
|
||
Preparation for compilation of rK common clock drivers into modules.
|
||
|
||
Reported-by: kernel test robot <lkp@intel.com>
|
||
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
|
||
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
|
||
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200914022225.23613-2-zhangqing@rock-chips.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 63207c37eac4f15fdebac14685a315c259c0a780)
|
||
---
|
||
drivers/clk/rockchip/clk-half-divider.c | 18 +++++-----
|
||
drivers/clk/rockchip/clk.c | 61 ++++++++++++++++-----------------
|
||
2 files changed, 40 insertions(+), 39 deletions(-)
|
||
|
||
diff --git a/drivers/clk/rockchip/clk-half-divider.c b/drivers/clk/rockchip/clk-half-divider.c
|
||
index b333fc28c94b..e97fd3dfbae7 100644
|
||
--- a/drivers/clk/rockchip/clk-half-divider.c
|
||
+++ b/drivers/clk/rockchip/clk-half-divider.c
|
||
@@ -166,7 +166,7 @@ struct clk *rockchip_clk_register_halfdiv(const char *name,
|
||
unsigned long flags,
|
||
spinlock_t *lock)
|
||
{
|
||
- struct clk *clk = ERR_PTR(-ENOMEM);
|
||
+ struct clk_hw *hw;
|
||
struct clk_mux *mux = NULL;
|
||
struct clk_gate *gate = NULL;
|
||
struct clk_divider *div = NULL;
|
||
@@ -212,16 +212,18 @@ struct clk *rockchip_clk_register_halfdiv(const char *name,
|
||
div_ops = &clk_half_divider_ops;
|
||
}
|
||
|
||
- clk = clk_register_composite(NULL, name, parent_names, num_parents,
|
||
- mux ? &mux->hw : NULL, mux_ops,
|
||
- div ? &div->hw : NULL, div_ops,
|
||
- gate ? &gate->hw : NULL, gate_ops,
|
||
- flags);
|
||
+ hw = clk_hw_register_composite(NULL, name, parent_names, num_parents,
|
||
+ mux ? &mux->hw : NULL, mux_ops,
|
||
+ div ? &div->hw : NULL, div_ops,
|
||
+ gate ? &gate->hw : NULL, gate_ops,
|
||
+ flags);
|
||
+ if (IS_ERR(hw))
|
||
+ goto err_div;
|
||
|
||
- return clk;
|
||
+ return hw->clk;
|
||
err_div:
|
||
kfree(gate);
|
||
err_gate:
|
||
kfree(mux);
|
||
- return ERR_PTR(-ENOMEM);
|
||
+ return ERR_CAST(hw);
|
||
}
|
||
diff --git a/drivers/clk/rockchip/clk.c b/drivers/clk/rockchip/clk.c
|
||
index 546e810c3560..46409972983e 100644
|
||
--- a/drivers/clk/rockchip/clk.c
|
||
+++ b/drivers/clk/rockchip/clk.c
|
||
@@ -43,7 +43,7 @@ static struct clk *rockchip_clk_register_branch(const char *name,
|
||
u8 gate_shift, u8 gate_flags, unsigned long flags,
|
||
spinlock_t *lock)
|
||
{
|
||
- struct clk *clk;
|
||
+ struct clk_hw *hw;
|
||
struct clk_mux *mux = NULL;
|
||
struct clk_gate *gate = NULL;
|
||
struct clk_divider *div = NULL;
|
||
@@ -100,20 +100,18 @@ static struct clk *rockchip_clk_register_branch(const char *name,
|
||
: &clk_divider_ops;
|
||
}
|
||
|
||
- clk = clk_register_composite(NULL, name, parent_names, num_parents,
|
||
- mux ? &mux->hw : NULL, mux_ops,
|
||
- div ? &div->hw : NULL, div_ops,
|
||
- gate ? &gate->hw : NULL, gate_ops,
|
||
- flags);
|
||
-
|
||
- if (IS_ERR(clk)) {
|
||
- ret = PTR_ERR(clk);
|
||
- goto err_composite;
|
||
+ hw = clk_hw_register_composite(NULL, name, parent_names, num_parents,
|
||
+ mux ? &mux->hw : NULL, mux_ops,
|
||
+ div ? &div->hw : NULL, div_ops,
|
||
+ gate ? &gate->hw : NULL, gate_ops,
|
||
+ flags);
|
||
+ if (IS_ERR(hw)) {
|
||
+ kfree(div);
|
||
+ kfree(gate);
|
||
+ return ERR_CAST(hw);
|
||
}
|
||
|
||
- return clk;
|
||
-err_composite:
|
||
- kfree(div);
|
||
+ return hw->clk;
|
||
err_div:
|
||
kfree(gate);
|
||
err_gate:
|
||
@@ -214,8 +212,8 @@ static struct clk *rockchip_clk_register_frac_branch(
|
||
unsigned long flags, struct rockchip_clk_branch *child,
|
||
spinlock_t *lock)
|
||
{
|
||
+ struct clk_hw *hw;
|
||
struct rockchip_clk_frac *frac;
|
||
- struct clk *clk;
|
||
struct clk_gate *gate = NULL;
|
||
struct clk_fractional_divider *div = NULL;
|
||
const struct clk_ops *div_ops = NULL, *gate_ops = NULL;
|
||
@@ -255,14 +253,14 @@ static struct clk *rockchip_clk_register_frac_branch(
|
||
div->approximation = rockchip_fractional_approximation;
|
||
div_ops = &clk_fractional_divider_ops;
|
||
|
||
- clk = clk_register_composite(NULL, name, parent_names, num_parents,
|
||
- NULL, NULL,
|
||
- &div->hw, div_ops,
|
||
- gate ? &gate->hw : NULL, gate_ops,
|
||
- flags | CLK_SET_RATE_UNGATE);
|
||
- if (IS_ERR(clk)) {
|
||
+ hw = clk_hw_register_composite(NULL, name, parent_names, num_parents,
|
||
+ NULL, NULL,
|
||
+ &div->hw, div_ops,
|
||
+ gate ? &gate->hw : NULL, gate_ops,
|
||
+ flags | CLK_SET_RATE_UNGATE);
|
||
+ if (IS_ERR(hw)) {
|
||
kfree(frac);
|
||
- return clk;
|
||
+ return ERR_CAST(hw);
|
||
}
|
||
|
||
if (child) {
|
||
@@ -292,7 +290,7 @@ static struct clk *rockchip_clk_register_frac_branch(
|
||
mux_clk = clk_register(NULL, &frac_mux->hw);
|
||
if (IS_ERR(mux_clk)) {
|
||
kfree(frac);
|
||
- return clk;
|
||
+ return mux_clk;
|
||
}
|
||
|
||
rockchip_clk_add_lookup(ctx, mux_clk, child->id);
|
||
@@ -301,7 +299,7 @@ static struct clk *rockchip_clk_register_frac_branch(
|
||
if (frac->mux_frac_idx >= 0) {
|
||
pr_debug("%s: found fractional parent in mux at pos %d\n",
|
||
__func__, frac->mux_frac_idx);
|
||
- ret = clk_notifier_register(clk, &frac->clk_nb);
|
||
+ ret = clk_notifier_register(hw->clk, &frac->clk_nb);
|
||
if (ret)
|
||
pr_err("%s: failed to register clock notifier for %s\n",
|
||
__func__, name);
|
||
@@ -311,7 +309,7 @@ static struct clk *rockchip_clk_register_frac_branch(
|
||
}
|
||
}
|
||
|
||
- return clk;
|
||
+ return hw->clk;
|
||
}
|
||
|
||
static struct clk *rockchip_clk_register_factor_branch(const char *name,
|
||
@@ -320,7 +318,7 @@ static struct clk *rockchip_clk_register_factor_branch(const char *name,
|
||
int gate_offset, u8 gate_shift, u8 gate_flags,
|
||
unsigned long flags, spinlock_t *lock)
|
||
{
|
||
- struct clk *clk;
|
||
+ struct clk_hw *hw;
|
||
struct clk_gate *gate = NULL;
|
||
struct clk_fixed_factor *fix = NULL;
|
||
|
||
@@ -349,16 +347,17 @@ static struct clk *rockchip_clk_register_factor_branch(const char *name,
|
||
fix->mult = mult;
|
||
fix->div = div;
|
||
|
||
- clk = clk_register_composite(NULL, name, parent_names, num_parents,
|
||
- NULL, NULL,
|
||
- &fix->hw, &clk_fixed_factor_ops,
|
||
- &gate->hw, &clk_gate_ops, flags);
|
||
- if (IS_ERR(clk)) {
|
||
+ hw = clk_hw_register_composite(NULL, name, parent_names, num_parents,
|
||
+ NULL, NULL,
|
||
+ &fix->hw, &clk_fixed_factor_ops,
|
||
+ &gate->hw, &clk_gate_ops, flags);
|
||
+ if (IS_ERR(hw)) {
|
||
kfree(fix);
|
||
kfree(gate);
|
||
+ return ERR_CAST(hw);
|
||
}
|
||
|
||
- return clk;
|
||
+ return hw->clk;
|
||
}
|
||
|
||
struct rockchip_clk_provider * __init rockchip_clk_init(struct device_node *np,
|
||
|
||
From ec0b48760e3c0efb4522dfedf3a5088e538991c5 Mon Sep 17 00:00:00 2001
|
||
From: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Date: Mon, 14 Sep 2020 10:22:21 +0800
|
||
Subject: [PATCH] clk: rockchip: Export rockchip_clk_register_ddrclk()
|
||
|
||
This is used by the Rockchip clk driver, export it to allow that
|
||
driver to be compiled as a module..
|
||
|
||
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
|
||
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200914022225.23613-3-zhangqing@rock-chips.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit f73907de3493b94d80af5122bcacc98f0e7b295b)
|
||
---
|
||
drivers/clk/rockchip/clk-ddr.c | 1 +
|
||
1 file changed, 1 insertion(+)
|
||
|
||
diff --git a/drivers/clk/rockchip/clk-ddr.c b/drivers/clk/rockchip/clk-ddr.c
|
||
index 9273bce4d7b6..86718c54e56b 100644
|
||
--- a/drivers/clk/rockchip/clk-ddr.c
|
||
+++ b/drivers/clk/rockchip/clk-ddr.c
|
||
@@ -136,3 +136,4 @@ struct clk *rockchip_clk_register_ddrclk(const char *name, int flags,
|
||
|
||
return clk;
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_register_ddrclk);
|
||
|
||
From e2b0bd39722ef935b30bacf97a23446297169ac7 Mon Sep 17 00:00:00 2001
|
||
From: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Date: Mon, 14 Sep 2020 10:22:22 +0800
|
||
Subject: [PATCH] clk: rockchip: Export rockchip_register_softrst()
|
||
|
||
This is used by the Rockchip clk driver, export it to allow that
|
||
driver to be compiled as a module..
|
||
|
||
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
|
||
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200914022225.23613-4-zhangqing@rock-chips.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 37353491d1a8c207685c138c3640bd43864b70d9)
|
||
---
|
||
drivers/clk/rockchip/softrst.c | 7 ++++---
|
||
1 file changed, 4 insertions(+), 3 deletions(-)
|
||
|
||
diff --git a/drivers/clk/rockchip/softrst.c b/drivers/clk/rockchip/softrst.c
|
||
index 5f1ff5e47c4f..5d07266745b8 100644
|
||
--- a/drivers/clk/rockchip/softrst.c
|
||
+++ b/drivers/clk/rockchip/softrst.c
|
||
@@ -77,9 +77,9 @@ static const struct reset_control_ops rockchip_softrst_ops = {
|
||
.deassert = rockchip_softrst_deassert,
|
||
};
|
||
|
||
-void __init rockchip_register_softrst(struct device_node *np,
|
||
- unsigned int num_regs,
|
||
- void __iomem *base, u8 flags)
|
||
+void rockchip_register_softrst(struct device_node *np,
|
||
+ unsigned int num_regs,
|
||
+ void __iomem *base, u8 flags)
|
||
{
|
||
struct rockchip_softrst *softrst;
|
||
int ret;
|
||
@@ -107,3 +107,4 @@ void __init rockchip_register_softrst(struct device_node *np,
|
||
kfree(softrst);
|
||
}
|
||
};
|
||
+EXPORT_SYMBOL_GPL(rockchip_register_softrst);
|
||
|
||
From 8af53c34ecbf759fccf3769fa03d43db2ac554cb Mon Sep 17 00:00:00 2001
|
||
From: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Date: Mon, 14 Sep 2020 10:22:23 +0800
|
||
Subject: [PATCH] clk: rockchip: Export some clock common APIs for module
|
||
drivers
|
||
|
||
This is used by the Rockchip clk driver, export it to allow that
|
||
driver to be compiled as a module.
|
||
|
||
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
|
||
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200914022225.23613-5-zhangqing@rock-chips.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit ea650c26611dd61adfcc8647d6144f2c9f453d90)
|
||
---
|
||
drivers/clk/rockchip/clk.c | 52 ++++++++++++++++++++++++++--------------------
|
||
1 file changed, 30 insertions(+), 22 deletions(-)
|
||
|
||
diff --git a/drivers/clk/rockchip/clk.c b/drivers/clk/rockchip/clk.c
|
||
index 46409972983e..b443169dd408 100644
|
||
--- a/drivers/clk/rockchip/clk.c
|
||
+++ b/drivers/clk/rockchip/clk.c
|
||
@@ -360,8 +360,9 @@ static struct clk *rockchip_clk_register_factor_branch(const char *name,
|
||
return hw->clk;
|
||
}
|
||
|
||
-struct rockchip_clk_provider * __init rockchip_clk_init(struct device_node *np,
|
||
- void __iomem *base, unsigned long nr_clks)
|
||
+struct rockchip_clk_provider *rockchip_clk_init(struct device_node *np,
|
||
+ void __iomem *base,
|
||
+ unsigned long nr_clks)
|
||
{
|
||
struct rockchip_clk_provider *ctx;
|
||
struct clk **clk_table;
|
||
@@ -393,14 +394,16 @@ struct rockchip_clk_provider * __init rockchip_clk_init(struct device_node *np,
|
||
kfree(ctx);
|
||
return ERR_PTR(-ENOMEM);
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_init);
|
||
|
||
-void __init rockchip_clk_of_add_provider(struct device_node *np,
|
||
- struct rockchip_clk_provider *ctx)
|
||
+void rockchip_clk_of_add_provider(struct device_node *np,
|
||
+ struct rockchip_clk_provider *ctx)
|
||
{
|
||
if (of_clk_add_provider(np, of_clk_src_onecell_get,
|
||
&ctx->clk_data))
|
||
pr_err("%s: could not register clk provider\n", __func__);
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_of_add_provider);
|
||
|
||
void rockchip_clk_add_lookup(struct rockchip_clk_provider *ctx,
|
||
struct clk *clk, unsigned int id)
|
||
@@ -408,8 +411,9 @@ void rockchip_clk_add_lookup(struct rockchip_clk_provider *ctx,
|
||
if (ctx->clk_data.clks && id)
|
||
ctx->clk_data.clks[id] = clk;
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_add_lookup);
|
||
|
||
-void __init rockchip_clk_register_plls(struct rockchip_clk_provider *ctx,
|
||
+void rockchip_clk_register_plls(struct rockchip_clk_provider *ctx,
|
||
struct rockchip_pll_clock *list,
|
||
unsigned int nr_pll, int grf_lock_offset)
|
||
{
|
||
@@ -432,11 +436,11 @@ void __init rockchip_clk_register_plls(struct rockchip_clk_provider *ctx,
|
||
rockchip_clk_add_lookup(ctx, clk, list->id);
|
||
}
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_register_plls);
|
||
|
||
-void __init rockchip_clk_register_branches(
|
||
- struct rockchip_clk_provider *ctx,
|
||
- struct rockchip_clk_branch *list,
|
||
- unsigned int nr_clk)
|
||
+void rockchip_clk_register_branches(struct rockchip_clk_provider *ctx,
|
||
+ struct rockchip_clk_branch *list,
|
||
+ unsigned int nr_clk)
|
||
{
|
||
struct clk *clk = NULL;
|
||
unsigned int idx;
|
||
@@ -565,14 +569,15 @@ void __init rockchip_clk_register_branches(
|
||
rockchip_clk_add_lookup(ctx, clk, list->id);
|
||
}
|
||
}
|
||
-
|
||
-void __init rockchip_clk_register_armclk(struct rockchip_clk_provider *ctx,
|
||
- unsigned int lookup_id,
|
||
- const char *name, const char *const *parent_names,
|
||
- u8 num_parents,
|
||
- const struct rockchip_cpuclk_reg_data *reg_data,
|
||
- const struct rockchip_cpuclk_rate_table *rates,
|
||
- int nrates)
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_register_branches);
|
||
+
|
||
+void rockchip_clk_register_armclk(struct rockchip_clk_provider *ctx,
|
||
+ unsigned int lookup_id,
|
||
+ const char *name, const char *const *parent_names,
|
||
+ u8 num_parents,
|
||
+ const struct rockchip_cpuclk_reg_data *reg_data,
|
||
+ const struct rockchip_cpuclk_rate_table *rates,
|
||
+ int nrates)
|
||
{
|
||
struct clk *clk;
|
||
|
||
@@ -587,9 +592,10 @@ void __init rockchip_clk_register_armclk(struct rockchip_clk_provider *ctx,
|
||
|
||
rockchip_clk_add_lookup(ctx, clk, lookup_id);
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_register_armclk);
|
||
|
||
-void __init rockchip_clk_protect_critical(const char *const clocks[],
|
||
- int nclocks)
|
||
+void rockchip_clk_protect_critical(const char *const clocks[],
|
||
+ int nclocks)
|
||
{
|
||
int i;
|
||
|
||
@@ -601,6 +607,7 @@ void __init rockchip_clk_protect_critical(const char *const clocks[],
|
||
clk_prepare_enable(clk);
|
||
}
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_clk_protect_critical);
|
||
|
||
static void __iomem *rst_base;
|
||
static unsigned int reg_restart;
|
||
@@ -620,10 +627,10 @@ static struct notifier_block rockchip_restart_handler = {
|
||
.priority = 128,
|
||
};
|
||
|
||
-void __init
|
||
+void
|
||
rockchip_register_restart_notifier(struct rockchip_clk_provider *ctx,
|
||
- unsigned int reg,
|
||
- void (*cb)(void))
|
||
+ unsigned int reg,
|
||
+ void (*cb)(void))
|
||
{
|
||
int ret;
|
||
|
||
@@ -635,3 +642,4 @@ rockchip_register_restart_notifier(struct rockchip_clk_provider *ctx,
|
||
pr_err("%s: cannot register restart handler, %d\n",
|
||
__func__, ret);
|
||
}
|
||
+EXPORT_SYMBOL_GPL(rockchip_register_restart_notifier);
|
||
|
||
From c71d3c0979104408630b2c540ae383b1ff0d4dd3 Mon Sep 17 00:00:00 2001
|
||
From: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Date: Mon, 14 Sep 2020 10:23:04 +0800
|
||
Subject: [PATCH] clk: rockchip: fix the clk config to support module build
|
||
|
||
use CONFIG_COMMON_CLK_ROCKCHIP for Rk common clk drivers.
|
||
use CONFIG_CLK_RKXX for Rk soc clk driver.
|
||
Mark CONFIG_CLK_RK3399 to "tristate",
|
||
to support building Rk3399 SoC clock driver as module.
|
||
|
||
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
|
||
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200914022304.23908-1-zhangqing@rock-chips.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 4d98ed1e126495016f2a3ef4db6379855c4aacf2)
|
||
---
|
||
drivers/clk/Kconfig | 1 +
|
||
drivers/clk/rockchip/Kconfig | 78 +++++++++++++++++++++++++++++++++++++++++++
|
||
drivers/clk/rockchip/Makefile | 42 ++++++++++++-----------
|
||
3 files changed, 101 insertions(+), 20 deletions(-)
|
||
create mode 100644 drivers/clk/rockchip/Kconfig
|
||
|
||
diff --git a/drivers/clk/Kconfig b/drivers/clk/Kconfig
|
||
index 4026fac9fac3..b41aaed9bd51 100644
|
||
--- a/drivers/clk/Kconfig
|
||
+++ b/drivers/clk/Kconfig
|
||
@@ -373,6 +373,7 @@ source "drivers/clk/meson/Kconfig"
|
||
source "drivers/clk/mvebu/Kconfig"
|
||
source "drivers/clk/qcom/Kconfig"
|
||
source "drivers/clk/renesas/Kconfig"
|
||
+source "drivers/clk/rockchip/Kconfig"
|
||
source "drivers/clk/samsung/Kconfig"
|
||
source "drivers/clk/sifive/Kconfig"
|
||
source "drivers/clk/sprd/Kconfig"
|
||
diff --git a/drivers/clk/rockchip/Kconfig b/drivers/clk/rockchip/Kconfig
|
||
new file mode 100644
|
||
index 000000000000..524b0e0df0a7
|
||
--- /dev/null
|
||
+++ b/drivers/clk/rockchip/Kconfig
|
||
@@ -0,0 +1,78 @@
|
||
+# SPDX-License-Identifier: GPL-2.0
|
||
+# common clock support for ROCKCHIP SoC family.
|
||
+
|
||
+config COMMON_CLK_ROCKCHIP
|
||
+ bool "Rockchip clock controller common support"
|
||
+ depends on ARCH_ROCKCHIP
|
||
+ default ARCH_ROCKCHIP
|
||
+ help
|
||
+ Say y here to enable common clock controller for Rockchip platforms.
|
||
+
|
||
+if COMMON_CLK_ROCKCHIP
|
||
+config CLK_PX30
|
||
+ bool "Rockchip PX30 clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for PX30 Clock Driver.
|
||
+
|
||
+config CLK_RV110X
|
||
+ bool "Rockchip RV110x clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RV110x Clock Driver.
|
||
+
|
||
+config CLK_RK3036
|
||
+ bool "Rockchip RK3036 clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK3036 Clock Driver.
|
||
+
|
||
+config CLK_RK312X
|
||
+ bool "Rockchip RK312x clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK312x Clock Driver.
|
||
+
|
||
+config CLK_RK3188
|
||
+ bool "Rockchip RK3188 clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK3188 Clock Driver.
|
||
+
|
||
+config CLK_RK322X
|
||
+ bool "Rockchip RK322x clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK322x Clock Driver.
|
||
+
|
||
+config CLK_RK3288
|
||
+ bool "Rockchip RK3288 clock controller support"
|
||
+ depends on ARM
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK3288 Clock Driver.
|
||
+
|
||
+config CLK_RK3308
|
||
+ bool "Rockchip RK3308 clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK3308 Clock Driver.
|
||
+
|
||
+config CLK_RK3328
|
||
+ bool "Rockchip RK3328 clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK3328 Clock Driver.
|
||
+
|
||
+config CLK_RK3368
|
||
+ bool "Rockchip RK3368 clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK3368 Clock Driver.
|
||
+
|
||
+config CLK_RK3399
|
||
+ bool "Rockchip RK3399 clock controller support"
|
||
+ default y
|
||
+ help
|
||
+ Build the driver for RK3399 Clock Driver.
|
||
+endif
|
||
diff --git a/drivers/clk/rockchip/Makefile b/drivers/clk/rockchip/Makefile
|
||
index 7c5b5813a87c..a99e4d9bbae1 100644
|
||
--- a/drivers/clk/rockchip/Makefile
|
||
+++ b/drivers/clk/rockchip/Makefile
|
||
@@ -3,24 +3,26 @@
|
||
# Rockchip Clock specific Makefile
|
||
#
|
||
|
||
-obj-y += clk.o
|
||
-obj-y += clk-pll.o
|
||
-obj-y += clk-cpu.o
|
||
-obj-y += clk-half-divider.o
|
||
-obj-y += clk-inverter.o
|
||
-obj-y += clk-mmc-phase.o
|
||
-obj-y += clk-muxgrf.o
|
||
-obj-y += clk-ddr.o
|
||
-obj-$(CONFIG_RESET_CONTROLLER) += softrst.o
|
||
+obj-$(CONFIG_COMMON_CLK_ROCKCHIP) += clk-rockchip.o
|
||
|
||
-obj-y += clk-px30.o
|
||
-obj-y += clk-rv1108.o
|
||
-obj-y += clk-rk3036.o
|
||
-obj-y += clk-rk3128.o
|
||
-obj-y += clk-rk3188.o
|
||
-obj-y += clk-rk3228.o
|
||
-obj-y += clk-rk3288.o
|
||
-obj-y += clk-rk3308.o
|
||
-obj-y += clk-rk3328.o
|
||
-obj-y += clk-rk3368.o
|
||
-obj-y += clk-rk3399.o
|
||
+clk-rockchip-y += clk.o
|
||
+clk-rockchip-y += clk-pll.o
|
||
+clk-rockchip-y += clk-cpu.o
|
||
+clk-rockchip-y += clk-half-divider.o
|
||
+clk-rockchip-y += clk-inverter.o
|
||
+clk-rockchip-y += clk-mmc-phase.o
|
||
+clk-rockchip-y += clk-muxgrf.o
|
||
+clk-rockchip-y += clk-ddr.o
|
||
+clk-rockchip-$(CONFIG_RESET_CONTROLLER) += softrst.o
|
||
+
|
||
+obj-$(CONFIG_CLK_PX30) += clk-px30.o
|
||
+obj-$(CONFIG_CLK_RV110X) += clk-rv1108.o
|
||
+obj-$(CONFIG_CLK_RK3036) += clk-rk3036.o
|
||
+obj-$(CONFIG_CLK_RK312X) += clk-rk3128.o
|
||
+obj-$(CONFIG_CLK_RK3188) += clk-rk3188.o
|
||
+obj-$(CONFIG_CLK_RK322X) += clk-rk3228.o
|
||
+obj-$(CONFIG_CLK_RK3288) += clk-rk3288.o
|
||
+obj-$(CONFIG_CLK_RK3308) += clk-rk3308.o
|
||
+obj-$(CONFIG_CLK_RK3328) += clk-rk3328.o
|
||
+obj-$(CONFIG_CLK_RK3368) += clk-rk3368.o
|
||
+obj-$(CONFIG_CLK_RK3399) += clk-rk3399.o
|
||
|
||
From 640cf0e121d7879899d26bce21b5c7d954f67b09 Mon Sep 17 00:00:00 2001
|
||
From: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Date: Mon, 14 Sep 2020 10:23:16 +0800
|
||
Subject: [PATCH] clk: rockchip: rk3399: Support module build
|
||
|
||
support CLK_OF_DECLARE and builtin_platform_driver_probe
|
||
double clk init method.
|
||
add module author, description and license to support building
|
||
Soc Rk3399 clock driver as module.
|
||
|
||
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
|
||
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200914022316.24045-1-zhangqing@rock-chips.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 70d839e2761d22eba6facdb3b65faea4d57f355d)
|
||
---
|
||
drivers/clk/rockchip/Kconfig | 2 +-
|
||
drivers/clk/rockchip/clk-rk3399.c | 56 +++++++++++++++++++++++++++++++++++++++
|
||
2 files changed, 57 insertions(+), 1 deletion(-)
|
||
|
||
diff --git a/drivers/clk/rockchip/Kconfig b/drivers/clk/rockchip/Kconfig
|
||
index 524b0e0df0a7..47cd6c5de837 100644
|
||
--- a/drivers/clk/rockchip/Kconfig
|
||
+++ b/drivers/clk/rockchip/Kconfig
|
||
@@ -71,7 +71,7 @@ config CLK_RK3368
|
||
Build the driver for RK3368 Clock Driver.
|
||
|
||
config CLK_RK3399
|
||
- bool "Rockchip RK3399 clock controller support"
|
||
+ tristate "Rockchip RK3399 clock controller support"
|
||
default y
|
||
help
|
||
Build the driver for RK3399 Clock Driver.
|
||
diff --git a/drivers/clk/rockchip/clk-rk3399.c b/drivers/clk/rockchip/clk-rk3399.c
|
||
index ce1d2446f142..7df2f1e00347 100644
|
||
--- a/drivers/clk/rockchip/clk-rk3399.c
|
||
+++ b/drivers/clk/rockchip/clk-rk3399.c
|
||
@@ -5,9 +5,11 @@
|
||
*/
|
||
|
||
#include <linux/clk-provider.h>
|
||
+#include <linux/module.h>
|
||
#include <linux/io.h>
|
||
#include <linux/of.h>
|
||
#include <linux/of_address.h>
|
||
+#include <linux/of_device.h>
|
||
#include <linux/platform_device.h>
|
||
#include <linux/regmap.h>
|
||
#include <dt-bindings/clock/rk3399-cru.h>
|
||
@@ -1600,3 +1602,57 @@ static void __init rk3399_pmu_clk_init(struct device_node *np)
|
||
rockchip_clk_of_add_provider(np, ctx);
|
||
}
|
||
CLK_OF_DECLARE(rk3399_cru_pmu, "rockchip,rk3399-pmucru", rk3399_pmu_clk_init);
|
||
+
|
||
+struct clk_rk3399_inits {
|
||
+ void (*inits)(struct device_node *np);
|
||
+};
|
||
+
|
||
+static const struct clk_rk3399_inits clk_rk3399_pmucru_init = {
|
||
+ .inits = rk3399_pmu_clk_init,
|
||
+};
|
||
+
|
||
+static const struct clk_rk3399_inits clk_rk3399_cru_init = {
|
||
+ .inits = rk3399_clk_init,
|
||
+};
|
||
+
|
||
+static const struct of_device_id clk_rk3399_match_table[] = {
|
||
+ {
|
||
+ .compatible = "rockchip,rk3399-cru",
|
||
+ .data = &clk_rk3399_cru_init,
|
||
+ }, {
|
||
+ .compatible = "rockchip,rk3399-pmucru",
|
||
+ .data = &clk_rk3399_pmucru_init,
|
||
+ },
|
||
+ { }
|
||
+};
|
||
+MODULE_DEVICE_TABLE(of, clk_rk3399_match_table);
|
||
+
|
||
+static int __init clk_rk3399_probe(struct platform_device *pdev)
|
||
+{
|
||
+ struct device_node *np = pdev->dev.of_node;
|
||
+ const struct of_device_id *match;
|
||
+ const struct clk_rk3399_inits *init_data;
|
||
+
|
||
+ match = of_match_device(clk_rk3399_match_table, &pdev->dev);
|
||
+ if (!match || !match->data)
|
||
+ return -EINVAL;
|
||
+
|
||
+ init_data = match->data;
|
||
+ if (init_data->inits)
|
||
+ init_data->inits(np);
|
||
+
|
||
+ return 0;
|
||
+}
|
||
+
|
||
+static struct platform_driver clk_rk3399_driver = {
|
||
+ .driver = {
|
||
+ .name = "clk-rk3399",
|
||
+ .of_match_table = clk_rk3399_match_table,
|
||
+ .suppress_bind_attrs = true,
|
||
+ },
|
||
+};
|
||
+builtin_platform_driver_probe(clk_rk3399_driver, clk_rk3399_probe);
|
||
+
|
||
+MODULE_DESCRIPTION("Rockchip RK3399 Clock Driver");
|
||
+MODULE_LICENSE("GPL");
|
||
+MODULE_ALIAS("platform:clk-rk3399");
|
||
|
||
From 2862d98b5f5d3682afe09bab8fc29c982e3ac0fe Mon Sep 17 00:00:00 2001
|
||
From: David Bauer <mail@david-bauer.net>
|
||
Date: Sun, 20 Sep 2020 17:45:27 +0200
|
||
Subject: [PATCH] dt-bindings: Add doc for FriendlyARM NanoPi R2S
|
||
|
||
Add devicetree binding documentation for the FriendlyARM NanoPi R2S.
|
||
|
||
Signed-off-by: David Bauer <mail@david-bauer.net>
|
||
Reviewed-by: Rob Herring <robh@kernel.org>
|
||
Link: https://lore.kernel.org/r/20200920154528.88185-1-mail@david-bauer.net
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 8cfcf3279419acbf2d2c471262bfb18d9e175fc9)
|
||
---
|
||
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 251c3ca22e1b..65b4cc2c63f7 100644
|
||
--- a/Documentation/devicetree/bindings/arm/rockchip.yaml
|
||
+++ b/Documentation/devicetree/bindings/arm/rockchip.yaml
|
||
@@ -104,6 +104,11 @@ properties:
|
||
- firefly,roc-rk3399-pc-mezzanine
|
||
- const: rockchip,rk3399
|
||
|
||
+ - description: FriendlyElec NanoPi R2S
|
||
+ items:
|
||
+ - const: friendlyarm,nanopi-r2s
|
||
+ - const: rockchip,rk3328
|
||
+
|
||
- description: FriendlyElec NanoPi4 series boards
|
||
items:
|
||
- enum:
|
||
|
||
From 6b865e0835b1517ed2e7d44feb819f83ce3bc138 Mon Sep 17 00:00:00 2001
|
||
From: David Bauer <mail@david-bauer.net>
|
||
Date: Sun, 20 Sep 2020 17:45:28 +0200
|
||
Subject: [PATCH] arm64: dts: rockchip: Add support for FriendlyARM NanoPi R2S
|
||
|
||
This adds support for the NanoPi R2S from FriendlyARM.
|
||
|
||
Rockchip RK3328 SoC
|
||
1GB DDR4 RAM
|
||
Gigabit Ethernet (WAN)
|
||
Gigabit Ethernet (USB3) (LAN)
|
||
USB 2.0 Host Port
|
||
MicroSD slot
|
||
Reset button
|
||
WAN - LAN - SYS LED
|
||
|
||
Signed-off-by: David Bauer <mail@david-bauer.net>
|
||
Link: https://lore.kernel.org/r/20200920154528.88185-2-mail@david-bauer.net
|
||
[adapted from sdmmc0m1_gpio to renamed sdmmc0m1_pin]
|
||
Reported-by: kernel test robot <lkp@intel.com>
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit f1ec83f880dbeaceb10d33c40c47aa1769b787e8)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/Makefile | 1 +
|
||
arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts | 368 +++++++++++++++++++++
|
||
2 files changed, 369 insertions(+)
|
||
create mode 100644 arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/Makefile b/arch/arm64/boot/dts/rockchip/Makefile
|
||
index d53efdf4cb5a..26661c7b736b 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/Makefile
|
||
+++ b/arch/arm64/boot/dts/rockchip/Makefile
|
||
@@ -6,6 +6,7 @@ dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3318-a95x-z2.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3326-odroid-go2.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-a1.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-evb.dtb
|
||
+dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-nanopi-r2s.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-rock64.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3328-roc-cc.dtb
|
||
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3368-evb-act8846.dtb
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts
|
||
new file mode 100644
|
||
index 000000000000..be7a31d81632
|
||
--- /dev/null
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3328-nanopi-r2s.dts
|
||
@@ -0,0 +1,368 @@
|
||
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||
+/*
|
||
+ * Copyright (c) 2020 David Bauer <mail@david-bauer.net>
|
||
+ */
|
||
+
|
||
+/dts-v1/;
|
||
+
|
||
+#include <dt-bindings/input/input.h>
|
||
+#include <dt-bindings/gpio/gpio.h>
|
||
+#include "rk3328.dtsi"
|
||
+
|
||
+/ {
|
||
+ model = "FriendlyElec NanoPi R2S";
|
||
+ compatible = "friendlyarm,nanopi-r2s", "rockchip,rk3328";
|
||
+
|
||
+ chosen {
|
||
+ stdout-path = "serial2:1500000n8";
|
||
+ };
|
||
+
|
||
+ gmac_clk: gmac-clock {
|
||
+ compatible = "fixed-clock";
|
||
+ clock-frequency = <125000000>;
|
||
+ clock-output-names = "gmac_clk";
|
||
+ #clock-cells = <0>;
|
||
+ };
|
||
+
|
||
+ keys {
|
||
+ compatible = "gpio-keys";
|
||
+ pinctrl-0 = <&reset_button_pin>;
|
||
+ pinctrl-names = "default";
|
||
+
|
||
+ reset {
|
||
+ label = "reset";
|
||
+ gpios = <&gpio0 RK_PA0 GPIO_ACTIVE_LOW>;
|
||
+ linux,code = <KEY_RESTART>;
|
||
+ debounce-interval = <50>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ leds {
|
||
+ compatible = "gpio-leds";
|
||
+ pinctrl-0 = <&lan_led_pin>, <&sys_led_pin>, <&wan_led_pin>;
|
||
+ pinctrl-names = "default";
|
||
+
|
||
+ lan_led: led-0 {
|
||
+ gpios = <&gpio2 RK_PB7 GPIO_ACTIVE_HIGH>;
|
||
+ label = "nanopi-r2s:green:lan";
|
||
+ };
|
||
+
|
||
+ sys_led: led-1 {
|
||
+ gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_HIGH>;
|
||
+ label = "nanopi-r2s:red:sys";
|
||
+ };
|
||
+
|
||
+ wan_led: led-2 {
|
||
+ gpios = <&gpio2 RK_PC2 GPIO_ACTIVE_HIGH>;
|
||
+ label = "nanopi-r2s:green:wan";
|
||
+ };
|
||
+ };
|
||
+
|
||
+ vcc_io_sdio: sdmmcio-regulator {
|
||
+ compatible = "regulator-gpio";
|
||
+ enable-active-high;
|
||
+ gpios = <&gpio1 RK_PD4 GPIO_ACTIVE_HIGH>;
|
||
+ pinctrl-0 = <&sdio_vcc_pin>;
|
||
+ pinctrl-names = "default";
|
||
+ regulator-name = "vcc_io_sdio";
|
||
+ regulator-always-on;
|
||
+ regulator-min-microvolt = <1800000>;
|
||
+ regulator-max-microvolt = <3300000>;
|
||
+ regulator-settling-time-us = <5000>;
|
||
+ regulator-type = "voltage";
|
||
+ startup-delay-us = <2000>;
|
||
+ states = <1800000 0x1
|
||
+ 3300000 0x0>;
|
||
+ vin-supply = <&vcc_io_33>;
|
||
+ };
|
||
+
|
||
+ vcc_sd: sdmmc-regulator {
|
||
+ compatible = "regulator-fixed";
|
||
+ gpio = <&gpio0 RK_PD6 GPIO_ACTIVE_LOW>;
|
||
+ pinctrl-0 = <&sdmmc0m1_pin>;
|
||
+ pinctrl-names = "default";
|
||
+ regulator-name = "vcc_sd";
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <3300000>;
|
||
+ regulator-max-microvolt = <3300000>;
|
||
+ vin-supply = <&vcc_io_33>;
|
||
+ };
|
||
+
|
||
+ vdd_5v: vdd-5v {
|
||
+ compatible = "regulator-fixed";
|
||
+ regulator-name = "vdd_5v";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <5000000>;
|
||
+ regulator-max-microvolt = <5000000>;
|
||
+ };
|
||
+};
|
||
+
|
||
+&cpu0 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu1 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu2 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&cpu3 {
|
||
+ cpu-supply = <&vdd_arm>;
|
||
+};
|
||
+
|
||
+&gmac2io {
|
||
+ assigned-clocks = <&cru SCLK_MAC2IO>, <&cru SCLK_MAC2IO_EXT>;
|
||
+ assigned-clock-parents = <&gmac_clk>, <&gmac_clk>;
|
||
+ clock_in_out = "input";
|
||
+ phy-handle = <&rtl8211e>;
|
||
+ phy-mode = "rgmii";
|
||
+ phy-supply = <&vcc_io_33>;
|
||
+ pinctrl-0 = <&rgmiim1_pins>;
|
||
+ pinctrl-names = "default";
|
||
+ rx_delay = <0x18>;
|
||
+ snps,aal;
|
||
+ tx_delay = <0x24>;
|
||
+ status = "okay";
|
||
+
|
||
+ mdio {
|
||
+ compatible = "snps,dwmac-mdio";
|
||
+ #address-cells = <1>;
|
||
+ #size-cells = <0>;
|
||
+
|
||
+ rtl8211e: ethernet-phy@1 {
|
||
+ reg = <1>;
|
||
+ pinctrl-0 = <ð_phy_reset_pin>;
|
||
+ pinctrl-names = "default";
|
||
+ reset-assert-us = <10000>;
|
||
+ reset-deassert-us = <50000>;
|
||
+ reset-gpios = <&gpio1 RK_PC2 GPIO_ACTIVE_LOW>;
|
||
+ };
|
||
+ };
|
||
+};
|
||
+
|
||
+&i2c1 {
|
||
+ status = "okay";
|
||
+
|
||
+ rk805: pmic@18 {
|
||
+ compatible = "rockchip,rk805";
|
||
+ reg = <0x18>;
|
||
+ interrupt-parent = <&gpio1>;
|
||
+ interrupts = <24 IRQ_TYPE_LEVEL_LOW>;
|
||
+ #clock-cells = <1>;
|
||
+ clock-output-names = "xin32k", "rk805-clkout2";
|
||
+ gpio-controller;
|
||
+ #gpio-cells = <2>;
|
||
+ pinctrl-0 = <&pmic_int_l>;
|
||
+ pinctrl-names = "default";
|
||
+ rockchip,system-power-controller;
|
||
+ wakeup-source;
|
||
+
|
||
+ vcc1-supply = <&vdd_5v>;
|
||
+ vcc2-supply = <&vdd_5v>;
|
||
+ vcc3-supply = <&vdd_5v>;
|
||
+ vcc4-supply = <&vdd_5v>;
|
||
+ vcc5-supply = <&vcc_io_33>;
|
||
+ vcc6-supply = <&vdd_5v>;
|
||
+
|
||
+ regulators {
|
||
+ vdd_log: DCDC_REG1 {
|
||
+ regulator-name = "vdd_log";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <712500>;
|
||
+ regulator-max-microvolt = <1450000>;
|
||
+ regulator-ramp-delay = <12500>;
|
||
+
|
||
+ regulator-state-mem {
|
||
+ regulator-on-in-suspend;
|
||
+ regulator-suspend-microvolt = <1000000>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ vdd_arm: DCDC_REG2 {
|
||
+ regulator-name = "vdd_arm";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <712500>;
|
||
+ regulator-max-microvolt = <1450000>;
|
||
+ regulator-ramp-delay = <12500>;
|
||
+
|
||
+ regulator-state-mem {
|
||
+ regulator-on-in-suspend;
|
||
+ regulator-suspend-microvolt = <950000>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ vcc_ddr: DCDC_REG3 {
|
||
+ regulator-name = "vcc_ddr";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+
|
||
+ regulator-state-mem {
|
||
+ regulator-on-in-suspend;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ vcc_io_33: DCDC_REG4 {
|
||
+ regulator-name = "vcc_io_33";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <3300000>;
|
||
+ regulator-max-microvolt = <3300000>;
|
||
+
|
||
+ regulator-state-mem {
|
||
+ regulator-on-in-suspend;
|
||
+ regulator-suspend-microvolt = <3300000>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ vcc_18: LDO_REG1 {
|
||
+ regulator-name = "vcc_18";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <1800000>;
|
||
+ regulator-max-microvolt = <1800000>;
|
||
+
|
||
+ regulator-state-mem {
|
||
+ regulator-on-in-suspend;
|
||
+ regulator-suspend-microvolt = <1800000>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ vcc18_emmc: LDO_REG2 {
|
||
+ regulator-name = "vcc18_emmc";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <1800000>;
|
||
+ regulator-max-microvolt = <1800000>;
|
||
+
|
||
+ regulator-state-mem {
|
||
+ regulator-on-in-suspend;
|
||
+ regulator-suspend-microvolt = <1800000>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ vdd_10: LDO_REG3 {
|
||
+ regulator-name = "vdd_10";
|
||
+ regulator-always-on;
|
||
+ regulator-boot-on;
|
||
+ regulator-min-microvolt = <1000000>;
|
||
+ regulator-max-microvolt = <1000000>;
|
||
+
|
||
+ regulator-state-mem {
|
||
+ regulator-on-in-suspend;
|
||
+ regulator-suspend-microvolt = <1000000>;
|
||
+ };
|
||
+ };
|
||
+ };
|
||
+ };
|
||
+};
|
||
+
|
||
+&io_domains {
|
||
+ pmuio-supply = <&vcc_io_33>;
|
||
+ vccio1-supply = <&vcc_io_33>;
|
||
+ vccio2-supply = <&vcc18_emmc>;
|
||
+ vccio3-supply = <&vcc_io_sdio>;
|
||
+ vccio4-supply = <&vcc_18>;
|
||
+ vccio5-supply = <&vcc_io_33>;
|
||
+ vccio6-supply = <&vcc_io_33>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&pinctrl {
|
||
+ button {
|
||
+ reset_button_pin: reset-button-pin {
|
||
+ rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ ethernet-phy {
|
||
+ eth_phy_reset_pin: eth-phy-reset-pin {
|
||
+ rockchip,pins = <1 RK_PC2 RK_FUNC_GPIO &pcfg_pull_down>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ leds {
|
||
+ lan_led_pin: lan-led-pin {
|
||
+ rockchip,pins = <2 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+
|
||
+ sys_led_pin: sys-led-pin {
|
||
+ rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+
|
||
+ wan_led_pin: wan-led-pin {
|
||
+ rockchip,pins = <2 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ pmic {
|
||
+ pmic_int_l: pmic-int-l {
|
||
+ rockchip,pins = <1 RK_PD0 RK_FUNC_GPIO &pcfg_pull_up>;
|
||
+ };
|
||
+ };
|
||
+
|
||
+ sd {
|
||
+ sdio_vcc_pin: sdio-vcc-pin {
|
||
+ rockchip,pins = <1 RK_PD4 RK_FUNC_GPIO &pcfg_pull_up>;
|
||
+ };
|
||
+ };
|
||
+};
|
||
+
|
||
+&pwm2 {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&sdmmc {
|
||
+ bus-width = <4>;
|
||
+ cap-sd-highspeed;
|
||
+ disable-wp;
|
||
+ pinctrl-0 = <&sdmmc0_clk>, <&sdmmc0_cmd>, <&sdmmc0_dectn>, <&sdmmc0_bus4>;
|
||
+ pinctrl-names = "default";
|
||
+ sd-uhs-sdr12;
|
||
+ sd-uhs-sdr25;
|
||
+ sd-uhs-sdr50;
|
||
+ sd-uhs-sdr104;
|
||
+ vmmc-supply = <&vcc_sd>;
|
||
+ vqmmc-supply = <&vcc_io_sdio>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&tsadc {
|
||
+ rockchip,hw-tshut-mode = <0>;
|
||
+ rockchip,hw-tshut-polarity = <0>;
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&u2phy {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&u2phy_host {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&u2phy_otg {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&uart2 {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&usb20_otg {
|
||
+ status = "okay";
|
||
+ dr_mode = "host";
|
||
+};
|
||
+
|
||
+&usb_host0_ehci {
|
||
+ status = "okay";
|
||
+};
|
||
+
|
||
+&usb_host0_ohci {
|
||
+ status = "okay";
|
||
+};
|
||
|
||
From f18092b21f3ea3ed7d134b274c64c8edde1fcb30 Mon Sep 17 00:00:00 2001
|
||
From: Artem Lapkin <email2tema@gmail.com>
|
||
Date: Wed, 23 Sep 2020 21:08:22 +0800
|
||
Subject: [PATCH] arm64: dts: rockchip: add spiflash node to rk3399-khadas-edge
|
||
|
||
The Khadas Edge Boards uses winbond - w25q128 spi flash with 104Mhz
|
||
|
||
Signed-off-by: Artem Lapkin <art@khadas.com>
|
||
Link: https://lore.kernel.org/r/20200923130823.1612533-2-art@khadas.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 5d71f44569941386b419398463166fdf1785f4e2)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi | 10 ++++++++++
|
||
1 file changed, 10 insertions(+)
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi
|
||
index e36837c04dc7..c67420578fac 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi
|
||
@@ -690,6 +690,16 @@
|
||
status = "okay";
|
||
};
|
||
|
||
+&spi1 {
|
||
+ status = "okay";
|
||
+
|
||
+ spiflash: flash@0 {
|
||
+ compatible = "winbond,w25q128fw", "jedec,spi-nor";
|
||
+ reg = <0>;
|
||
+ spi-max-frequency = <104000000>;
|
||
+ };
|
||
+};
|
||
+
|
||
&tcphy0 {
|
||
status = "okay";
|
||
};
|
||
|
||
From e2cad982d40449e0839c6de164a34a1d2e23d694 Mon Sep 17 00:00:00 2001
|
||
From: Artem Lapkin <email2tema@gmail.com>
|
||
Date: Wed, 23 Sep 2020 21:08:23 +0800
|
||
Subject: [PATCH] arm64: dts: rockchip: add ir-receiver node to
|
||
rk3399-khadas-edge
|
||
|
||
add missed ir-receiver and ir_rx pinctl nodes to rk3399-khadas-edge
|
||
Khadas Edge board uses gpio-ir-receiver on RK_PB6 gpio
|
||
|
||
Signed-off-by: Artem Lapkin <art@khadas.com>
|
||
Link: https://lore.kernel.org/r/20200923130823.1612533-3-art@khadas.com
|
||
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
||
(cherry picked from commit 30a9a8c16865d37bfc0f1859a398ba1b24eec569)
|
||
---
|
||
arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi | 14 ++++++++++++++
|
||
1 file changed, 14 insertions(+)
|
||
|
||
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi
|
||
index c67420578fac..635afdd99122 100644
|
||
--- a/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi
|
||
+++ b/arch/arm64/boot/dts/rockchip/rk3399-khadas-edge.dtsi
|
||
@@ -138,6 +138,14 @@
|
||
};
|
||
};
|
||
|
||
+ ir-receiver {
|
||
+ compatible = "gpio-ir-receiver";
|
||
+ gpios = <&gpio1 RK_PB6 GPIO_ACTIVE_LOW>;
|
||
+ linux,rc-map-name = "rc-khadas";
|
||
+ pinctrl-names = "default";
|
||
+ pinctrl-0 = <&ir_rx>;
|
||
+ };
|
||
+
|
||
leds {
|
||
compatible = "gpio-leds";
|
||
pinctrl-names = "default";
|
||
@@ -585,6 +593,12 @@
|
||
};
|
||
};
|
||
|
||
+ ir {
|
||
+ ir_rx: ir-rx {
|
||
+ rockchip,pins = <1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
+ };
|
||
+ };
|
||
+
|
||
leds {
|
||
sys_led_pin: sys-led-pin {
|
||
rockchip,pins = <0 RK_PA6 RK_FUNC_GPIO &pcfg_pull_none>;
|
||
|
||
From d9ffbaa89722fee3ef963646ea2423ac84f78854 Mon Sep 17 00:00:00 2001
|
||
From: Stephen Boyd <sboyd@kernel.org>
|
||
Date: Wed, 23 Sep 2020 17:41:44 -0700
|
||
Subject: [PATCH] clk: rockchip: Initialize hw to error to avoid undefined
|
||
behavior
|
||
|
||
We can get down to this return value from ERR_CAST() without
|
||
initializing hw. Set it to -ENOMEM so that we always return something
|
||
sane.
|
||
|
||
Fixes the following smatch warning:
|
||
|
||
drivers/clk/rockchip/clk-half-divider.c:228 rockchip_clk_register_halfdiv() error: uninitialized symbol 'hw'.
|
||
drivers/clk/rockchip/clk-half-divider.c:228 rockchip_clk_register_halfdiv() warn: passing zero to 'ERR_CAST'
|
||
|
||
Cc: Elaine Zhang <zhangqing@rock-chips.com>
|
||
Cc: Heiko Stuebner <heiko@sntech.de>
|
||
Fixes: 956060a52795 ("clk: rockchip: add support for half divider")
|
||
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
|
||
(cherry picked from commit f8ac4db0e23c15baa3f379d4f7e007589d7710ed)
|
||
---
|
||
drivers/clk/rockchip/clk-half-divider.c | 2 +-
|
||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
||
diff --git a/drivers/clk/rockchip/clk-half-divider.c b/drivers/clk/rockchip/clk-half-divider.c
|
||
index e97fd3dfbae7..ccd5c270c213 100644
|
||
--- a/drivers/clk/rockchip/clk-half-divider.c
|
||
+++ b/drivers/clk/rockchip/clk-half-divider.c
|
||
@@ -166,7 +166,7 @@ struct clk *rockchip_clk_register_halfdiv(const char *name,
|
||
unsigned long flags,
|
||
spinlock_t *lock)
|
||
{
|
||
- struct clk_hw *hw;
|
||
+ struct clk_hw *hw = ERR_PTR(-ENOMEM);
|
||
struct clk_mux *mux = NULL;
|
||
struct clk_gate *gate = NULL;
|
||
struct clk_divider *div = NULL;
|
||
|
||
From aadd7a83a8a1e799653d9df0cc99bb0633515fbf Mon Sep 17 00:00:00 2001
|
||
From: Vinod Koul <vkoul@kernel.org>
|
||
Date: Wed, 30 Sep 2020 17:47:35 +0530
|
||
Subject: [PATCH] dmaengine: pl330: fix argument for tasklet
|
||
|
||
Commit 59cd818763e8 ("dmaengine: fsl: convert tasklets to use new
|
||
tasklet_setup() API") converted the pl330 driver to use new tasklet
|
||
functions but missed that driver calls the tasklet function directly as
|
||
well, so update it.
|
||
|
||
Fixes: 59cd818763e8 ("dmaengine: fsl: convert tasklets to use new tasklet_setup() API")
|
||
Reported-by: kernel test robot <lkp@intel.com>
|
||
Link: https://lore.kernel.org/r/20200930121735.49699-1-vkoul@kernel.org
|
||
Signed-off-by: Vinod Koul <vkoul@kernel.org>
|
||
(cherry picked from commit 86ae924a91a4a4297ad9f47e131f74b1dab6cb7a)
|
||
---
|
||
drivers/dma/pl330.c | 2 +-
|
||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||
|
||
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
|
||
index d98fb318dd2d..e9f0101d92fa 100644
|
||
--- a/drivers/dma/pl330.c
|
||
+++ b/drivers/dma/pl330.c
|
||
@@ -2484,7 +2484,7 @@ static void pl330_issue_pending(struct dma_chan *chan)
|
||
list_splice_tail_init(&pch->submitted_list, &pch->work_list);
|
||
spin_unlock_irqrestore(&pch->lock, flags);
|
||
|
||
- pl330_tasklet((unsigned long)pch);
|
||
+ pl330_tasklet(&pch->task);
|
||
}
|
||
|
||
/*
|