Richard Fitzgerald
80e6643393
ASoC: cs42l42: Correct configuring of switch inversion from ts-inv
...
[ Upstream commit 778a0cbef5fb76bf506f84938517bb77e7a1c478 ]
The setting from the cirrus,ts-inv property should be applied to the
TIP_SENSE_INV bit, as this is the one that actually affects the jack
detect block. The TS_INV bit only swaps the meaning of the PLUG and
UNPLUG interrupts and should always be 1 for the interrupts to have
the normal meaning.
Due to some misunderstanding the driver had been implemented to
configure the TS_INV bit based on the jack switch polarity. This made
the interrupts behave the correct way around, but left the jack detect
block, button detect and analogue circuits always interpreting an open
switch as unplugged.
The signal chain inside the codec is:
SENSE pin -> TIP_SENSE_INV -> TS_INV -> (invert) -> interrupts
|
v
Jack detect,
button detect and
analog control
As the TIP_SENSE_INV already performs the necessary inversion the
TS_INV bit never needs to change. It must always be 1 to yield the
expected interrupt behaviour.
Some extra confusion has arisen because of the additional invert in the
interrupt path, meaning that a value applied to the TS_INV bit produces
the opposite effect of applying it to the TIP_SENSE_INV bit. The ts-inv
property has therefore always had the opposite effect to what might be
expected (0 = inverted, 1 = not inverted). To maintain the meaning of
the ts-inv property it must be inverted when applied to TIP_SENSE_INV.
Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com>
Fixes: 2c394ca79604 ("ASoC: Add support for CS42L42 codec")
Link: https://lore.kernel.org/r/20211028140902.11786-3-rf@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-11-18 14:04:21 +01:00
..
2020-07-16 23:06:09 +01:00
2019-06-19 17:09:55 +02:00
2020-07-09 22:20:31 +01:00
2019-06-19 17:09:55 +02:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2020-07-16 23:06:09 +01:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:25:18 -07:00
2020-06-22 15:13:40 +01:00
2020-04-16 15:29:39 +01:00
2019-05-24 17:36:46 +02:00
2020-07-09 22:20:31 +01:00
2018-08-29 12:39:19 +01:00
2019-05-30 11:25:18 -07:00
2020-07-16 23:06:09 +01:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2020-07-09 22:20:31 +01:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-10-10 15:06:09 +01:00
2020-05-04 15:36:50 +01:00
2019-10-21 15:53:49 +01:00
2019-10-10 15:06:09 +01:00
2019-05-30 11:25:18 -07:00
2020-07-09 22:20:31 +01:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:26:32 -07:00
2020-02-04 03:05:27 +00:00
2019-07-02 13:51:29 +01:00
2021-03-25 09:04:04 +01:00
2020-09-17 17:40:13 +01:00
2020-07-16 23:06:20 +01:00
2019-06-19 17:09:55 +02:00
2018-07-30 12:02:26 +01:00
2020-07-09 22:20:31 +01:00
2020-07-16 23:06:20 +01:00
2018-07-30 12:02:25 +01:00
2020-06-22 15:13:49 +01:00
2019-05-30 11:26:32 -07:00
2019-06-19 17:09:55 +02:00
2021-05-14 09:50:38 +02:00
2018-02-20 15:02:58 +00:00
2020-07-16 23:06:15 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:15 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:40 +01:00
2019-06-19 17:09:55 +02:00
2018-02-27 10:41:34 +00:00
2019-05-30 11:26:32 -07:00
2021-03-04 11:37:45 +01:00
2020-07-16 23:06:09 +01:00
2020-12-30 11:53:36 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2021-06-03 09:00:49 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-02-22 15:13:03 +00:00
2019-02-08 13:00:28 +00:00
2021-11-18 14:04:21 +01:00
2021-07-14 16:56:46 +02:00
2019-06-19 17:09:55 +02:00
2020-10-23 18:28:51 +01:00
2019-05-30 11:26:37 -07:00
2020-07-16 23:06:19 +01:00
2019-06-19 17:09:55 +02:00
2021-03-04 11:37:40 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:48 +01:00
2019-06-05 17:37:07 +02:00
2020-07-16 23:06:19 +01:00
2020-09-25 18:18:15 +01:00
2020-04-21 19:01:55 +01:00
2019-06-19 17:09:55 +02:00
2020-09-25 18:18:16 +01:00
2020-07-28 16:43:33 +01:00
2020-07-28 16:43:33 +01:00
2020-07-28 16:43:33 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-09-28 17:59:06 +01:00
2020-09-28 17:59:06 +01:00
2020-07-16 23:06:19 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:19 +01:00
2019-05-30 11:26:37 -07:00
2019-05-30 11:26:37 -07:00
2020-05-18 16:15:07 +01:00
2020-07-16 23:06:19 +01:00
2020-07-16 23:06:19 +01:00
2019-05-30 11:26:41 -07:00
2021-06-03 09:00:42 +02:00
2019-05-30 11:26:41 -07:00
2020-12-30 11:54:09 +01:00
2019-05-22 13:18:51 +01:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:47 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:18 +01:00
2020-07-16 23:06:18 +01:00
2020-07-07 13:03:22 +01:00
2020-06-22 15:13:47 +01:00
2019-05-30 11:26:32 -07:00
2020-08-17 18:48:43 +01:00
2020-08-17 18:48:43 +01:00
2020-08-21 16:22:55 +01:00
2020-08-17 18:48:45 +01:00
2020-07-16 23:06:18 +01:00
2020-04-22 13:15:57 +01:00
2019-06-19 17:09:10 +02:00
2018-07-03 16:00:30 +01:00
2021-04-07 15:00:04 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:17 +01:00
2020-01-07 22:29:38 +00:00
2020-09-30 16:53:23 +02:00
2020-05-05 08:59:02 +02:00
2020-10-02 21:05:27 +01:00
2018-02-12 11:11:56 +00:00
2020-09-22 12:48:03 +01:00
2019-06-19 17:09:52 +02:00
2020-06-22 15:13:36 +01:00
2020-07-16 23:06:09 +01:00
2019-06-05 17:37:17 +02:00
2020-05-28 13:20:17 +01:00
2020-05-28 13:20:17 +01:00
2020-08-23 17:36:59 -05:00
2020-10-08 21:16:51 +01:00
2019-06-19 17:09:55 +02:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:09 +01:00
2019-06-05 17:37:17 +02:00
2019-03-21 14:57:47 +00:00
2020-06-22 15:13:36 +01:00
2020-01-23 12:36:45 +00:00
2020-10-08 21:16:51 +01:00
2019-06-01 18:29:58 +02:00
2020-05-04 13:27:02 +01:00
2020-07-22 14:31:55 +01:00
2019-05-30 11:26:32 -07:00
2020-07-09 22:20:31 +01:00
2018-04-16 12:37:36 +01:00
2020-08-27 14:43:24 +01:00
2020-08-27 14:43:24 +01:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2021-06-16 12:01:34 +02:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:14 +01:00
2020-02-14 16:46:24 +00:00
2020-06-22 15:13:43 +01:00
2019-06-19 17:09:55 +02:00
2020-07-30 21:00:36 +01:00
2019-08-15 15:05:18 +01:00
2019-06-19 17:09:55 +02:00
2021-04-21 13:00:51 +02:00
2021-07-14 16:56:42 +02:00
2020-07-09 21:01:26 +01:00
2021-04-21 13:00:52 +02:00
2021-07-14 16:56:42 +02:00
2020-12-30 11:53:44 +01:00
2020-07-24 15:22:34 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-08-09 18:12:38 +01:00
2019-06-19 17:09:55 +02:00
2019-05-30 11:26:32 -07:00
2019-05-30 11:26:32 -07:00
2020-07-22 14:31:55 +01:00
2019-05-21 11:28:39 +02:00
2020-07-16 23:06:09 +01:00
2019-05-30 11:26:39 -07:00
2020-08-17 12:28:55 +01:00
2020-06-22 15:13:43 +01:00
2019-08-09 13:24:29 +01:00
2018-04-26 12:44:15 +01:00
2020-06-15 19:16:49 +01:00
2019-01-25 18:07:13 +00:00
2020-09-08 13:55:01 +01:00
2020-08-20 20:17:25 +01:00
2020-03-23 18:17:22 +00:00
2020-01-21 18:26:41 +00:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-05-28 13:20:18 +01:00
2020-04-29 14:23:18 +01:00
2020-07-16 23:06:09 +01:00
2019-06-12 13:52:26 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-08-18 14:52:33 +01:00
2019-07-06 12:25:24 +01:00
2019-05-30 11:26:37 -07:00
2019-05-30 11:26:37 -07:00
2020-07-16 23:06:13 +01:00
2019-05-30 11:26:37 -07:00
2020-07-22 14:31:55 +01:00
2020-07-22 14:31:55 +01:00
2020-08-23 17:36:59 -05:00
2020-07-22 14:31:55 +01:00
2019-05-30 11:26:41 -07:00
2019-05-30 11:26:41 -07:00
2020-07-16 23:06:13 +01:00
2019-05-30 11:26:41 -07:00
2020-07-16 23:06:13 +01:00
2018-03-19 09:23:59 +08:00
2020-07-16 23:06:13 +01:00
2018-03-19 09:23:59 +08:00
2019-05-30 11:26:32 -07:00
2019-06-19 17:09:55 +02:00
2019-07-10 16:25:12 +01:00
2019-07-10 16:25:12 +01:00
2019-07-10 16:25:12 +01:00
2019-07-10 16:25:12 +01:00
2019-06-05 17:37:15 +02:00
2019-06-05 17:37:15 +02:00
2020-08-25 18:47:03 +01:00
2019-06-05 17:37:15 +02:00
2019-05-30 11:26:41 -07:00
2021-07-14 16:56:37 +02:00
2019-01-03 16:34:35 +00:00
2020-06-15 20:58:36 +01:00
2020-05-04 16:23:23 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-07-09 22:20:32 +01:00
2019-06-19 17:09:55 +02:00
2021-05-19 10:13:00 +02:00
2019-06-19 17:09:55 +02:00
2020-07-09 21:56:50 +01:00
2019-06-19 17:09:55 +02:00
2021-07-14 16:56:43 +02:00
2020-01-10 13:31:49 +00:00
2020-05-18 12:38:29 +01:00
2020-01-10 13:31:49 +00:00
2021-07-14 16:56:43 +02:00
2020-01-09 21:22:36 +00:00
2021-04-07 15:00:06 +02:00
2020-01-09 21:22:36 +00:00
2021-07-14 16:56:43 +02:00
2020-01-13 14:58:45 +00:00
2020-09-28 17:59:02 +01:00
2020-09-28 17:59:02 +01:00
2020-06-23 12:54:11 +01:00
2020-01-17 15:30:31 +00:00
2021-04-07 15:00:04 +02:00
2020-11-05 17:25:17 +00:00
2020-09-10 12:49:44 +01:00
2020-05-07 13:18:04 +01:00
2020-05-07 13:18:04 +01:00
2020-06-22 15:13:36 +01:00
2019-06-19 17:09:55 +02:00
2021-07-14 16:56:42 +02:00
2020-03-26 18:48:08 +00:00
2019-09-09 10:52:07 +01:00
2019-07-26 13:10:09 +01:00
2019-12-11 16:43:28 +00:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:46 +01:00
2019-06-19 17:09:55 +02:00
2021-07-28 14:35:36 +02:00
2021-04-07 15:00:04 +02:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:46 +01:00
2019-06-19 17:09:55 +02:00
2021-04-07 15:00:04 +02:00
2019-06-19 17:09:55 +02:00
2021-06-23 14:42:48 +02:00
2019-06-19 17:09:55 +02:00
2020-07-09 21:56:50 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:46 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:46 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:46 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2021-05-19 10:12:54 +02:00
2020-07-03 15:29:50 +01:00
2020-07-23 19:07:38 +01:00
2019-11-27 12:50:56 +00:00
2020-07-09 22:20:31 +01:00
2019-11-11 13:02:06 +00:00
2021-09-15 09:50:46 +02:00
2021-07-14 16:56:43 +02:00
2021-09-03 10:09:21 +02:00
2020-08-17 13:33:44 +01:00
2021-04-07 15:00:04 +02:00
2020-04-15 13:00:27 +01:00
2019-06-05 17:36:37 +02:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:25:18 -07:00
2019-05-30 11:25:18 -07:00
2019-06-19 17:09:10 +02:00
2019-09-04 13:48:31 +01:00
2019-05-21 11:28:40 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2018-05-18 11:20:11 +01:00
2020-07-16 23:06:13 +01:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2019-05-30 11:29:19 -07:00
2020-07-16 23:06:13 +01:00
2019-05-24 17:36:46 +02:00
2020-07-16 23:06:13 +01:00
2020-07-09 22:20:31 +01:00
2019-05-30 11:26:32 -07:00
2020-07-09 22:20:31 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:09 +01:00
2019-05-30 11:26:32 -07:00
2021-06-16 12:01:35 +02:00
2020-07-16 23:06:12 +01:00
2019-05-30 11:26:32 -07:00
2020-07-22 14:31:55 +01:00
2020-07-22 14:31:55 +01:00
2020-09-22 16:04:20 +01:00
2021-06-23 14:42:48 +02:00
2020-10-08 21:16:51 +01:00
2020-10-08 21:16:51 +01:00
2020-09-23 18:48:03 +01:00
2020-09-23 18:48:03 +01:00
2020-08-18 14:52:33 +01:00
2020-07-22 14:31:55 +01:00
2020-07-22 14:31:55 +01:00
2020-07-22 14:31:55 +01:00
2020-07-22 14:31:55 +01:00
2020-06-22 15:13:36 +01:00
2020-07-16 23:06:09 +01:00
2018-04-16 11:53:52 +01:00
2020-09-18 13:09:02 +01:00
2020-09-18 13:09:02 +01:00
2020-07-16 23:06:11 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:11 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:11 +01:00
2021-08-18 08:59:05 +02:00
2021-08-08 09:05:22 +02:00
2020-09-21 22:08:34 +01:00
2019-04-04 15:07:34 +07:00
2019-04-04 15:07:34 +07:00
2021-05-14 09:49:57 +02:00
2020-09-21 22:08:36 +01:00
2020-05-18 16:15:07 +01:00
2019-06-05 17:37:07 +02:00
2020-07-09 22:20:31 +01:00
2019-06-05 17:37:07 +02:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:40 +01:00
2018-06-18 12:54:38 +01:00
2020-06-22 15:13:36 +01:00
2018-06-01 12:05:30 +01:00
2019-06-05 17:37:07 +02:00
2020-07-16 23:06:09 +01:00
2019-06-05 17:37:07 +02:00
2020-07-16 23:06:09 +01:00
2019-07-31 12:26:47 +01:00
2020-05-18 16:15:07 +01:00
2019-06-19 17:09:55 +02:00
2021-03-25 09:04:07 +01:00
2021-09-15 09:50:44 +02:00
2020-07-20 15:34:29 +01:00
2020-06-22 15:13:41 +01:00
2019-01-28 18:18:23 +00:00
2020-05-18 16:15:07 +01:00
2019-06-05 17:37:07 +02:00
2020-08-18 14:52:41 +01:00
2019-05-30 11:26:32 -07:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:45 +01:00
2019-05-30 11:26:32 -07:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:45 +01:00
2019-06-19 17:09:55 +02:00
2020-04-21 19:01:55 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:45 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:45 +01:00
2020-10-02 21:05:29 +01:00
2020-05-04 19:23:59 +01:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2019-08-15 15:02:20 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-04-16 15:29:39 +01:00
2019-06-19 17:09:55 +02:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:45 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2019-11-11 19:42:56 +00:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-08-17 12:28:56 +01:00
2021-10-27 09:56:47 +02:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-08-18 14:52:44 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-20 15:34:31 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2019-05-30 11:26:32 -07:00
2020-07-16 23:06:16 +01:00
2020-12-30 11:53:07 +01:00
2019-10-01 12:10:10 +01:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-07-09 22:20:31 +01:00
2019-05-30 11:26:32 -07:00
2020-12-30 11:53:08 +01:00
2019-06-19 17:09:55 +02:00
2020-12-30 11:53:08 +01:00
2019-06-19 17:09:55 +02:00
2020-07-16 23:06:16 +01:00
2019-06-19 17:09:55 +02:00
2020-06-22 15:13:45 +01:00
2019-06-05 17:37:07 +02:00
2019-06-05 17:37:17 +02:00
2019-05-30 11:26:32 -07:00
2020-08-18 14:52:33 +01:00
2021-07-28 14:35:36 +02:00
2020-04-21 19:01:55 +01:00
2020-09-01 13:13:16 +01:00
2020-09-01 13:13:16 +01:00
2020-07-23 19:52:23 +01:00
2021-03-04 11:37:45 +01:00
2020-05-26 10:55:37 +01:00
2019-06-19 17:09:55 +02:00