]> git.baikalelectronics.ru Git - kernel.git/commit
ALSA: hda - Update mixer name for the lower codec address
authorTakashi Iwai <tiwai@suse.de>
Thu, 15 Oct 2015 12:06:14 +0000 (14:06 +0200)
committerTakashi Iwai <tiwai@suse.de>
Thu, 15 Oct 2015 12:10:25 +0000 (14:10 +0200)
commit7c07584d4ffe212cfddf1c34c565588e733c022b
tree84c0107ba000e147910e28a92490bd8c6403d745
parentd8aee2faf5ed3a32b2ec80e01a04a3cb86bb27f1
ALSA: hda - Update mixer name for the lower codec address

In most cases, we prefer the onboard codec as the primary device, thus
it's better to set it as the mixer name.  Currently, however, the
mixer name is updated per the device instantiation order, and user
gets often HDMI/DP or other seen as a mixer chip name.  Also, if a
codec name is renamed by the driver, the old chip name might be left
still as the mixer name.

This patch addresses these issues by remembering the chip address that
was referred as the mixer name.  When a codec with the same or lower
address gives its name, renew the mixer name accordingly, as it's
either the update of the codec name or we get likely the more
appropriate chip as the reference.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/hda_bind.c
sound/pci/hda/hda_codec.c
sound/pci/hda/hda_codec.h