aboutsummaryrefslogtreecommitdiff
path: root/sound/soc/soc-jack.c
diff options
context:
space:
mode:
authorLiam Girdwood2012-11-19 14:39:14 +0000
committerMark Brown2012-11-21 11:39:54 +0900
commit008d55e258d8d9a5bfe03d652779cd14c770c60a (patch)
tree0805b1bbf1b5862e6da62b68a4bfd63e707aa0b2 /sound/soc/soc-jack.c
parent204b62c6bc1b8d3ce405c59281585af523b14172 (diff)
ASoC: Jack: Standardise ASoC Jack messages
Currently ASoC has a mixture of message prefixes e.g. "ASoC", "asoc" or none and message types e.g. pr_debug or dev_dbg. Make sure all ASoC core messages use the same "ASoC" prefix and convert any component device specific messages to use dev_dbg instead of pr_debug. Signed-off-by: Liam Girdwood <lrg@ti.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/soc-jack.c')
-rw-r--r--sound/soc/soc-jack.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/sound/soc/soc-jack.c b/sound/soc/soc-jack.c
index 1ab5fe04bfcc..8da7d8a8ee70 100644
--- a/sound/soc/soc-jack.c
+++ b/sound/soc/soc-jack.c
@@ -172,12 +172,13 @@ int snd_soc_jack_add_pins(struct snd_soc_jack *jack, int count,
for (i = 0; i < count; i++) {
if (!pins[i].pin) {
- printk(KERN_ERR "No name for pin %d\n", i);
+ dev_err(jack->codec->dev, "ASoC: No name for pin %d\n",
+ i);
return -EINVAL;
}
if (!pins[i].mask) {
- printk(KERN_ERR "No mask for pin %d (%s)\n", i,
- pins[i].pin);
+ dev_err(jack->codec->dev, "ASoC: No mask for pin %d"
+ " (%s)\n", i, pins[i].pin);
return -EINVAL;
}
@@ -297,13 +298,13 @@ int snd_soc_jack_add_gpios(struct snd_soc_jack *jack, int count,
for (i = 0; i < count; i++) {
if (!gpio_is_valid(gpios[i].gpio)) {
- printk(KERN_ERR "Invalid gpio %d\n",
+ dev_err(jack->codec->dev, "ASoC: Invalid gpio %d\n",
gpios[i].gpio);
ret = -EINVAL;
goto undo;
}
if (!gpios[i].name) {
- printk(KERN_ERR "No name for gpio %d\n",
+ dev_err(jack->codec->dev, "ASoC: No name for gpio %d\n",
gpios[i].gpio);
ret = -EINVAL;
goto undo;
@@ -332,7 +333,7 @@ int snd_soc_jack_add_gpios(struct snd_soc_jack *jack, int count,
if (gpios[i].wake) {
ret = irq_set_irq_wake(gpio_to_irq(gpios[i].gpio), 1);
if (ret != 0)
- printk(KERN_ERR
+ dev_err(jack->codec->dev, "ASoC: "
"Failed to mark GPIO %d as wake source: %d\n",
gpios[i].gpio, ret);
}