* [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
@ 2024-08-28 7:47 Jonathan Liu
2024-08-28 12:51 ` Rob Herring (Arm)
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Jonathan Liu @ 2024-08-28 7:47 UTC (permalink / raw)
To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Heiko Stuebner
Cc: FUKAUMI Naoki, Jonathan Liu, devicetree, linux-arm-kernel,
linux-rockchip, linux-kernel
This adds the necessary device tree changes to enable analog audio
output for the 3.5 mm TRS headphone jack on the Radxa ROCK 4C+ with
its RK809 audio codec.
Signed-off-by: Jonathan Liu <net147@gmail.com>
---
.../boot/dts/rockchip/rk3399-rock-4c-plus.dts | 46 ++++++++++++++++++-
1 file changed, 45 insertions(+), 1 deletion(-)
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dts b/arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dts
index d4b4dced3e39..14453b286446 100644
--- a/arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dts
+++ b/arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dts
@@ -52,6 +52,21 @@ led-1 {
};
};
+ rk809-sound {
+ compatible = "simple-audio-card";
+ simple-audio-card,format = "i2s";
+ simple-audio-card,name = "Analog RK809";
+ simple-audio-card,mclk-fs = <256>;
+
+ simple-audio-card,cpu {
+ sound-dai = <&i2s0>;
+ };
+
+ simple-audio-card,codec {
+ sound-dai = <&rk809>;
+ };
+ };
+
sdio_pwrseq: sdio-pwrseq {
compatible = "mmc-pwrseq-simple";
clocks = <&rk809 1>;
@@ -200,10 +215,13 @@ rk809: pmic@20 {
interrupt-parent = <&gpio1>;
interrupts = <RK_PC5 IRQ_TYPE_LEVEL_LOW>;
#clock-cells = <1>;
+ clock-names = "mclk";
+ clocks = <&cru SCLK_I2S_8CH_OUT>;
clock-output-names = "rk808-clkout1", "rk808-clkout2";
pinctrl-names = "default";
- pinctrl-0 = <&pmic_int_l>;
+ pinctrl-0 = <&pmic_int_l>, <&i2s_8ch_mclk>;
rockchip,system-power-controller;
+ #sound-dai-cells = <0>;
wakeup-source;
vcc1-supply = <&vcc5v0_sys>;
@@ -445,6 +463,10 @@ &i2c3 {
status = "okay";
};
+&i2s0 {
+ status = "okay";
+};
+
&i2s2 {
status = "okay";
};
@@ -472,6 +494,28 @@ bt_wake_l: bt-wake-l {
};
};
+ i2s0 {
+ i2s0_8ch_bus: i2s0-8ch-bus {
+ rockchip,pins =
+ <3 RK_PD0 1 &pcfg_pull_none>,
+ <3 RK_PD2 1 &pcfg_pull_none>,
+ <3 RK_PD3 1 &pcfg_pull_none>,
+ <3 RK_PD7 1 &pcfg_pull_none>;
+ };
+
+ i2s0_8ch_bus_bclk_off: i2s0-8ch-bus-bclk-off {
+ rockchip,pins =
+ <3 RK_PD0 RK_FUNC_GPIO &pcfg_pull_none>,
+ <3 RK_PD2 1 &pcfg_pull_none>,
+ <3 RK_PD3 1 &pcfg_pull_none>,
+ <3 RK_PD7 1 &pcfg_pull_none>;
+ };
+
+ i2s_8ch_mclk: i2s-8ch-mclk {
+ rockchip,pins = <4 RK_PA0 1 &pcfg_pull_none>;
+ };
+ };
+
leds {
user_led1: user-led1 {
rockchip,pins = <3 RK_PD4 RK_FUNC_GPIO &pcfg_pull_none>;
--
2.46.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
2024-08-28 7:47 [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+ Jonathan Liu
@ 2024-08-28 12:51 ` Rob Herring (Arm)
2024-08-28 13:03 ` Heiko Stübner
2024-08-28 12:56 ` Heiko Stuebner
2024-08-28 13:00 ` Heiko Stübner
2 siblings, 1 reply; 7+ messages in thread
From: Rob Herring (Arm) @ 2024-08-28 12:51 UTC (permalink / raw)
To: Jonathan Liu
Cc: Conor Dooley, Krzysztof Kozlowski, Heiko Stuebner, devicetree,
linux-kernel, FUKAUMI Naoki, linux-arm-kernel, linux-rockchip
On Wed, 28 Aug 2024 17:47:53 +1000, Jonathan Liu wrote:
> This adds the necessary device tree changes to enable analog audio
> output for the 3.5 mm TRS headphone jack on the Radxa ROCK 4C+ with
> its RK809 audio codec.
>
> Signed-off-by: Jonathan Liu <net147@gmail.com>
> ---
> .../boot/dts/rockchip/rk3399-rock-4c-plus.dts | 46 ++++++++++++++++++-
> 1 file changed, 45 insertions(+), 1 deletion(-)
>
My bot found new DTB warnings on the .dts files added or changed in this
series.
Some warnings may be from an existing SoC .dtsi. Or perhaps the warnings
are fixed by another series. Ultimately, it is up to the platform
maintainer whether these warnings are acceptable or not. No need to reply
unless the platform maintainer has comments.
If you already ran DT checks and didn't see these error(s), then
make sure dt-schema is up to date:
pip3 install dtschema --upgrade
New warnings running 'make CHECK_DTBS=y rockchip/rk3399-rock-4c-plus.dtb' for 20240828074755.1320692-1-net147@gmail.com:
arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dtb: pmic: vsel1-gpio: {'rockchip,pins': [[1, 17, 0, 194]], 'phandle': 138} is not of type 'array'
from schema $id: http://devicetree.org/schemas/gpio/gpio-consumer.yaml#
arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dtb: pmic: vsel2-gpio: {'rockchip,pins': [[1, 14, 0, 194]], 'phandle': 139} is not of type 'array'
from schema $id: http://devicetree.org/schemas/gpio/gpio-consumer.yaml#
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
2024-08-28 7:47 [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+ Jonathan Liu
2024-08-28 12:51 ` Rob Herring (Arm)
@ 2024-08-28 12:56 ` Heiko Stuebner
2024-08-28 13:00 ` Heiko Stübner
2 siblings, 0 replies; 7+ messages in thread
From: Heiko Stuebner @ 2024-08-28 12:56 UTC (permalink / raw)
To: Rob Herring, Krzysztof Kozlowski, Jonathan Liu, Conor Dooley
Cc: Heiko Stuebner, linux-arm-kernel, linux-rockchip, linux-kernel,
FUKAUMI Naoki, devicetree
On Wed, 28 Aug 2024 17:47:53 +1000, Jonathan Liu wrote:
> This adds the necessary device tree changes to enable analog audio
> output for the 3.5 mm TRS headphone jack on the Radxa ROCK 4C+ with
> its RK809 audio codec.
>
>
Applied, thanks!
[1/1] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
commit: 174c306321355d8a189b8f01fcc3f897ba13f227
Best regards,
--
Heiko Stuebner <heiko@sntech.de>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
2024-08-28 7:47 [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+ Jonathan Liu
2024-08-28 12:51 ` Rob Herring (Arm)
2024-08-28 12:56 ` Heiko Stuebner
@ 2024-08-28 13:00 ` Heiko Stübner
2024-08-28 13:24 ` Jonathan Liu
2 siblings, 1 reply; 7+ messages in thread
From: Heiko Stübner @ 2024-08-28 13:00 UTC (permalink / raw)
To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Jonathan Liu
Cc: FUKAUMI Naoki, Jonathan Liu, devicetree, linux-arm-kernel,
linux-rockchip, linux-kernel
Hi Jonathan,
Am Mittwoch, 28. August 2024, 09:47:53 CEST schrieb Jonathan Liu:
> This adds the necessary device tree changes to enable analog audio
> output for the 3.5 mm TRS headphone jack on the Radxa ROCK 4C+ with
> its RK809 audio codec.
>
> Signed-off-by: Jonathan Liu <net147@gmail.com>
as it looks like you have one of those boards, could I possibly as you
to take a look at the vdd_cpu_b and vdd_gpu nodes?
I see (and devicetree check reports it too) a pinctrl-0 for the vsel-gpio
without accompanying pinctrl-names.
Could you check if things fail if you either add pinctrl-names or remove
the pinctrl-0 entry?
Thanks a lot
Heiko
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
2024-08-28 12:51 ` Rob Herring (Arm)
@ 2024-08-28 13:03 ` Heiko Stübner
0 siblings, 0 replies; 7+ messages in thread
From: Heiko Stübner @ 2024-08-28 13:03 UTC (permalink / raw)
To: Jonathan Liu, Rob Herring (Arm)
Cc: Conor Dooley, Krzysztof Kozlowski, devicetree, linux-kernel,
FUKAUMI Naoki, linux-arm-kernel, linux-rockchip
Am Mittwoch, 28. August 2024, 14:51:12 CEST schrieb Rob Herring (Arm):
>
> On Wed, 28 Aug 2024 17:47:53 +1000, Jonathan Liu wrote:
> > This adds the necessary device tree changes to enable analog audio
> > output for the 3.5 mm TRS headphone jack on the Radxa ROCK 4C+ with
> > its RK809 audio codec.
> >
> > Signed-off-by: Jonathan Liu <net147@gmail.com>
> > ---
> > .../boot/dts/rockchip/rk3399-rock-4c-plus.dts | 46 ++++++++++++++++++-
> > 1 file changed, 45 insertions(+), 1 deletion(-)
> >
>
>
> My bot found new DTB warnings on the .dts files added or changed in this
> series.
>
> Some warnings may be from an existing SoC .dtsi. Or perhaps the warnings
> are fixed by another series. Ultimately, it is up to the platform
> maintainer whether these warnings are acceptable or not. No need to reply
> unless the platform maintainer has comments.
>
> If you already ran DT checks and didn't see these error(s), then
> make sure dt-schema is up to date:
>
> pip3 install dtschema --upgrade
>
>
> New warnings running 'make CHECK_DTBS=y rockchip/rk3399-rock-4c-plus.dtb' for 20240828074755.1320692-1-net147@gmail.com:
>
> arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dtb: pmic: vsel1-gpio: {'rockchip,pins': [[1, 17, 0, 194]], 'phandle': 138} is not of type 'array'
> from schema $id: http://devicetree.org/schemas/gpio/gpio-consumer.yaml#
> arch/arm64/boot/dts/rockchip/rk3399-rock-4c-plus.dtb: pmic: vsel2-gpio: {'rockchip,pins': [[1, 14, 0, 194]], 'phandle': 139} is not of type 'array'
> from schema $id: http://devicetree.org/schemas/gpio/gpio-consumer.yaml#
unrelated to the change in question, as that affects silergy regulators.
But I just asked Jonathan to check on their board if we can just remove
those seemingly unused pinctrl properties.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
2024-08-28 13:00 ` Heiko Stübner
@ 2024-08-28 13:24 ` Jonathan Liu
2024-08-28 13:42 ` Heiko Stübner
0 siblings, 1 reply; 7+ messages in thread
From: Jonathan Liu @ 2024-08-28 13:24 UTC (permalink / raw)
To: Heiko Stübner
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, FUKAUMI Naoki,
devicetree, linux-arm-kernel, linux-rockchip, linux-kernel
Hi Heiko,
On Wed, 28 Aug 2024 at 22:59, Heiko Stübner <heiko@sntech.de> wrote:
> Am Mittwoch, 28. August 2024, 09:47:53 CEST schrieb Jonathan Liu:
> > This adds the necessary device tree changes to enable analog audio
> > output for the 3.5 mm TRS headphone jack on the Radxa ROCK 4C+ with
> > its RK809 audio codec.
> >
> > Signed-off-by: Jonathan Liu <net147@gmail.com>
>
> as it looks like you have one of those boards, could I possibly as you
> to take a look at the vdd_cpu_b and vdd_gpu nodes?
>
> I see (and devicetree check reports it too) a pinctrl-0 for the vsel-gpio
> without accompanying pinctrl-names.
>
> Could you check if things fail if you either add pinctrl-names or remove
> the pinctrl-0 entry?
I tried both but neither resulted in any change to the warnings in dtbs_check.
Reverting my change also results in the same warnings so I don't think
it is related to my change.
Regards,
Jonathan
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+
2024-08-28 13:24 ` Jonathan Liu
@ 2024-08-28 13:42 ` Heiko Stübner
0 siblings, 0 replies; 7+ messages in thread
From: Heiko Stübner @ 2024-08-28 13:42 UTC (permalink / raw)
To: Jonathan Liu
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, FUKAUMI Naoki,
devicetree, linux-arm-kernel, linux-rockchip, linux-kernel
Hi Jonathan,
Am Mittwoch, 28. August 2024, 15:24:56 CEST schrieb Jonathan Liu:
> On Wed, 28 Aug 2024 at 22:59, Heiko Stübner <heiko@sntech.de> wrote:
> > Am Mittwoch, 28. August 2024, 09:47:53 CEST schrieb Jonathan Liu:
> > > This adds the necessary device tree changes to enable analog audio
> > > output for the 3.5 mm TRS headphone jack on the Radxa ROCK 4C+ with
> > > its RK809 audio codec.
> > >
> > > Signed-off-by: Jonathan Liu <net147@gmail.com>
> >
> > as it looks like you have one of those boards, could I possibly as you
> > to take a look at the vdd_cpu_b and vdd_gpu nodes?
> >
> > I see (and devicetree check reports it too) a pinctrl-0 for the vsel-gpio
> > without accompanying pinctrl-names.
> >
> > Could you check if things fail if you either add pinctrl-names or remove
> > the pinctrl-0 entry?
>
> I tried both but neither resulted in any change to the warnings in dtbs_check.
> Reverting my change also results in the same warnings so I don't think
> it is related to my change.
I was more aiming at a functional test on the board :-) .
You are correct in that this is not related to your change, I was just
seeing someone with the hardware.
I.e. while running dtbs check here I saw those regulator nodes
and didn't want to change stuff without being able to test them.
Heiko
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2024-08-28 13:44 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-28 7:47 [PATCH v2] arm64: dts: rockchip: Enable RK809 audio codec for Radxa ROCK 4C+ Jonathan Liu
2024-08-28 12:51 ` Rob Herring (Arm)
2024-08-28 13:03 ` Heiko Stübner
2024-08-28 12:56 ` Heiko Stuebner
2024-08-28 13:00 ` Heiko Stübner
2024-08-28 13:24 ` Jonathan Liu
2024-08-28 13:42 ` Heiko Stübner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).