diff mbox

[1/2] ASoC: arizona: Add debug prints for output power up/down times

Message ID 1474990545-29282-1-git-send-email-ckeepax@opensource.wolfsonmicro.com (mailing list archive)
State Accepted
Commit d605bd024e085ba7fe0fbedf1707d339ea9cc0af
Headers show

Commit Message

Charles Keepax Sept. 27, 2016, 3:35 p.m. UTC
When debugging it is useful to check the total power up/down delay that
is executed as part of the coalesced output delay. This patch adds some
debug prints for this.

Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
---
 sound/soc/codecs/arizona.c | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Mark Brown Sept. 27, 2016, 4:04 p.m. UTC | #1
On Tue, Sep 27, 2016 at 04:35:44PM +0100, Charles Keepax wrote:
> When debugging it is useful to check the total power up/down delay that
> is executed as part of the coalesced output delay. This patch adds some
> debug prints for this.

This doesn't apply against current code, please check and resend.
diff mbox

Patch

diff --git a/sound/soc/codecs/arizona.c b/sound/soc/codecs/arizona.c
index 780cf4f..eaf1dbb 100644
--- a/sound/soc/codecs/arizona.c
+++ b/sound/soc/codecs/arizona.c
@@ -891,6 +891,8 @@  int arizona_out_ev(struct snd_soc_dapm_widget *w,
 		case ARIZONA_OUT3R_ENA_SHIFT:
 			priv->out_up_pending--;
 			if (!priv->out_up_pending) {
+				dev_dbg(codec->dev, "Power up delay: %d\n",
+					priv->out_up_delay);
 				msleep(priv->out_up_delay);
 				priv->out_up_delay = 0;
 			}
@@ -925,6 +927,8 @@  int arizona_out_ev(struct snd_soc_dapm_widget *w,
 		case ARIZONA_OUT3R_ENA_SHIFT:
 			priv->out_down_pending--;
 			if (!priv->out_down_pending) {
+				dev_dbg(codec->dev, "Power down delay: %d\n",
+					priv->out_down_delay);
 				msleep(priv->out_down_delay);
 				priv->out_down_delay = 0;
 			}