sound fixes for 3.18-rc5
Linus,
please pull sound fixes for v3.18-rc5 from:
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git tags/sound-3.18-rc5
The topmost commit is 3542aed7480925eb859f7ce101982209cc19a126
----------------------------------------------------------------
sound fixes for 3.18-rc5
Things get calming down, now we have only a few fix patches:
a trivial fix for memory leak in usb-audio, a patch for the new HD-audio PCI id, a device-specific mute-LED fix, and a slightly big patch to cover the missing COEF inits of various Realtek codecs.
----------------------------------------------------------------
Devin Ryles (1):
ALSA: hda_intel: Add DeviceIDs for Sunrise Point-LP
Kailang Yang (1):
ALSA: hda/realtek - Change EAPD to verb control
Takashi Iwai (2):
ALSA: usb-audio: Fix memory leak in FTU quirk
ALSA: hda - Add mute LED control for Lenovo Ideapad Z560
--- sound/pci/hda/hda_intel.c | 4 ++ sound/pci/hda/patch_conexant.c | 31 ++++++++++++ sound/pci/hda/patch_realtek.c | 105 +++++++++++++++++++++++++++++------------ sound/usb/mixer_quirks.c | 6 +++ 4 files changed, 116 insertions(+), 30 deletions(-)
sound/pci/hda/hda_intel.c +4 -0
@@ -219,6 +219,7 @@ MODULE_SUPPORTED_DEVICE("{{Intel, ICH6},""{Intel, LPT_LP}," "{Intel, WPT_LP}," "{Intel, SPT}," +"{Intel, SPT_LP}," "{Intel, HPT}," "{Intel, PBG}," "{Intel, SCH},"
@@ -2004,6 +2005,9 @@ static const struct pci_device_id azx_ids[] = {/* Sunrise Point */ { PCI_DEVICE(0x8086, 0xa170), .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH }, + /* Sunrise Point-LP */ + { PCI_DEVICE(0x8086, 0x9d70), + .driver_data = AZX_DRIVER_PCH | AZX_DCAPS_INTEL_PCH }, /* Haswell */ { PCI_DEVICE(0x8086, 0x0a0c), .driver_data = AZX_DRIVER_HDMI | AZX_DCAPS_INTEL_HASWELL },
sound/pci/hda/patch_conexant.c +31 -0
@@ -43,6 +43,7 @@ struct conexant_spec {unsigned int num_eapds;hda_nid_t eapds[4 ];bool dynamic_eapd; +hda_nid_t mute_led_eapd;unsigned int parse_flags;/* flag for snd_hda_parse_pin_defcfg() */
@@ -163,6 +164,17 @@ static void cx_auto_vmaster_hook(void *private_data, int enabled)cx_auto_turn_eapd (codec, spec->num_eapds, spec->eapds, enabled); } +/* turn on/off EAPD according to Master switch (inversely!) for mute LED */ +static void cx_auto_vmaster_hook_mute_led (void *private_data,int enabled) +{ +struct hda_codec *codec = private_data; +struct conexant_spec *spec = codec->spec; + +snd_hda_codec_write (codec, spec->mute_led_eapd,0 , +AC_VERB_SET_EAPD_BTLENABLE , + enabled ?0x00 :0x02 ); +} +static int cx_auto_build_controls (struct hda_codec *codec) {int err;
@@ -223,6 +235,7 @@ enum {CXT_FIXUP_TOSHIBA_P105 ,CXT_FIXUP_HP_530 ,CXT_FIXUP_CAP_MIX_AMP_5047 , + CXT_FIXUP_MUTE_LED_EAPD, };/* for hda_fixup_thinkpad_acpi() */
@@ -557,6 +570,18 @@ static void cxt_fixup_olpc_xo(struct hda_codec *codec, } } +static void cxt_fixup_mute_led_eapd (struct hda_codec *codec, +const struct hda_fixup *fix,int action) +{ +struct conexant_spec *spec = codec->spec; + +if (action ==HDA_FIXUP_ACT_PRE_PROBE ) { + spec->mute_led_eapd =0x1b ; + spec->dynamic_eapd =1 ; + spec->gen.vmaster_mute.hook = cx_auto_vmaster_hook_mute_led; + } +} +/* * Fix max input level on mixer widget to 0dB * (originally it has 0x2b steps with 0dB offset 0x14)
@@ -705,6 +730,10 @@ static const struct hda_fixup cxt_fixups[] = { .type = HDA_FIXUP_FUNC, .v.func = cxt_fixup_cap_mix_amp_5047, }, + [CXT_FIXUP_MUTE_LED_EAPD] = { + .type = HDA_FIXUP_FUNC, + .v.func = cxt_fixup_mute_led_eapd, + }, }; static const struct snd_pci_quirk cxt5045_fixups[] = {
@@ -762,6 +791,7 @@ static const struct snd_pci_quirk cxt5066_fixups[] = {SND_PCI_QUIRK (0x17aa ,0x21cf ,"Lenovo T520" ,CXT_PINCFG_LENOVO_TP410 ),SND_PCI_QUIRK (0x17aa ,0x21da ,"Lenovo X220" ,CXT_PINCFG_LENOVO_TP410 ),SND_PCI_QUIRK (0x17aa ,0x21db ,"Lenovo X220-tablet" ,CXT_PINCFG_LENOVO_TP410 ), +SND_PCI_QUIRK (0x17aa ,0x38af ,"Lenovo IdeaPad Z560" ,CXT_FIXUP_MUTE_LED_EAPD ),SND_PCI_QUIRK (0x17aa ,0x3975 ,"Lenovo U300s" ,CXT_FIXUP_STEREO_DMIC ),SND_PCI_QUIRK (0x17aa ,0x3977 ,"Lenovo IdeaPad U310" ,CXT_FIXUP_STEREO_DMIC ), SND_PCI_QUIRK(0x17aa, 0x397b, "Lenovo S205", CXT_FIXUP_STEREO_DMIC),
@@ -780,6 +810,7 @@ static const struct hda_model_fixup cxt5066_fixup_models[] = { { .id = CXT_PINCFG_LEMOTE_A1004, .name = "lemote-a1004" }, { .id = CXT_PINCFG_LEMOTE_A1205, .name = "lemote-a1205" }, { .id = CXT_FIXUP_OLPC_XO, .name = "olpc-xo" }, + { .id = CXT_FIXUP_MUTE_LED_EAPD, .name = "mute-led-eapd" }, {} };
sound/pci/hda/patch_realtek.c +75 -30
135 lines not on this page · raw message
sound/usb/mixer_quirks.c +6 -0
@@ -885,6 +885,11 @@ static int snd_ftu_eff_switch_put(struct snd_kcontrol *kctl,return changed; } +static void kctl_private_value_free (struct snd_kcontrol *kctl) +{ +kfree ((void *)kctl->private_value); +} +static int snd_ftu_create_effect_switch (struct usb_mixer_interface *mixer,int validx,int bUnitID) {
@@ -919,6 +924,7 @@ static int snd_ftu_create_effect_switch(struct usb_mixer_interface *mixer,return -ENOMEM ; } + kctl->private_free = kctl_private_value_free; err =snd_ctl_add (mixer->chip->card, kctl);if (err <0 )return err;