ASoC: Explicitly say registerless widgets have no register
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Wed, 23 Mar 2011 20:45:40 +0000 (20:45 +0000)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Wed, 23 Mar 2011 23:12:24 +0000 (23:12 +0000)
This stops code that handles widgets generically from attempting to access
registers for these widgets.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Cc: stable@kernel.org
include/sound/soc-dapm.h

index 979ed84e07d65a78fb24798a72e2bd3976d5ec10..ddc2b3d6be03dd8ce694f04fcdaf16aca8e85c7a 100644 (file)
 /* platform domain */
 #define SND_SOC_DAPM_INPUT(wname) \
 {      .id = snd_soc_dapm_input, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0}
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM }
 #define SND_SOC_DAPM_OUTPUT(wname) \
 {      .id = snd_soc_dapm_output, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0}
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM }
 #define SND_SOC_DAPM_MIC(wname, wevent) \
 {      .id = snd_soc_dapm_mic, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0, .event = wevent, \
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM, .event = wevent, \
        .event_flags = SND_SOC_DAPM_PRE_PMU | SND_SOC_DAPM_POST_PMD}
 #define SND_SOC_DAPM_HP(wname, wevent) \
 {      .id = snd_soc_dapm_hp, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0, .event = wevent, \
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM, .event = wevent, \
        .event_flags = SND_SOC_DAPM_POST_PMU | SND_SOC_DAPM_PRE_PMD}
 #define SND_SOC_DAPM_SPK(wname, wevent) \
 {      .id = snd_soc_dapm_spk, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0, .event = wevent, \
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM, .event = wevent, \
        .event_flags = SND_SOC_DAPM_POST_PMU | SND_SOC_DAPM_PRE_PMD}
 #define SND_SOC_DAPM_LINE(wname, wevent) \
 {      .id = snd_soc_dapm_line, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0, .event = wevent, \
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM, .event = wevent, \
        .event_flags = SND_SOC_DAPM_POST_PMU | SND_SOC_DAPM_PRE_PMD}
 
 /* path domain */
 /* events that are pre and post DAPM */
 #define SND_SOC_DAPM_PRE(wname, wevent) \
 {      .id = snd_soc_dapm_pre, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0, .event = wevent, \
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM, .event = wevent, \
        .event_flags = SND_SOC_DAPM_PRE_PMU | SND_SOC_DAPM_PRE_PMD}
 #define SND_SOC_DAPM_POST(wname, wevent) \
 {      .id = snd_soc_dapm_post, .name = wname, .kcontrols = NULL, \
-       .num_kcontrols = 0, .event = wevent, \
+       .num_kcontrols = 0, .reg = SND_SOC_NOPM, .event = wevent, \
        .event_flags = SND_SOC_DAPM_POST_PMU | SND_SOC_DAPM_POST_PMD}
 
 /* stream domain */