ODROID-COMMON: adjust sound card dai link for spdif_out.

hw:0,0 -> tdmc <-> internal DAC
hw:0,1 -> spdif_b <-> hdmitx
hw:0,2 -> spdif_a <-> spdif_out(GPIOA_11)

Change-Id: I2d31ec832d6cb82e2363977cbcbc5bc96fa3f993
This commit is contained in:
Kevin Kim
2018-12-06 18:29:01 +09:00
committed by Luke Go
parent 2247e37c4b
commit 329632ae25
2 changed files with 18 additions and 0 deletions

View File

@@ -1075,12 +1075,23 @@ static int aml_dai_spdif_prepare(
spdif_get_channel_status_info(&chsts, runtime->rate);
spdif_set_channel_status_info(&chsts, p_spdif->id);
#if defined(CONFIG_ARCH_MESON64_ODROID_COMMON)
/* TOHDMITX_CTRL0
* ODROID is spdif_b only would notify to hdmitx
*/
if (p_spdif->id == 1) {
spdifout_to_hdmitx_ctrl(p_spdif->id);
/* notify to hdmitx */
spdif_notify_to_hdmitx(substream);
}
#else
/* TOHDMITX_CTRL0
* Both spdif_a/spdif_b would notify to hdmitx
*/
spdifout_to_hdmitx_ctrl(p_spdif->id);
/* notify to hdmitx */
spdif_notify_to_hdmitx(substream);
#endif
} else {
struct toddr *to = p_spdif->tddr;

View File

@@ -624,8 +624,15 @@ void spdifout_play_with_zerodata(unsigned int spdif_id)
/* spdif clk */
spdifout_clk_ctrl(spdif_id, true);
#if defined(CONFIG_ARCH_MESON64_ODROID_COMMON)
/* ODROID spdif_b only to hdmitx */
if (spdif_id == 1)
spdifout_to_hdmitx_ctrl(spdif_id);
#else
/* spdif to hdmitx */
spdifout_to_hdmitx_ctrl(spdif_id);
#endif
/* spdif ctrl */
spdifout_fifo_ctrl(spdif_id,