Lines Matching +full:i2s +full:- +full:out
1 // SPDX-License-Identifier: GPL-2.0
13 #include <sound/soc-dai.h>
15 #include <dt-bindings/sound/meson-g12a-tohdmitx.h>
16 #include "meson-codec-glue.h"
18 #define G12A_TOHDMITX_DRV_NAME "g12a-tohdmitx"
35 "I2S A", "I2S B", "I2S C",
45 struct soc_enum *e = (struct soc_enum *)kcontrol->private_value; in g12a_tohdmitx_i2s_mux_put_enum()
48 if (ucontrol->value.enumerated.item[0] >= e->items) in g12a_tohdmitx_i2s_mux_put_enum()
49 return -EINVAL; in g12a_tohdmitx_i2s_mux_put_enum()
51 mux = snd_soc_enum_item_to_val(e, ucontrol->value.enumerated.item[0]); in g12a_tohdmitx_i2s_mux_put_enum()
52 changed = snd_soc_component_test_bits(component, e->reg, in g12a_tohdmitx_i2s_mux_put_enum()
63 snd_soc_component_update_bits(component, e->reg, in g12a_tohdmitx_i2s_mux_put_enum()
81 SOC_DAPM_ENUM_EXT("I2S Source", g12a_tohdmitx_i2s_mux_enum,
96 struct soc_enum *e = (struct soc_enum *)kcontrol->private_value; in g12a_tohdmitx_spdif_mux_put_enum()
99 if (ucontrol->value.enumerated.item[0] >= e->items) in g12a_tohdmitx_spdif_mux_put_enum()
100 return -EINVAL; in g12a_tohdmitx_spdif_mux_put_enum()
102 mux = snd_soc_enum_item_to_val(e, ucontrol->value.enumerated.item[0]); in g12a_tohdmitx_spdif_mux_put_enum()
138 SND_SOC_DAPM_MUX("I2S SRC", SND_SOC_NOPM, 0, 0,
140 SND_SOC_DAPM_SWITCH("I2S OUT EN", SND_SOC_NOPM, 0, 0,
144 SND_SOC_DAPM_SWITCH("SPDIF OUT EN", SND_SOC_NOPM, 0, 0,
193 TOHDMITX_IN("I2S IN A", TOHDMITX_I2S_IN_A,
195 TOHDMITX_IN("I2S IN B", TOHDMITX_I2S_IN_B,
197 TOHDMITX_IN("I2S IN C", TOHDMITX_I2S_IN_C,
199 TOHDMITX_OUT("I2S OUT", TOHDMITX_I2S_OUT,
205 TOHDMITX_OUT("SPDIF OUT", TOHDMITX_SPDIF_OUT,
217 { "I2S SRC", "I2S A", "I2S IN A Playback" },
218 { "I2S SRC", "I2S B", "I2S IN B Playback" },
219 { "I2S SRC", "I2S C", "I2S IN C Playback" },
220 { "I2S OUT EN", "Switch", "I2S SRC" },
221 { "I2S OUT Capture", NULL, "I2S OUT EN" },
224 { "SPDIF OUT EN", "Switch", "SPDIF SRC" },
225 { "SPDIF OUT Capture", NULL, "SPDIF OUT EN" },
244 { .compatible = "amlogic,g12a-tohdmitx", },
251 struct device *dev = &pdev->dev; in g12a_tohdmitx_probe()