ASoC: mchp-pdmc: add support for suspend to RAM
authorClaudiu Beznea <claudiu.beznea@microchip.com>
Tue, 13 Dec 2022 11:28:50 +0000 (13:28 +0200)
committerMark Brown <broonie@kernel.org>
Sun, 25 Dec 2022 23:33:17 +0000 (23:33 +0000)
commit404c61c47d84bf1662e9d698e4f0c42898893c59
treec8cbfb6963493b3f81f92186515c809f39b1b0c4
parente8c8e9de4ee3e9e1231b4f179c3f0e340bc2b1cf
ASoC: mchp-pdmc: add support for suspend to RAM

Add support for suspend to RAM by re-aranging the lines in switch..case
from mchp_pdmc_trigger() and saving/restoring the enabled interrupts. These
are necessary as AT91 devices has a special power saving mode (called
backup and self-refresh) where most of the SoC parts are powered off
and thus we need to reconfigure the PDMC on resume.

Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Link: https://lore.kernel.org/r/20221213112851.89212-4-claudiu.beznea@microchip.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/atmel/mchp-pdmc.c