build/patch/kernel/archive/rockchip64-6.1/overlays-11-add-rk3318-box-led-conf4.patch

87 lines
2.7 KiB
Diff

From 9e2a9f208da921fa6e72e75d9c4b0d259f0002d9 Mon Sep 17 00:00:00 2001
From: Paolo Sabatino <paolo.sabatino@gmail.com>
Date: Sat, 8 Oct 2022 20:20:41 +0000
Subject: [PATCH] add rk3318-box-led-conf4 overlay
---
arch/arm64/boot/dts/rockchip/overlay/Makefile | 1 +
.../rockchip/overlay/README.rockchip-overlays | 4 ++
.../overlay/rockchip-rk3318-box-led-conf4.dts | 38 +++++++++++++++++++
3 files changed, 43 insertions(+)
create mode 100644 arch/arm64/boot/dts/rockchip/overlay/rockchip-rk3318-box-led-conf4.dts
diff --git a/arch/arm64/boot/dts/rockchip/overlay/Makefile b/arch/arm64/boot/dts/rockchip/overlay/Makefile
index f11aa6d57449..340f88be014b 100644
--- a/arch/arm64/boot/dts/rockchip/overlay/Makefile
+++ b/arch/arm64/boot/dts/rockchip/overlay/Makefile
@@ -14,6 +14,7 @@ dtbo-$(CONFIG_ARCH_ROCKCHIP) += \
rockchip-rk3318-box-led-conf1.dtbo \
rockchip-rk3318-box-led-conf2.dtbo \
rockchip-rk3318-box-led-conf3.dtbo \
+ rockchip-rk3318-box-led-conf4.dtbo \
rockchip-rk3318-box-emmc-ddr.dtbo \
rockchip-rk3318-box-wlan-ap6334.dtbo \
rockchip-rk3318-box-wlan-ext.dtbo \
diff --git a/arch/arm64/boot/dts/rockchip/overlay/README.rockchip-overlays b/arch/arm64/boot/dts/rockchip/overlay/README.rockchip-overlays
index 27f945d38e24..b3121afd5a63 100644
--- a/arch/arm64/boot/dts/rockchip/overlay/README.rockchip-overlays
+++ b/arch/arm64/boot/dts/rockchip/overlay/README.rockchip-overlays
@@ -136,6 +136,10 @@ has an integrated PMIC (RK805). The dtbo is very important to achieve
1.3 Ghz speed for CPU and stable voltages for other parts of the
system. Also enables gpio leds and keys.
+### rk3318-box-led-conf4
+
+Generic rk3318-box configuration but with sdio chip on sdmmc-ext connector
+
### rk3318-box-emmc-ddr
Activates eMMC DDR capability for rk3318 tv box boards. Probably all the eMMC chips
diff --git a/arch/arm64/boot/dts/rockchip/overlay/rockchip-rk3318-box-led-conf4.dts b/arch/arm64/boot/dts/rockchip/overlay/rockchip-rk3318-box-led-conf4.dts
new file mode 100644
index 000000000000..5d60f51069d8
--- /dev/null
+++ b/arch/arm64/boot/dts/rockchip/overlay/rockchip-rk3318-box-led-conf4.dts
@@ -0,0 +1,38 @@
+/dts-v1/;
+/plugin/;
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/pinctrl/rockchip.h>
+
+/**
+ * Generic rk3318 board with sdio bus on sdmmc_ext connector
+ */
+
+&gpio_led {
+
+ working {
+ gpios = <&gpio2 RK_PC7 GPIO_ACTIVE_HIGH>;
+ linux,default-trigger = "mmc2";
+ };
+
+};
+
+/*
+ * Following section enables the sdio bus on sdmmc_ext controller
+ */
+&sdio {
+ /delete-property/ mmc-pwrseq;
+ status = "disabled";
+};
+
+&sdio_ext {
+ rockchip,default-sample-phase = <112>;
+ sd-uhs-sdr50;
+ mmc-pwrseq = <&sdio_pwrseq>;
+ status = "okay";
+};
+
+&sdmmc_ext {
+ status = "disabled";
+};
--
2.34.1