diff options
Diffstat (limited to 'sound')
-rw-r--r-- | sound/pci/hda/patch_nvhdmi.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/sound/pci/hda/patch_nvhdmi.c b/sound/pci/hda/patch_nvhdmi.c index 2c1e01a4b095..fafd054955cb 100644 --- a/sound/pci/hda/patch_nvhdmi.c +++ b/sound/pci/hda/patch_nvhdmi.c @@ -26,6 +26,9 @@ #include <linux/delay.h> #include <linux/slab.h> #include <sound/core.h> +#if defined(CONFIG_SND_HDA_TEGRA) +#include <mach/hdmi-audio.h> +#endif #include "hda_codec.h" #include "hda_local.h" @@ -202,6 +205,15 @@ static int nvhdmi_dig_playback_pcm_prepare_8ch_89(struct hda_pcm_stream *hinfo, unsigned int format, struct snd_pcm_substream *substream) { +#if defined(CONFIG_SND_HDA_TEGRA) + int err = 0; + /* Set hdmi:audio freq and source selection*/ + err = tegra_hdmi_setup_audio_freq_source(substream->runtime->rate, AUTO); + if ( err < 0 ) { + snd_printk(KERN_ERR + "Unable to set hdmi audio freq:%d \n", substream->runtime->rate); + } +#endif hdmi_set_channel_count(codec, hinfo->nid, substream->runtime->channels); |