From: yang.a.fang@intel.com
To: broonie@kernel.org, lgirdwood@gmail.com
Cc: alsa-devel@alsa-project.org, srinivas.sripathi@intel.com,
Anish.Kumar@maximintegrated.com, praveen.k.jain@intel.com,
denny.iriawan@intel.com, "Fang, Yang A" <yang.a.fang@intel.com>,
sathyanarayana.nujella@intel.com, ullysses.a.eoff@intel.com,
kevin.strasser@linux.intel.com, dgreid@chromium.org
Subject: [PATCH 1/2] ASoC: extend seq_notifier callback interface
Date: Thu, 6 Aug 2015 16:15:44 -0700 [thread overview]
Message-ID: <1438902946-49633-1-git-send-email-yang.a.fang@intel.com> (raw)
From: "Fang, Yang A" <yang.a.fang@intel.com>
This is needed for some codec driver to know whether
it is power up/down sequence call from dapm
Signed-off-by: Fang, Yang A <yang.a.fang@intel.com>
---
include/sound/soc-dapm.h | 2 +-
include/sound/soc.h | 2 +-
sound/soc/codecs/wm5100.c | 2 +-
sound/soc/codecs/wm8903.c | 2 +-
sound/soc/codecs/wm8996.c | 2 +-
sound/soc/soc-dapm.c | 5 ++---
6 files changed, 7 insertions(+), 8 deletions(-)
diff --git a/include/sound/soc-dapm.h b/include/sound/soc-dapm.h
index 37d95a8..1d017a3 100644
--- a/include/sound/soc-dapm.h
+++ b/include/sound/soc-dapm.h
@@ -607,7 +607,7 @@ struct snd_soc_dapm_context {
/* Go to BIAS_OFF in suspend if the DAPM context is idle */
unsigned int suspend_bias_off:1;
void (*seq_notifier)(struct snd_soc_dapm_context *,
- enum snd_soc_dapm_type, int);
+ enum snd_soc_dapm_type, int, bool);
struct device *dev; /* from parent - for debug */
struct snd_soc_component *component; /* parent component */
diff --git a/include/sound/soc.h b/include/sound/soc.h
index add5097..0072e21 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -875,7 +875,7 @@ struct snd_soc_codec_driver {
bool suspend_bias_off;
void (*seq_notifier)(struct snd_soc_dapm_context *,
- enum snd_soc_dapm_type, int);
+ enum snd_soc_dapm_type, int, bool);
bool ignore_pmdown_time; /* Doesn't benefit from pmdown delay */
};
diff --git a/sound/soc/codecs/wm5100.c b/sound/soc/codecs/wm5100.c
index 8120b0c..6f4e6c3 100644
--- a/sound/soc/codecs/wm5100.c
+++ b/sound/soc/codecs/wm5100.c
@@ -733,7 +733,7 @@ WM5100_MIXER_CONTROLS("LHPF4", WM5100_HPLP4MIX_INPUT_1_SOURCE),
};
static void wm5100_seq_notifier(struct snd_soc_dapm_context *dapm,
- enum snd_soc_dapm_type event, int subseq)
+ enum snd_soc_dapm_type event, int subseq, bool power_up)
{
struct snd_soc_codec *codec = snd_soc_dapm_to_codec(dapm);
struct wm5100_priv *wm5100 = snd_soc_codec_get_drvdata(codec);
diff --git a/sound/soc/codecs/wm8903.c b/sound/soc/codecs/wm8903.c
index b011253..12da3b1 100644
--- a/sound/soc/codecs/wm8903.c
+++ b/sound/soc/codecs/wm8903.c
@@ -280,7 +280,7 @@ static int wm8903_dcs_event(struct snd_soc_dapm_widget *w,
#define WM8903_DCS_MODE_START_STOP 2
static void wm8903_seq_notifier(struct snd_soc_dapm_context *dapm,
- enum snd_soc_dapm_type event, int subseq)
+ enum snd_soc_dapm_type event, int subseq, bool power_up)
{
struct snd_soc_codec *codec = snd_soc_dapm_to_codec(dapm);
struct wm8903_priv *wm8903 = snd_soc_codec_get_drvdata(codec);
diff --git a/sound/soc/codecs/wm8996.c b/sound/soc/codecs/wm8996.c
index 2a696db..f12a900 100644
--- a/sound/soc/codecs/wm8996.c
+++ b/sound/soc/codecs/wm8996.c
@@ -686,7 +686,7 @@ static void wait_for_dc_servo(struct snd_soc_codec *codec, u16 mask)
}
static void wm8996_seq_notifier(struct snd_soc_dapm_context *dapm,
- enum snd_soc_dapm_type event, int subseq)
+ enum snd_soc_dapm_type event, int subseq, bool power_up)
{
struct snd_soc_codec *codec = snd_soc_dapm_to_codec(dapm);
struct wm8996_priv *wm8996 = snd_soc_codec_get_drvdata(codec);
diff --git a/sound/soc/soc-dapm.c b/sound/soc/soc-dapm.c
index 1992568..ebea2d3 100644
--- a/sound/soc/soc-dapm.c
+++ b/sound/soc/soc-dapm.c
@@ -1528,8 +1528,7 @@ static void dapm_seq_run(struct snd_soc_card *card,
for (i = 0; i < ARRAY_SIZE(dapm_up_seq); i++)
if (sort[i] == cur_sort)
cur_dapm->seq_notifier(cur_dapm,
- i,
- cur_subseq);
+ i, cur_subseq, power_up);
}
if (cur_dapm && w->dapm != cur_dapm)
@@ -1591,7 +1590,7 @@ static void dapm_seq_run(struct snd_soc_card *card,
for (i = 0; i < ARRAY_SIZE(dapm_up_seq); i++)
if (sort[i] == cur_sort)
cur_dapm->seq_notifier(cur_dapm,
- i, cur_subseq);
+ i, cur_subseq, power_up);
}
list_for_each_entry(d, &card->dapm_list, list) {
--
1.7.9.5
next reply other threads:[~2015-08-06 23:16 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-06 23:15 yang.a.fang [this message]
2015-08-06 23:15 ` [PATCH 2/2] ASoC: max98090: Enforce correct device sequencing when configuring a new yang.a.fang
2015-08-07 10:43 ` Mark Brown
2015-08-07 20:50 ` Fang, Yang A
2015-08-07 21:08 ` [PATCH v2] " yang.a.fang
2015-08-07 21:41 ` Anish Kumar
2015-08-10 12:00 ` Applied "ASoC: max98090: Fix sequencing when starting additional routes" to the asoc tree Mark Brown
2015-08-07 10:44 ` [PATCH 1/2] ASoC: extend seq_notifier callback interface Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1438902946-49633-1-git-send-email-yang.a.fang@intel.com \
--to=yang.a.fang@intel.com \
--cc=Anish.Kumar@maximintegrated.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=denny.iriawan@intel.com \
--cc=dgreid@chromium.org \
--cc=kevin.strasser@linux.intel.com \
--cc=lgirdwood@gmail.com \
--cc=praveen.k.jain@intel.com \
--cc=sathyanarayana.nujella@intel.com \
--cc=srinivas.sripathi@intel.com \
--cc=ullysses.a.eoff@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox