diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-01-20 12:30:20 -0500 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-01-20 12:30:20 -0500 |
commit | 8c441982fdc00f77b7aa609061c6411f47bcceda (patch) | |
tree | c0cb9f2f8719fe7b39073c64ea898613936ca601 /sound/pci/hda/patch_realtek.c | |
parent | 2297bd6e526ce1469279284ffda9140f8d60ea84 (diff) |
ALSA: hda - Assign proper digital I/O type for STAC/IDT
Assign the proper PCM digital I/O type (HDA_PCM_TYPE_*) for the digital
I/O on STAC/IDT codecs. HDA_PCM_TYPE_HDMI is assigned for the HDMI I/O.
A similar framework is implemented to patch_realtek.c, but it's not
set up and still using only HDA_PCM_TYPE_SPDIF yet.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/patch_realtek.c')
-rw-r--r-- | sound/pci/hda/patch_realtek.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 5d249a547fbf..4fdae06162ed 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
@@ -269,6 +269,7 @@ struct alc_spec { | |||
269 | * dig_out_nid and hp_nid are optional | 269 | * dig_out_nid and hp_nid are optional |
270 | */ | 270 | */ |
271 | hda_nid_t alt_dac_nid; | 271 | hda_nid_t alt_dac_nid; |
272 | int dig_out_type; | ||
272 | 273 | ||
273 | /* capture */ | 274 | /* capture */ |
274 | unsigned int num_adc_nids; | 275 | unsigned int num_adc_nids; |
@@ -3087,7 +3088,10 @@ static int alc_build_pcms(struct hda_codec *codec) | |||
3087 | codec->num_pcms = 2; | 3088 | codec->num_pcms = 2; |
3088 | info = spec->pcm_rec + 1; | 3089 | info = spec->pcm_rec + 1; |
3089 | info->name = spec->stream_name_digital; | 3090 | info->name = spec->stream_name_digital; |
3090 | info->pcm_type = HDA_PCM_TYPE_SPDIF; | 3091 | if (spec->dig_out_type) |
3092 | info->pcm_type = spec->dig_out_type; | ||
3093 | else | ||
3094 | info->pcm_type = HDA_PCM_TYPE_SPDIF; | ||
3091 | if (spec->multiout.dig_out_nid && | 3095 | if (spec->multiout.dig_out_nid && |
3092 | spec->stream_digital_playback) { | 3096 | spec->stream_digital_playback) { |
3093 | info->stream[SNDRV_PCM_STREAM_PLAYBACK] = *(spec->stream_digital_playback); | 3097 | info->stream[SNDRV_PCM_STREAM_PLAYBACK] = *(spec->stream_digital_playback); |