ALSA: hda/cirrus: Add jack detect interrupt support from CS42L42 companion codec.
authorVitaly Rodionov <vitalyr@opensource.cirrus.com>
Sat, 6 Mar 2021 11:19:33 +0000 (11:19 +0000)
committerTakashi Iwai <tiwai@suse.de>
Sun, 7 Mar 2021 08:18:28 +0000 (09:18 +0100)
commitb73df04187ebb52edf3f7e502bb245c5ccab2763
tree570eddf567b6f6e3cedfe4008302e9254a63608a
parent6cc7e93f46a5ce9f65ad3c6c6f645f1d831a8fa4
ALSA: hda/cirrus: Add jack detect interrupt support from CS42L42 companion codec.

In the case of CS8409 we do not have unsol events from NID's 0x24 and 0x34
where hs mic and hp are connected. Companion codec CS42L42 will generate
interrupt via gpio 4 to notify jack events. We have to overwrite standard
snd_hda_jack_unsol_event(), read CS42L42 jack detect status registers and
then notify status via generic snd_hda_jack_unsol_event() call.

Tested on DELL Inspiron-3500, DELL Inspiron-3501, DELL Inspiron-3505.

Signed-off-by: Vitaly Rodionov <vitalyr@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20210306111934.4832-4-vitalyr@opensource.cirrus.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/patch_cirrus.c