From 49435a2edfec05b076e4e642053b003c78192928 Mon Sep 17 00:00:00 2001 From: Meng Wang Date: Tue, 19 Jan 2021 09:13:27 +0800 Subject: [PATCH] asoc: swr-dmic: add ignore_suspend for VA widgets Add ignore_suspend for SWR DMIC VA widgets. Change-Id: I77a35f983d40762b8363de541d062724fb5ee5ae Signed-off-by: Meng Wang --- asoc/codecs/swr-dmic.c | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/asoc/codecs/swr-dmic.c b/asoc/codecs/swr-dmic.c index bfcdf1323e96..8d8e310ea05a 100644 --- a/asoc/codecs/swr-dmic.c +++ b/asoc/codecs/swr-dmic.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0-only /* - * Copyright (c) 2019-2020, The Linux Foundation. All rights reserved. + * Copyright (c) 2019-2021, The Linux Foundation. All rights reserved. */ #include @@ -394,6 +394,21 @@ static int swr_dmic_codec_probe(struct snd_soc_component *component) strlcat(w_name, " SWR_DMIC_OUTPUT", sizeof(w_name)); snd_soc_dapm_ignore_suspend(dapm, w_name); + memset(w_name, 0, sizeof(w_name)); + strlcpy(w_name, component->name_prefix, sizeof(w_name)); + strlcat(w_name, " VA_SWR_DMIC", sizeof(w_name)); + snd_soc_dapm_ignore_suspend(dapm, w_name); + + memset(w_name, 0, sizeof(w_name)); + strlcpy(w_name, component->name_prefix, sizeof(w_name)); + strlcat(w_name, " SMIC_VA_PORT_EN", sizeof(w_name)); + snd_soc_dapm_ignore_suspend(dapm, w_name); + + memset(w_name, 0, sizeof(w_name)); + strlcpy(w_name, component->name_prefix, sizeof(w_name)); + strlcat(w_name, " SWR_DMIC_VA_OUTPUT", sizeof(w_name)); + snd_soc_dapm_ignore_suspend(dapm, w_name); + snd_soc_dapm_sync(dapm); swr_dmic->nblock.notifier_call = swr_dmic_event_notify;