diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-02-13 05:59:26 -0500 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-02-13 05:59:26 -0500 |
commit | c8a1a8985d705339a346203f26d2d6ff137f84c9 (patch) | |
tree | e838790e6fb9b9a3ff0f08c465c3ec256dbcdf0c | |
parent | 946835074e026f4bbe9f3c2b091dca6346bd1474 (diff) | |
parent | 9411e21cd0cc4fd046b4f448417b0e103e80951c (diff) |
Merge branch 'fix/hda' into topic/hda
-rw-r--r-- | sound/pci/hda/hda_codec.c | 10 | ||||
-rw-r--r-- | sound/pci/hda/hda_local.h | 2 | ||||
-rw-r--r-- | sound/pci/hda/patch_analog.c | 15 | ||||
-rw-r--r-- | sound/pci/hda/patch_sigmatel.c | 11 |
4 files changed, 34 insertions, 4 deletions
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c index 29eeb748561..98884bc8f35 100644 --- a/sound/pci/hda/hda_codec.c +++ b/sound/pci/hda/hda_codec.c | |||
@@ -3119,6 +3119,16 @@ int snd_hda_multi_out_dig_prepare(struct hda_codec *codec, | |||
3119 | } | 3119 | } |
3120 | EXPORT_SYMBOL_HDA(snd_hda_multi_out_dig_prepare); | 3120 | EXPORT_SYMBOL_HDA(snd_hda_multi_out_dig_prepare); |
3121 | 3121 | ||
3122 | int snd_hda_multi_out_dig_cleanup(struct hda_codec *codec, | ||
3123 | struct hda_multi_out *mout) | ||
3124 | { | ||
3125 | mutex_lock(&codec->spdif_mutex); | ||
3126 | cleanup_dig_out_stream(codec, mout->dig_out_nid); | ||
3127 | mutex_unlock(&codec->spdif_mutex); | ||
3128 | return 0; | ||
3129 | } | ||
3130 | EXPORT_SYMBOL_HDA(snd_hda_multi_out_dig_cleanup); | ||
3131 | |||
3122 | /* | 3132 | /* |
3123 | * release the digital out | 3133 | * release the digital out |
3124 | */ | 3134 | */ |
diff --git a/sound/pci/hda/hda_local.h b/sound/pci/hda/hda_local.h index 2ae6b53a462..84e2cf644fd 100644 --- a/sound/pci/hda/hda_local.h +++ b/sound/pci/hda/hda_local.h | |||
@@ -254,6 +254,8 @@ int snd_hda_multi_out_dig_prepare(struct hda_codec *codec, | |||
254 | unsigned int stream_tag, | 254 | unsigned int stream_tag, |
255 | unsigned int format, | 255 | unsigned int format, |
256 | struct snd_pcm_substream *substream); | 256 | struct snd_pcm_substream *substream); |
257 | int snd_hda_multi_out_dig_cleanup(struct hda_codec *codec, | ||
258 | struct hda_multi_out *mout); | ||
257 | int snd_hda_multi_out_analog_open(struct hda_codec *codec, | 259 | int snd_hda_multi_out_analog_open(struct hda_codec *codec, |
258 | struct hda_multi_out *mout, | 260 | struct hda_multi_out *mout, |
259 | struct snd_pcm_substream *substream, | 261 | struct snd_pcm_substream *substream, |
diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c index d58c32b5b43..af6b0035e2e 100644 --- a/sound/pci/hda/patch_analog.c +++ b/sound/pci/hda/patch_analog.c | |||
@@ -301,6 +301,14 @@ static int ad198x_dig_playback_pcm_prepare(struct hda_pcm_stream *hinfo, | |||
301 | format, substream); | 301 | format, substream); |
302 | } | 302 | } |
303 | 303 | ||
304 | static int ad198x_dig_playback_pcm_cleanup(struct hda_pcm_stream *hinfo, | ||
305 | struct hda_codec *codec, | ||
306 | struct snd_pcm_substream *substream) | ||
307 | { | ||
308 | struct ad198x_spec *spec = codec->spec; | ||
309 | return snd_hda_multi_out_dig_cleanup(codec, &spec->multiout); | ||
310 | } | ||
311 | |||
304 | /* | 312 | /* |
305 | * Analog capture | 313 | * Analog capture |
306 | */ | 314 | */ |
@@ -359,7 +367,8 @@ static struct hda_pcm_stream ad198x_pcm_digital_playback = { | |||
359 | .ops = { | 367 | .ops = { |
360 | .open = ad198x_dig_playback_pcm_open, | 368 | .open = ad198x_dig_playback_pcm_open, |
361 | .close = ad198x_dig_playback_pcm_close, | 369 | .close = ad198x_dig_playback_pcm_close, |
362 | .prepare = ad198x_dig_playback_pcm_prepare | 370 | .prepare = ad198x_dig_playback_pcm_prepare, |
371 | .cleanup = ad198x_dig_playback_pcm_cleanup | ||
363 | }, | 372 | }, |
364 | }; | 373 | }; |
365 | 374 | ||
@@ -1923,8 +1932,8 @@ static hda_nid_t ad1988_capsrc_nids[3] = { | |||
1923 | #define AD1988_SPDIF_OUT_HDMI 0x0b | 1932 | #define AD1988_SPDIF_OUT_HDMI 0x0b |
1924 | #define AD1988_SPDIF_IN 0x07 | 1933 | #define AD1988_SPDIF_IN 0x07 |
1925 | 1934 | ||
1926 | static hda_nid_t ad1989b_slave_dig_outs[2] = { | 1935 | static hda_nid_t ad1989b_slave_dig_outs[] = { |
1927 | AD1988_SPDIF_OUT, AD1988_SPDIF_OUT_HDMI | 1936 | AD1988_SPDIF_OUT, AD1988_SPDIF_OUT_HDMI, 0 |
1928 | }; | 1937 | }; |
1929 | 1938 | ||
1930 | static struct hda_input_mux ad1988_6stack_capture_source = { | 1939 | static struct hda_input_mux ad1988_6stack_capture_source = { |
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c index c8573e265e0..aeb5d2126da 100644 --- a/sound/pci/hda/patch_sigmatel.c +++ b/sound/pci/hda/patch_sigmatel.c | |||
@@ -2439,6 +2439,14 @@ static int stac92xx_dig_playback_pcm_prepare(struct hda_pcm_stream *hinfo, | |||
2439 | stream_tag, format, substream); | 2439 | stream_tag, format, substream); |
2440 | } | 2440 | } |
2441 | 2441 | ||
2442 | static int stac92xx_dig_playback_pcm_cleanup(struct hda_pcm_stream *hinfo, | ||
2443 | struct hda_codec *codec, | ||
2444 | struct snd_pcm_substream *substream) | ||
2445 | { | ||
2446 | struct sigmatel_spec *spec = codec->spec; | ||
2447 | return snd_hda_multi_out_dig_cleanup(codec, &spec->multiout); | ||
2448 | } | ||
2449 | |||
2442 | 2450 | ||
2443 | /* | 2451 | /* |
2444 | * Analog capture callbacks | 2452 | * Analog capture callbacks |
@@ -2483,7 +2491,8 @@ static struct hda_pcm_stream stac92xx_pcm_digital_playback = { | |||
2483 | .ops = { | 2491 | .ops = { |
2484 | .open = stac92xx_dig_playback_pcm_open, | 2492 | .open = stac92xx_dig_playback_pcm_open, |
2485 | .close = stac92xx_dig_playback_pcm_close, | 2493 | .close = stac92xx_dig_playback_pcm_close, |
2486 | .prepare = stac92xx_dig_playback_pcm_prepare | 2494 | .prepare = stac92xx_dig_playback_pcm_prepare, |
2495 | .cleanup = stac92xx_dig_playback_pcm_cleanup | ||
2487 | }, | 2496 | }, |
2488 | }; | 2497 | }; |
2489 | 2498 | ||