* Add ODROID-M1 board support * Add Rockchip kernel config for ODROID-M1 Kernel defconfig for Rockchip is based on Armbian kernel defconfig from config/kernel/linux-rk3568-odroid-edge.config (git hash 95c829f9e664). * Add U-Boot/Kernel patches * Add Rockchip blob support Add package which provides Rockchip TPL and ATF firmware binaries. * Use latest U-Boot for ODROID-M1 * Fix Rockchip blob support * Update defconfig * Use GPT by default * Create uboot partition to support non-recovery boot * Enable eMMC boot in U-Boot SPL * Drop unnecessary mmc device selection Distro boot already activates the right mmc device. The extra selection seems to actually cause problems for eMMC boot. * Make sure driver for eMMC is built-in * Use odroid-m1 as Supervisor machine * Add ODROID-M1 to CI pipeline and issue template * Bump to Linux 6.1.16
103 lines
3.1 KiB
Diff
103 lines
3.1 KiB
Diff
From ae25f92a09abb7dd16a9ad3b74e0c105b385f214 Mon Sep 17 00:00:00 2001
|
|
Message-Id: <ae25f92a09abb7dd16a9ad3b74e0c105b385f214.1678107917.git.stefan@agner.ch>
|
|
In-Reply-To: <d388735d551e09b00317a509859fca51776b9826.1678107917.git.stefan@agner.ch>
|
|
References: <d388735d551e09b00317a509859fca51776b9826.1678107917.git.stefan@agner.ch>
|
|
From: Aurelien Jarno <aurelien@aurel32.net>
|
|
Date: Fri, 30 Sep 2022 07:12:38 +0200
|
|
Subject: [PATCH] arm64: dts: rockchip: Add analog audio on ODROID-M1
|
|
|
|
On the ODROID-M1, the I2S1 TDM controller is connected to the rk809
|
|
codec in I2S mode. It is used to provide a stereo headphones output and
|
|
a mono speaker output. A GPIO with an external pullup is used as an
|
|
headphone detection input.
|
|
|
|
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
Tested-by: Dan Johansen <strit@manjaro.org>
|
|
Link: https://lore.kernel.org/r/20220930051246.391614-6-aurelien@aurel32.net
|
|
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
|
|
---
|
|
.../boot/dts/rockchip/rk3568-odroid-m1.dts | 43 ++++++++++++++++++-
|
|
1 file changed, 42 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts b/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts
|
|
index 94e839c9afab..634c1bd80b4e 100644
|
|
--- a/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts
|
|
+++ b/arch/arm64/boot/dts/rockchip/rk3568-odroid-m1.dts
|
|
@@ -59,6 +59,31 @@ led_work: led-1 {
|
|
};
|
|
};
|
|
|
|
+ rk809-sound {
|
|
+ compatible = "simple-audio-card";
|
|
+ pinctrl-names = "default";
|
|
+ pinctrl-0 = <&hp_det_pin>;
|
|
+ simple-audio-card,name = "Analog RK817";
|
|
+ simple-audio-card,format = "i2s";
|
|
+ simple-audio-card,hp-det-gpio = <&gpio0 RK_PB0 GPIO_ACTIVE_HIGH>;
|
|
+ simple-audio-card,mclk-fs = <256>;
|
|
+ simple-audio-card,widgets =
|
|
+ "Headphone", "Headphones",
|
|
+ "Speaker", "Speaker";
|
|
+ simple-audio-card,routing =
|
|
+ "Headphones", "HPOL",
|
|
+ "Headphones", "HPOR",
|
|
+ "Speaker", "SPKO";
|
|
+
|
|
+ simple-audio-card,cpu {
|
|
+ sound-dai = <&i2s1_8ch>;
|
|
+ };
|
|
+
|
|
+ simple-audio-card,codec {
|
|
+ sound-dai = <&rk809>;
|
|
+ };
|
|
+ };
|
|
+
|
|
vcc3v3_sys: vcc3v3-sys-regulator {
|
|
compatible = "regulator-fixed";
|
|
regulator-name = "vcc3v3_sys";
|
|
@@ -131,10 +156,15 @@ rk809: pmic@20 {
|
|
reg = <0x20>;
|
|
interrupt-parent = <&gpio0>;
|
|
interrupts = <RK_PA3 IRQ_TYPE_LEVEL_LOW>;
|
|
+ assigned-clocks = <&cru I2S1_MCLKOUT_TX>;
|
|
+ assigned-clock-parents = <&cru CLK_I2S1_8CH_TX>;
|
|
#clock-cells = <1>;
|
|
+ clock-names = "mclk";
|
|
+ clocks = <&cru I2S1_MCLKOUT_TX>;
|
|
pinctrl-names = "default";
|
|
- pinctrl-0 = <&pmic_int_l>;
|
|
+ pinctrl-0 = <&pmic_int_l>, <&i2s1m0_mclk>;
|
|
rockchip,system-power-controller;
|
|
+ #sound-dai-cells = <0>;
|
|
vcc1-supply = <&vcc3v3_sys>;
|
|
vcc2-supply = <&vcc3v3_sys>;
|
|
vcc3-supply = <&vcc3v3_sys>;
|
|
@@ -340,6 +370,11 @@ regulator-state-mem {
|
|
};
|
|
};
|
|
|
|
+&i2s1_8ch {
|
|
+ rockchip,trcm-sync-tx-only;
|
|
+ status = "okay";
|
|
+};
|
|
+
|
|
&mdio0 {
|
|
rgmii_phy0: ethernet-phy@0 {
|
|
compatible = "ethernet-phy-ieee802.3-c22";
|
|
@@ -379,6 +414,12 @@ pmic_int_l: pmic-int-l {
|
|
rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>;
|
|
};
|
|
};
|
|
+
|
|
+ rk809 {
|
|
+ hp_det_pin: hp-det-pin {
|
|
+ rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>;
|
|
+ };
|
|
+ };
|
|
};
|
|
|
|
&pmu_io_domains {
|
|
--
|
|
2.39.2
|
|
|