ALSA: hda - Add the pin / port mapping on Intel ILK and VLV
Intel IronLake and ValleyView platforms have different HDMI widget pin and digital port mapping from other newer ones. The recent ones (HSW+) have NID 0x05 to 0x07 for port B to port D, while these chips have NID 0x04 to 0x06. For adapting this mapping, pass the codec object instead of the bus object to snd_hdac_sync_audio_rate() and snd_hdac_acomp_get_eld() so that they can check the codec ID and calculate the mapping properly. The changes in the HDMI codec driver side will follow in the later patch. Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
@@ -1486,7 +1486,7 @@ static void sync_eld_via_acomp(struct hda_codec *codec,
|
||||
|
||||
mutex_lock(&per_pin->lock);
|
||||
eld->monitor_present = false;
|
||||
size = snd_hdac_acomp_get_eld(&codec->bus->core, per_pin->pin_nid,
|
||||
size = snd_hdac_acomp_get_eld(&codec->core, per_pin->pin_nid,
|
||||
&eld->monitor_present, eld->eld_buffer,
|
||||
ELD_MAX_SIZE);
|
||||
if (size > 0) {
|
||||
@@ -1740,7 +1740,7 @@ static int generic_hdmi_playback_pcm_prepare(struct hda_pcm_stream *hinfo,
|
||||
/* Call sync_audio_rate to set the N/CTS/M manually if necessary */
|
||||
/* Todo: add DP1.2 MST audio support later */
|
||||
if (codec_has_acomp(codec))
|
||||
snd_hdac_sync_audio_rate(&codec->bus->core, pin_nid, runtime->rate);
|
||||
snd_hdac_sync_audio_rate(&codec->core, pin_nid, runtime->rate);
|
||||
|
||||
non_pcm = check_non_pcm_per_cvt(codec, cvt_nid);
|
||||
mutex_lock(&per_pin->lock);
|
||||
|
Reference in New Issue
Block a user