alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@nvidia.com>
To: broonie@opensource.wolfsonmicro.com, lrg@slimlogic.co.uk
Cc: linux-tegra@vger.kernel.org, alsa-devel@alsa-project.org,
	Stephen Warren <swarren@nvidia.com>
Subject: [PATCH 5/7] ASoC: Tegra: Harmony: Use dev_err not pr_err
Date: Fri, 28 Jan 2011 14:26:39 -0700	[thread overview]
Message-ID: <1296250001-6348-5-git-send-email-swarren@nvidia.com> (raw)
In-Reply-To: <1296250001-6348-1-git-send-email-swarren@nvidia.com>

Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
 sound/soc/tegra/harmony.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/sound/soc/tegra/harmony.c b/sound/soc/tegra/harmony.c
index b5311a3..76793a9 100644
--- a/sound/soc/tegra/harmony.c
+++ b/sound/soc/tegra/harmony.c
@@ -48,7 +48,6 @@
 #include "tegra_asoc_utils.h"
 
 #define DRV_NAME "tegra-snd-harmony"
-#define PREFIX DRV_NAME ": "
 
 struct tegra_harmony {
 	struct harmony_audio_platform_data *pdata;
@@ -61,6 +60,8 @@ static int harmony_asoc_hw_params(struct snd_pcm_substream *substream,
 	struct snd_soc_pcm_runtime *rtd = substream->private_data;
 	struct snd_soc_dai *codec_dai = rtd->codec_dai;
 	struct snd_soc_dai *cpu_dai = rtd->cpu_dai;
+	struct snd_soc_codec *codec = rtd->codec;
+	struct snd_soc_card *card = codec->card;
 	int srate, mclk, mclk_change;
 	int err;
 
@@ -81,7 +82,7 @@ static int harmony_asoc_hw_params(struct snd_pcm_substream *substream,
 
 	err = tegra_asoc_utils_set_rate(srate, mclk, &mclk_change);
 	if (err < 0) {
-		pr_err(PREFIX "Can't configure clocks\n");
+		dev_err(card->dev, "Can't configure clocks\n");
 		return err;
 	}
 
@@ -90,7 +91,7 @@ static int harmony_asoc_hw_params(struct snd_pcm_substream *substream,
 					SND_SOC_DAIFMT_NB_NF |
 					SND_SOC_DAIFMT_CBS_CFS);
 	if (err < 0) {
-		pr_err(PREFIX "codec_dai fmt not set\n");
+		dev_err(card->dev, "codec_dai fmt not set\n");
 		return err;
 	}
 
@@ -99,7 +100,7 @@ static int harmony_asoc_hw_params(struct snd_pcm_substream *substream,
 					SND_SOC_DAIFMT_NB_NF |
 					SND_SOC_DAIFMT_CBS_CFS);
 	if (err < 0) {
-		pr_err(PREFIX "cpu_dai fmt not set\n");
+		dev_err(card->dev, "cpu_dai fmt not set\n");
 		return err;
 	}
 
@@ -107,7 +108,7 @@ static int harmony_asoc_hw_params(struct snd_pcm_substream *substream,
 		err = snd_soc_dai_set_sysclk(codec_dai, 0, mclk,
 					     SND_SOC_CLOCK_IN);
 		if (err < 0) {
-			pr_err(PREFIX "codec_dai clock not set\n");
+			dev_err(card->dev, "codec_dai clock not set\n");
 			return err;
 		}
 	}
-- 
1.7.1

  parent reply	other threads:[~2011-01-28 21:27 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-28 21:26 [PATCH 1/7] ASoC: Move card list initialization to snd_soc_register_card Stephen Warren
2011-01-28 21:26 ` [PATCH 2/7] ASoC: Tegra: Harmony: Don't use soc-audio platform device Stephen Warren
2011-01-28 21:26 ` [PATCH 3/7] ASoC: Tegra: Harmony: Support the internal speaker Stephen Warren
2011-01-31 13:14   ` Mark Brown
2011-01-28 21:26 ` [PATCH 4/7] ASoC: Tegra: Harmony: Fix indentation issue Stephen Warren
2011-01-28 21:26 ` Stephen Warren [this message]
2011-01-28 21:26 ` [PATCH 6/7] ASoC: Tegra: utils: Don't use global variables Stephen Warren
2011-01-28 21:26 ` [PATCH 7/7] ASoC: Tegra: I2S: Use dev_err not pr_err Stephen Warren
2011-01-31 12:08 ` [PATCH 1/7] ASoC: Move card list initialization to snd_soc_register_card Liam Girdwood
2011-01-31 13:17 ` 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=1296250001-6348-5-git-send-email-swarren@nvidia.com \
    --to=swarren@nvidia.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=linux-tegra@vger.kernel.org \
    --cc=lrg@slimlogic.co.uk \
    /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;
as well as URLs for NNTP newsgroup(s).