]> git.itanic.dy.fi Git - linux-stable/commit
ASoC: mediatek: mt8186-da7219: Expose individual headset jack pins
authorNícolas F. R. A. Prado <nfraprado@collabora.com>
Thu, 22 Sep 2022 23:59:49 +0000 (19:59 -0400)
committerMark Brown <broonie@kernel.org>
Fri, 23 Sep 2022 12:56:08 +0000 (13:56 +0100)
commit8e986748680629a82398c65da0c5bda4c6a01b3d
treef7521d0a6434c4f48964468e1120179c4bf12cd5
parent13bee4a16ac5c5f0e3a5db868df991be57e74aa5
ASoC: mediatek: mt8186-da7219: Expose individual headset jack pins

The da7219 codec is able to distinguish between two event types:
headphone insertion/removal and headset microphone insertion/removal.
However, currently, the mt8186-da7219 driver exposes a single kcontrol
for the headset jack, so userspace isn't able to differentiate between
the two events.

Add a definition for the headset jack pins, so that a separate jack
kcontrol is created for each one, allowing userspace to track and handle
them individually.

Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/r/20220922235951.252532-5-nfraprado@collabora.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/mediatek/mt8186/mt8186-mt6366-da7219-max98357.c