]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - sound/pci/hda/patch_analog.c
[ALSA] HDA: Add Asus VX1 support
[linux-2.6-omap-h63xx.git] / sound / pci / hda / patch_analog.c
index 54cfd4526d209e9e58190a5f287378fd57793dd1..cfe064a75ca6c4abafa644ab6fc5cc8d5acedf13 100644 (file)
@@ -72,7 +72,7 @@ struct ad198x_spec {
        unsigned int num_kctl_alloc, num_kctl_used;
        struct snd_kcontrol_new *kctl_alloc;
        struct hda_input_mux private_imux;
-       hda_nid_t private_dac_nids[4];
+       hda_nid_t private_dac_nids[AUTO_CFG_MAX_OUTS];
 
        unsigned int jack_present :1;
 
@@ -612,7 +612,8 @@ static void ad1986a_hp_automute(struct hda_codec *codec)
        unsigned int present;
 
        present = snd_hda_codec_read(codec, 0x1a, 0, AC_VERB_GET_PIN_SENSE, 0);
-       spec->jack_present = (present & 0x80000000) != 0;
+       /* Lenovo N100 seems to report the reversed bit for HP jack-sensing */
+       spec->jack_present = !(present & 0x80000000);
        ad1986a_update_hp(codec);
 }
 
@@ -840,6 +841,7 @@ static struct snd_pci_quirk ad1986a_cfg_tbl[] = {
        SND_PCI_QUIRK(0x1043, 0x1297, "ASUS Z62F", AD1986A_LAPTOP_EAPD),
        SND_PCI_QUIRK(0x1043, 0x12b3, "ASUS V1j", AD1986A_LAPTOP_EAPD),
        SND_PCI_QUIRK(0x1043, 0x1302, "ASUS W3j", AD1986A_LAPTOP_EAPD),
+       SND_PCI_QUIRK(0x1043, 0x1443, "ASUS VX1", AD1986A_LAPTOP),
        SND_PCI_QUIRK(0x1043, 0x1447, "ASUS A8J", AD1986A_3STACK),
        SND_PCI_QUIRK(0x1043, 0x817f, "ASUS P5", AD1986A_3STACK),
        SND_PCI_QUIRK(0x1043, 0x818f, "ASUS P5", AD1986A_LAPTOP),
@@ -956,6 +958,14 @@ static int patch_ad1986a(struct hda_codec *codec)
                break;
        }
 
+       /* AD1986A has a hardware problem that it can't share a stream
+        * with multiple output pins.  The copy of front to surrounds
+        * causes noisy or silent outputs at a certain timing, e.g.
+        * changing the volume.
+        * So, let's disable the shared stream.
+        */
+       spec->multiout.no_share_stream = 1;
+
        return 0;
 }