Hans de Goede 8fc7cc507d
ASoC: rt5640: Only cancel jack-detect work on suspend if active
If jack-detection is not used; or has already been disabled then
there is no need to call rt5640_cancel_work().

Move the rt5640_cancel_work() inside the "if (rt5640->jack) {}" block,
grouping it together with the disabling of the IRQ which queues the work
in the first place.

This also makes suspend() symetrical with resume() which re-queues the work
in an "if (rt5640->jack) {}" block.

Cc: Oder Chiou <oder_chiou@realtek.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20230912113245.320159-7-hdegoede@redhat.com
Signed-off-by: Mark Brown <broonie@kernel.org>
2023-09-12 14:37:51 +01:00
..
2021-04-20 17:25:51 +01:00
2023-08-14 13:10:36 +01:00
2023-07-25 14:06:08 +02:00
2023-05-25 10:54:21 +01:00
2023-01-31 12:10:50 +00:00
2023-07-23 23:33:05 +01:00
2023-08-11 21:12:45 +02:00
2021-03-31 18:00:38 +01:00
2023-01-31 11:04:55 +00:00
2022-06-06 12:33:10 +01:00
2023-08-10 00:19:02 +01:00
2023-08-13 19:38:00 +01:00
2023-08-13 19:37:49 +01:00
2023-08-13 19:37:50 +01:00
2023-08-13 19:37:52 +01:00
2020-05-07 13:18:04 +01:00
2023-08-13 19:37:52 +01:00
2022-10-13 13:01:32 +01:00
2023-08-13 19:37:53 +01:00
2023-08-17 22:38:42 +01:00
2023-08-13 19:37:54 +01:00
2023-08-13 19:37:56 +01:00
2023-08-13 19:37:58 +01:00
2021-12-06 10:04:05 +01:00
2022-07-08 11:52:42 +01:00
2021-12-06 10:04:05 +01:00
2020-07-20 15:34:29 +01:00
2020-10-02 21:05:29 +01:00