diff options
author | Mark Brown <broonie@linaro.org> | 2013-09-11 11:17:14 +0100 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2013-09-11 11:17:14 +0100 |
commit | 29dc5dd229dc3130b51df0932e59946fc09d3bd4 (patch) | |
tree | 51fbe8eb543fc4fd3f8ee6582bdc72ea0bccee6f /sound/soc/codecs/hdmi.c | |
parent | 6e4664525b1db28f8c4e1130957f70a94c19213e (diff) | |
parent | e011143454606de70eba1db5d99454eec0017fdb (diff) | |
download | linux-29dc5dd229dc3130b51df0932e59946fc09d3bd4.tar.bz2 |
Merge remote-tracking branch 'asoc/fix/atmel' into asoc-linus
Diffstat (limited to 'sound/soc/codecs/hdmi.c')
-rw-r--r-- | sound/soc/codecs/hdmi.c | 30 |
1 files changed, 29 insertions, 1 deletions
diff --git a/sound/soc/codecs/hdmi.c b/sound/soc/codecs/hdmi.c index 2bcae2b40c92..68342b121c96 100644 --- a/sound/soc/codecs/hdmi.c +++ b/sound/soc/codecs/hdmi.c @@ -23,11 +23,20 @@ #define DRV_NAME "hdmi-audio-codec" -static struct snd_soc_codec_driver hdmi_codec; +static const struct snd_soc_dapm_widget hdmi_widgets[] = { + SND_SOC_DAPM_INPUT("RX"), + SND_SOC_DAPM_OUTPUT("TX"), +}; + +static const struct snd_soc_dapm_route hdmi_routes[] = { + { "Capture", NULL, "RX" }, + { "TX", NULL, "Playback" }, +}; static struct snd_soc_dai_driver hdmi_codec_dai = { .name = "hdmi-hifi", .playback = { + .stream_name = "Playback", .channels_min = 2, .channels_max = 8, .rates = SNDRV_PCM_RATE_32000 | @@ -37,6 +46,25 @@ static struct snd_soc_dai_driver hdmi_codec_dai = { .formats = SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S24_LE, }, + .capture = { + .stream_name = "Capture", + .channels_min = 2, + .channels_max = 2, + .rates = SNDRV_PCM_RATE_32000 | + SNDRV_PCM_RATE_44100 | SNDRV_PCM_RATE_48000 | + SNDRV_PCM_RATE_88200 | SNDRV_PCM_RATE_96000 | + SNDRV_PCM_RATE_176400 | SNDRV_PCM_RATE_192000, + .formats = SNDRV_PCM_FMTBIT_S16_LE | + SNDRV_PCM_FMTBIT_S24_LE, + }, + +}; + +static struct snd_soc_codec_driver hdmi_codec = { + .dapm_widgets = hdmi_widgets, + .num_dapm_widgets = ARRAY_SIZE(hdmi_widgets), + .dapm_routes = hdmi_routes, + .num_dapm_routes = ARRAY_SIZE(hdmi_routes), }; static int hdmi_codec_probe(struct platform_device *pdev) |