forked from radxa-pkg/radxa-overlays
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: rk3588: add two i2s2 sound card
Co-authored-by: ZHANG Yuntian <[email protected]>
- Loading branch information
1 parent
cfc96d0
commit 9b778dc
Showing
3 changed files
with
94 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
44 changes: 44 additions & 0 deletions
44
arch/arm64/boot/dts/rockchip/overlays/rk3588-i2s2-2ch-m1-hifiberry-dac.dts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
/dts-v1/; | ||
/plugin/; | ||
/ { | ||
metadata { | ||
title = "Enable HiFiBerry DAC+ Light on I2S2-M1"; | ||
compatible = "radxa,rock-5b", "radxa,rock-5b-plus"; | ||
category = "audio"; | ||
description = "Enable HiFiBerry DAC+ Light on I2S2-M1."; | ||
exclusive = "GPIO3_B5", "GPIO3_B6", "GPIO3_B2", "GPIO3_B3", "i2s2_2ch"; | ||
}; | ||
}; | ||
|
||
&{/} { | ||
pcm5102a_codec: pcm5102a-codec { | ||
compatible = "ti,pcm5102a"; | ||
#sound-dai-cells = <0>; | ||
status = "okay"; | ||
}; | ||
|
||
sound_ext_card: sound-ext-card { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
status = "okay"; | ||
compatible = "simple-audio-card"; | ||
simple-audio-card,format = "i2s"; | ||
simple-audio-card,mclk-fs = <256>; | ||
simple-audio-card,name = "snd_rpi_hifiberry_dac"; | ||
simple-audio-card,dai-link@0 { | ||
reg = <0>; | ||
format = "i2s"; | ||
cpu { | ||
sound-dai = <&i2s2_2ch>; | ||
}; | ||
codec { | ||
sound-dai = <&pcm5102a_codec>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&i2s2_2ch { | ||
pinctrl-0 = <&i2s2m1_lrck &i2s2m1_sclk &i2s2m1_sdi &i2s2m1_sdo>; | ||
status = "okay"; | ||
}; |
48 changes: 48 additions & 0 deletions
48
arch/arm64/boot/dts/rockchip/overlays/rk3588-i2s2-2ch-m1.dts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/dts-v1/; | ||
/plugin/; | ||
|
||
/ { | ||
metadata { | ||
title = "Enable I2S2-M1 2-channel dummy sound card"; | ||
compatible = "radxa,rock-5b", "radxa,rock-5b-plus"; | ||
category = "misc"; | ||
description = "Enable I2S2-M1 2-channel dummy sound card. | ||
This overlay is only for demonstration purpose. | ||
It does not support any specific hardware device."; | ||
exclusive = "GPIO3_B5", "GPIO3_B6", "GPIO3_B2", "GPIO3_B3", "i2s2_2ch"; | ||
}; | ||
}; | ||
|
||
&{/} { | ||
i2s2_dummy_codec: i2s2-dummy-codec { | ||
compatible = "rockchip,dummy-codec"; | ||
#sound-dai-cells = <0>; | ||
}; | ||
|
||
i2s2_dummy_sound: i2s2-dummy-sound { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
compatible = "simple-audio-card"; | ||
simple-audio-card,format = "i2s"; | ||
simple-audio-card,name = "dummy-card"; | ||
simple-audio-card,mclk-fs = <256>; | ||
status = "okay"; | ||
|
||
simple-audio-card,dai-link@0 { | ||
reg = <0>; | ||
format = "i2s"; | ||
cpu { | ||
sound-dai = <&i2s2_2ch>; | ||
}; | ||
|
||
codec { | ||
sound-dai = <&i2s2_dummy_codec>; | ||
}; | ||
}; | ||
}; | ||
}; | ||
|
||
&i2s2_2ch { | ||
pinctrl-0 = <&i2s2m1_lrck &i2s2m1_sclk &i2s2m1_sdi &i2s2m1_sdo>; | ||
status = "okay"; | ||
}; |