mirror of
https://github.com/libretro/Lakka-LibreELEC.git
synced 2024-11-24 10:16:18 +00:00
a798e0b5d8
Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
100 lines
2.5 KiB
Diff
100 lines
2.5 KiB
Diff
From 9aac0fbe0ef9eb783562b52461504fd221efe92b Mon Sep 17 00:00:00 2001
|
|
From: Christian Hewitt <christianshewitt@gmail.com>
|
|
Date: Tue, 7 Mar 2023 13:17:16 +0000
|
|
Subject: [PATCH 119/120] WIP: arm64: dts: meson: add WiFi/BT support to
|
|
BananaPi M5
|
|
|
|
The BPI-M5 has an optional RTL8822CS WiFi/BT mezzanine board. Describe
|
|
the board but mark the sd_mmc_a and uart_A nodes disabled so they can
|
|
be enabled via overlay or fdtput when the baord is connected.
|
|
|
|
Signed-off-by: Christian Hewitt <christianshewitt@gmail.com>
|
|
---
|
|
.../dts/amlogic/meson-sm1-bananapi-m5.dts | 59 +++++++++++++++++++
|
|
1 file changed, 59 insertions(+)
|
|
|
|
diff --git a/arch/arm64/boot/dts/amlogic/meson-sm1-bananapi-m5.dts b/arch/arm64/boot/dts/amlogic/meson-sm1-bananapi-m5.dts
|
|
index 34b3238ee0a0..0b434572a789 100644
|
|
--- a/arch/arm64/boot/dts/amlogic/meson-sm1-bananapi-m5.dts
|
|
+++ b/arch/arm64/boot/dts/amlogic/meson-sm1-bananapi-m5.dts
|
|
@@ -25,6 +25,20 @@ cvbs_connector_in: endpoint {
|
|
};
|
|
};
|
|
|
|
+ sdio_pwrseq: sdio-pwrseq {
|
|
+ compatible = "mmc-pwrseq-simple";
|
|
+ reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>;
|
|
+ clocks = <&wifi32k>;
|
|
+ clock-names = "ext_clock";
|
|
+ };
|
|
+
|
|
+ wifi32k: wifi32k {
|
|
+ compatible = "pwm-clock";
|
|
+ #clock-cells = <0>;
|
|
+ clock-frequency = <32768>;
|
|
+ pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */
|
|
+ };
|
|
+
|
|
sound {
|
|
compatible = "amlogic,axg-sound-card";
|
|
model = "BPI-M5";
|
|
@@ -173,6 +187,36 @@ &frddr_c {
|
|
status = "okay";
|
|
};
|
|
|
|
+/* SDIO */
|
|
+&sd_emmc_a {
|
|
+ /* enable if WiFi/BT board connected */
|
|
+ status = "disabled";
|
|
+ pinctrl-0 = <&sdio_pins>;
|
|
+ pinctrl-1 = <&sdio_clk_gate_pins>;
|
|
+ pinctrl-names = "default", "clk-gate";
|
|
+ #address-cells = <1>;
|
|
+ #size-cells = <0>;
|
|
+
|
|
+ bus-width = <4>;
|
|
+ sd-uhs-sdr104;
|
|
+ max-frequency = <50000000>;
|
|
+
|
|
+ non-removable;
|
|
+ disable-wp;
|
|
+
|
|
+ /* WiFi firmware requires power in suspend */
|
|
+ keep-power-in-suspend;
|
|
+
|
|
+ mmc-pwrseq = <&sdio_pwrseq>;
|
|
+
|
|
+ vmmc-supply = <&vddao_3v3>;
|
|
+ vqmmc-supply = <&vddao_1v8>;
|
|
+
|
|
+ rtl8822cs: wifi@1 {
|
|
+ reg = <1>;
|
|
+ };
|
|
+};
|
|
+
|
|
&tdmif_b {
|
|
status = "okay";
|
|
};
|
|
@@ -220,3 +264,18 @@ &toddr_b {
|
|
&toddr_c {
|
|
status = "okay";
|
|
};
|
|
+
|
|
+&uart_A {
|
|
+ /* enable if WiFi/BT board connected */
|
|
+ status = "disabled";
|
|
+ pinctrl-0 = <&uart_a_pins>, <&uart_a_cts_rts_pins>;
|
|
+ pinctrl-names = "default";
|
|
+ uart-has-rtscts;
|
|
+
|
|
+ bluetooth {
|
|
+ compatible = "realtek,rtl8822cs-bt";
|
|
+ enable-gpios = <&gpio GPIOX_17 GPIO_ACTIVE_HIGH>;
|
|
+ host-wake-gpios = <&gpio GPIOX_19 GPIO_ACTIVE_HIGH>;
|
|
+ device-wake-gpios = <&gpio GPIOX_18 GPIO_ACTIVE_HIGH>;
|
|
+ };
|
|
+};
|
|
--
|
|
2.34.1
|
|
|