diff options
| author | Chen Yuxi <chenyuxi19@huawei.com> | 2026-11-17 07:05:16 +0000 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2026-11-18 13:48:29 +0000 |
| commit | fd3b0fc97ea72d027359e7603a1224703cec1864 (patch) | |
| tree | 811dae1af5c7e0dbcb0b00e002924da5094f8d8c /tools/perf/scripts/python | |
| parent | bd6e011c8121c909daf51c78b56bb3bf7f467889 (diff) | |
ASoC: wm8962: Fix broken headset button caused by wrong guard constant
Commit e59075211902 ("ASoC: wm8962: Don't report a microphone if
it's shorted to ground on plug") guards the mic short report by
testing wm8962->mic_status against WM8962_MICDET_STS. But mic_status
stores the reported jack status, composed of SND_JACK_MICROPHONE and
SND_JACK_BTN_0, which never has WM8962_MICDET_STS set. The guard is
therefore always true, so every mic short event reports nothing.
Pressing the button on a TRRS headset shorts the mic pin to ground,
which used to be reported as SND_JACK_BTN_0. After that commit the
button press is silently dropped, breaking the headset button on all
wm8962 boards using the mic detect path.
Test mic_status against SND_JACK_MICROPHONE instead, restoring the
intended behaviour: suppress the report only when no microphone was
previously detected, i.e. a TRS plug in a TRRS socket.
Fixes: e59075211902 ("ASoC: wm8962: Don't report a microphone if it's shorted to ground on plug")
Cc: stable@vger.kernel.org
Signed-off-by: Chen Yuxi <chenyuxi19@huawei.com>
Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Reviewed-by: Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm>
Link: https://patch.msgid.link/20261117070516.3861828-1-chenyuxi19@huawei.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
