Commit 2d7481d9 authored by Alex Bee's avatar Alex Bee Committed by sanglipeng
Browse files

arm64: dts: rockchip: add ES8316 codec for ROCK Pi 4

stable inclusion
from stable-v5.10.192
commit 77806f63c317cab3392f3ab7d4c6d392fb4a5da9
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I933RF

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=77806f63c317cab3392f3ab7d4c6d392fb4a5da9



--------------------------------

[ Upstream commit 65bd2b8b ]

ROCK Pi 4 boards have the codec connected to i2s0 and it is accessible
via i2c1 address 0x11.
Add an audio-graph-card for it.

Signed-off-by: default avatarAlex Bee <knaerzche@gmail.com>
Link: https://lore.kernel.org/r/20210618181256.27992-5-knaerzche@gmail.com


Signed-off-by: default avatarHeiko Stuebner <heiko@sntech.de>
Stable-dep-of: cee57275 ("arm64: dts: rockchip: Disable HS400 for eMMC on ROCK Pi 4")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarsanglipeng <sanglipeng1@jd.com>
parent cd8c34a8
Loading
Loading
Loading
Loading
+28 −0
Original line number Diff line number Diff line
@@ -31,6 +31,12 @@
		reset-gpios = <&gpio0 RK_PB2 GPIO_ACTIVE_LOW>;
	};

	sound {
		compatible = "audio-graph-card";
		label = "Analog";
		dais = <&i2s0_p0>;
	};

	vcc12v_dcin: dc-12v {
		compatible = "regulator-fixed";
		regulator-name = "vcc12v_dcin";
@@ -417,6 +423,20 @@
	i2c-scl-rising-time-ns = <300>;
	i2c-scl-falling-time-ns = <15>;
	status = "okay";

	es8316: codec@11 {
		compatible = "everest,es8316";
		reg = <0x11>;
		clocks = <&cru SCLK_I2S_8CH_OUT>;
		clock-names = "mclk";
		#sound-dai-cells = <0>;

		port {
			es8316_p0_0: endpoint {
				remote-endpoint = <&i2s0_p0_0>;
			};
		};
	};
};

&i2c3 {
@@ -435,6 +455,14 @@
	rockchip,playback-channels = <8>;
	rockchip,capture-channels = <8>;
	status = "okay";

	i2s0_p0: port {
		i2s0_p0_0: endpoint {
			dai-format = "i2s";
			mclk-fs = <256>;
			remote-endpoint = <&es8316_p0_0>;
		};
	};
};

&i2s1 {