diff options
Diffstat (limited to 'sound/pci/hda/patch_realtek.c')
-rw-r--r-- | sound/pci/hda/patch_realtek.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 4bd26725355c..7e5422f64caf 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
@@ -2633,12 +2633,14 @@ static int alc_build_pcms(struct hda_codec *codec) | |||
2633 | 2633 | ||
2634 | info->name = spec->stream_name_analog; | 2634 | info->name = spec->stream_name_analog; |
2635 | if (spec->stream_analog_playback) { | 2635 | if (spec->stream_analog_playback) { |
2636 | snd_assert(spec->multiout.dac_nids, return -EINVAL); | 2636 | if (snd_BUG_ON(!spec->multiout.dac_nids)) |
2637 | return -EINVAL; | ||
2637 | info->stream[SNDRV_PCM_STREAM_PLAYBACK] = *(spec->stream_analog_playback); | 2638 | info->stream[SNDRV_PCM_STREAM_PLAYBACK] = *(spec->stream_analog_playback); |
2638 | info->stream[SNDRV_PCM_STREAM_PLAYBACK].nid = spec->multiout.dac_nids[0]; | 2639 | info->stream[SNDRV_PCM_STREAM_PLAYBACK].nid = spec->multiout.dac_nids[0]; |
2639 | } | 2640 | } |
2640 | if (spec->stream_analog_capture) { | 2641 | if (spec->stream_analog_capture) { |
2641 | snd_assert(spec->adc_nids, return -EINVAL); | 2642 | if (snd_BUG_ON(!spec->adc_nids)) |
2643 | return -EINVAL; | ||
2642 | info->stream[SNDRV_PCM_STREAM_CAPTURE] = *(spec->stream_analog_capture); | 2644 | info->stream[SNDRV_PCM_STREAM_CAPTURE] = *(spec->stream_analog_capture); |
2643 | info->stream[SNDRV_PCM_STREAM_CAPTURE].nid = spec->adc_nids[0]; | 2645 | info->stream[SNDRV_PCM_STREAM_CAPTURE].nid = spec->adc_nids[0]; |
2644 | } | 2646 | } |