diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-07-04 12:20:25 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-07-04 12:20:25 +0200 |
commit | 1475ef0f0367766417f10f82880178ca42922748 (patch) | |
tree | 5e9d8fe6b35cfdfa8dfc56076f4facff92c2451e /sound/pci/hda/hda_codec.c | |
parent | ALSA: hda - Don't override maxbps for FLOAT sharing with linear formats (diff) | |
parent | ALSA: hda - move 8086:fb30 quirk (stac9205) to the proper section (diff) | |
download | linux-1475ef0f0367766417f10f82880178ca42922748.tar.xz linux-1475ef0f0367766417f10f82880178ca42922748.zip |
Merge branch 'fix/hda' into topic/hda
Diffstat (limited to 'sound/pci/hda/hda_codec.c')
-rw-r--r-- | sound/pci/hda/hda_codec.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c index fb5760c64e74..94d848e98716 100644 --- a/sound/pci/hda/hda_codec.c +++ b/sound/pci/hda/hda_codec.c @@ -3467,10 +3467,16 @@ int snd_hda_multi_out_analog_open(struct hda_codec *codec, } mutex_lock(&codec->spdif_mutex); if (mout->share_spdif) { - runtime->hw.rates &= mout->spdif_rates; - runtime->hw.formats &= mout->spdif_formats; - if (mout->spdif_maxbps < hinfo->maxbps) - hinfo->maxbps = mout->spdif_maxbps; + if ((runtime->hw.rates & mout->spdif_rates) && + (runtime->hw.formats & mout->spdif_formats)) { + runtime->hw.rates &= mout->spdif_rates; + runtime->hw.formats &= mout->spdif_formats; + if (mout->spdif_maxbps < hinfo->maxbps) + hinfo->maxbps = mout->spdif_maxbps; + } else { + mout->share_spdif = 0; + /* FIXME: need notify? */ + } } mutex_unlock(&codec->spdif_mutex); } |