ASoC: cs42l43: Disable IRQs in system suspend

Currently the MFD driver disables all the IRQs upon entering system
suspend, however there are some issues with this approach. As this
device uses runtime force suspend.

The regmap IRQ handler can run, claim a PM runtime reference and get
scheduled, the MFD can then force suspend. When the IRQ thread gets
rescheduled it will try to access volatile registers on the
suspended device. Furthermore, this race also applies to work queue
items scheduled by the IRQ handlers.

As the MFD code doesn't know about the individual work queue items, the
end drivers must mask their own IRQs and sync in any work queues as part
of entering system suspend. Update the code here to do so.

Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Message-ID: <20250903094549.271068-4-ckeepax@opensource.cirrus.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Charles Keepax 2025-09-03 10:45:46 +01:00 • committed by Mark Brown
commit a69b4ba19a
No known key found for this signature in database
GPG key ID: 24D68B725D5487D0
2 changed files with 64 additions and 15 deletions