Skip to contentSkip to conversation

ASoC: Add subsequence information to seq_notify callbacks

PATCH In review Mark Brown 2 participants 2 messages Jan 26, 2011 – Jan 27, 2011

Subsystems (2)
lore
Share & tools
lore

Mark Brown

author
#0 lore raw

PATCH 1/1 ASoC: Add subsequence information to seq_notify callbacks

Allows drivers to distinguish which subsequence is being notified when they get called back.

---
 include/sound/soc-dapm.h |    2 +-
 include/sound/soc.h      |    2 +-
 sound/soc/soc-dapm.c     |    5 +++--
 3 files changed, 5 insertions(+), 4 deletions(-)
include/sound/soc-dapm.h +1 -1
index 6a25e69..979ed84 100644
@@ -501,7 +501,7 @@ struct snd_soc_dapm_context {
 	struct snd_soc_dapm_update *update;
 
 	void (*seq_notifier)(struct snd_soc_dapm_context *,
-			     enum snd_soc_dapm_type);
+			     enum snd_soc_dapm_type, int);
 
 	struct device *dev; /* from parent - for debug */
 	struct snd_soc_codec *codec; /* parent codec */
include/sound/soc.h +1 -1
index 49a14da..ab0d5cd 100644
@@ -554,7 +554,7 @@ struct snd_soc_codec_driver {
 			      enum snd_soc_bias_level level);
 
 	void (*seq_notifier)(struct snd_soc_dapm_context *,
-			     enum snd_soc_dapm_type);
+			     enum snd_soc_dapm_type, int);
 };
 
 /* SoC platform interface */
sound/soc/soc-dapm.c +3 -2
index 37b376f..0f94fd0 100644
@@ -899,7 +899,8 @@ static void dapm_seq_run(struct snd_soc_dapm_context *dapm,
 				for (i = 0; i < ARRAY_SIZE(dapm_up_seq); i++)
 					if (sort[i] == cur_sort)
 						cur_dapm->seq_notifier(cur_dapm,
-								       i);
+								       i,
+								       cur_subseq);
 			}
 
 			INIT_LIST_HEAD(&pending);
@@ -968,7 +969,7 @@ static void dapm_seq_run(struct snd_soc_dapm_context *dapm,
 		for (i = 0; i < ARRAY_SIZE(dapm_up_seq); i++)
 			if (sort[i] == cur_sort)
 				cur_dapm->seq_notifier(cur_dapm,
-						       i);
+						       i, cur_subseq);
 	}
 }
 
Signature · 1 line
1.7.2.3
Acked-by on v1 1/1
#1 lore raw
Quoted 9 lines · Mark Brown

Allows drivers to distinguish which subsequence is being notified when they get called back.

---
 include/sound/soc-dapm.h |    2 +-
 include/sound/soc.h      |    2 +-
 sound/soc/soc-dapm.c     |    5 +++--
 3 files changed, 5 insertions(+), 4 deletions(-)
Signature · 3 lines
Freelance Developer, SlimLogic Ltd
ASoC and Voltage Regulator Maintainer.
http://www.slimlogic.co.uk