Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 008d55e2 authored by Liam Girdwood's avatar Liam Girdwood Committed by Mark Brown
Browse files

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: default avatarLiam Girdwood <lrg@ti.com>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent 204b62c6
Loading
Loading
Loading
Loading
+7 −6
Original line number Original line Diff line number Diff line
@@ -172,12 +172,13 @@ int snd_soc_jack_add_pins(struct snd_soc_jack *jack, int count,


	for (i = 0; i < count; i++) {
	for (i = 0; i < count; i++) {
		if (!pins[i].pin) {
		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;
			return -EINVAL;
		}
		}
		if (!pins[i].mask) {
		if (!pins[i].mask) {
			printk(KERN_ERR "No mask for pin %d (%s)\n", i,
			dev_err(jack->codec->dev, "ASoC: No mask for pin %d"
			       pins[i].pin);
				" (%s)\n", i, pins[i].pin);
			return -EINVAL;
			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++) {
	for (i = 0; i < count; i++) {
		if (!gpio_is_valid(gpios[i].gpio)) {
		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);
				gpios[i].gpio);
			ret = -EINVAL;
			ret = -EINVAL;
			goto undo;
			goto undo;
		}
		}
		if (!gpios[i].name) {
		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);
				gpios[i].gpio);
			ret = -EINVAL;
			ret = -EINVAL;
			goto undo;
			goto undo;
@@ -332,7 +333,7 @@ int snd_soc_jack_add_gpios(struct snd_soc_jack *jack, int count,
		if (gpios[i].wake) {
		if (gpios[i].wake) {
			ret = irq_set_irq_wake(gpio_to_irq(gpios[i].gpio), 1);
			ret = irq_set_irq_wake(gpio_to_irq(gpios[i].gpio), 1);
			if (ret != 0)
			if (ret != 0)
				printk(KERN_ERR
				dev_err(jack->codec->dev, "ASoC: "
				  "Failed to mark GPIO %d as wake source: %d\n",
				  "Failed to mark GPIO %d as wake source: %d\n",
					gpios[i].gpio, ret);
					gpios[i].gpio, ret);
		}
		}