linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be()
@ 2020-02-19 11:50 Jerome Brunet
  2020-02-19 21:53 ` Pierre-Louis Bossart
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Jerome Brunet @ 2020-02-19 11:50 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood
  Cc: Jerome Brunet, alsa-devel, linux-kernel, Kuninori Morimoto

Now that dpcm_get_be() is used in dpcm_end_walk_at_be(), it is not a error
if this function does not find a BE for the provided widget. Remove the
related dev_err() trace which is confusing since things might be working
as expected.

When called from dpcm_add_paths(), it is an error if dpcm_get_be() fails to
find a BE for the provided widget. The necessary error trace is already
done in this case.

Fixes: 027a48387183 ("ASoC: soc-pcm: use dpcm_get_be() at dpcm_end_walk_at_be()")
Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
---
 sound/soc/soc-pcm.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c
index 63f67eb7c077..aff27c8599ef 100644
--- a/sound/soc/soc-pcm.c
+++ b/sound/soc/soc-pcm.c
@@ -1270,9 +1270,7 @@ static struct snd_soc_pcm_runtime *dpcm_get_be(struct snd_soc_card *card,
 		}
 	}
 
-	/* dai link name and stream name set correctly ? */
-	dev_err(card->dev, "ASoC: can't get %s BE for %s\n",
-		stream ? "capture" : "playback", widget->name);
+	/* Widget provided is not a BE */
 	return NULL;
 }
 
-- 
2.24.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be()
  2020-02-19 11:50 [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be() Jerome Brunet
@ 2020-02-19 21:53 ` Pierre-Louis Bossart
  2020-02-20  0:02 ` Kuninori Morimoto
  2020-02-20 12:52 ` Applied "ASoC: dpcm: remove confusing trace in dpcm_get_be()" to the asoc tree Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Pierre-Louis Bossart @ 2020-02-19 21:53 UTC (permalink / raw)
  To: Jerome Brunet, Mark Brown, Liam Girdwood
  Cc: alsa-devel, linux-kernel, Kuninori Morimoto, Kai Vehmanen



On 2/19/20 5:50 AM, Jerome Brunet wrote:
> Now that dpcm_get_be() is used in dpcm_end_walk_at_be(), it is not a error
> if this function does not find a BE for the provided widget. Remove the
> related dev_err() trace which is confusing since things might be working
> as expected.
> 
> When called from dpcm_add_paths(), it is an error if dpcm_get_be() fails to
> find a BE for the provided widget. The necessary error trace is already
> done in this case.
> 
> Fixes: 027a48387183 ("ASoC: soc-pcm: use dpcm_get_be() at dpcm_end_walk_at_be()")
> Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>

Good catch, this error log is indeed unnecessary, I see more than 30 
lines of 'can't get capture/playback BE' for all the non-BE widgets in 
our topologies (PCM, buffers, PGA, EQ, etc).

Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

> ---
>   sound/soc/soc-pcm.c | 4 +---
>   1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c
> index 63f67eb7c077..aff27c8599ef 100644
> --- a/sound/soc/soc-pcm.c
> +++ b/sound/soc/soc-pcm.c
> @@ -1270,9 +1270,7 @@ static struct snd_soc_pcm_runtime *dpcm_get_be(struct snd_soc_card *card,
>   		}
>   	}
>   
> -	/* dai link name and stream name set correctly ? */
> -	dev_err(card->dev, "ASoC: can't get %s BE for %s\n",
> -		stream ? "capture" : "playback", widget->name);
> +	/* Widget provided is not a BE */
>   	return NULL;
>   }
>   
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be()
  2020-02-19 11:50 [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be() Jerome Brunet
  2020-02-19 21:53 ` Pierre-Louis Bossart
@ 2020-02-20  0:02 ` Kuninori Morimoto
  2020-02-20 12:52 ` Applied "ASoC: dpcm: remove confusing trace in dpcm_get_be()" to the asoc tree Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Kuninori Morimoto @ 2020-02-20  0:02 UTC (permalink / raw)
  To: Jerome Brunet; +Cc: Mark Brown, Liam Girdwood, alsa-devel, linux-kernel


Hi Jerome

Thank you for your patch

> Now that dpcm_get_be() is used in dpcm_end_walk_at_be(), it is not a error
> if this function does not find a BE for the provided widget. Remove the
> related dev_err() trace which is confusing since things might be working
> as expected.
> 
> When called from dpcm_add_paths(), it is an error if dpcm_get_be() fails to
> find a BE for the provided widget. The necessary error trace is already
> done in this case.
> 
> Fixes: 027a48387183 ("ASoC: soc-pcm: use dpcm_get_be() at dpcm_end_walk_at_be()")
> Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
> ---

Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Thank you for your help !!
Best regards
---
Kuninori Morimoto

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Applied "ASoC: dpcm: remove confusing trace in dpcm_get_be()" to the asoc tree
  2020-02-19 11:50 [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be() Jerome Brunet
  2020-02-19 21:53 ` Pierre-Louis Bossart
  2020-02-20  0:02 ` Kuninori Morimoto
@ 2020-02-20 12:52 ` Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Mark Brown @ 2020-02-20 12:52 UTC (permalink / raw)
  To: Jerome Brunet
  Cc: alsa-devel, Kuninori Morimoto, Liam Girdwood, linux-kernel,
	Mark Brown, Pierre-Louis Bossart

The patch

   ASoC: dpcm: remove confusing trace in dpcm_get_be()

has been applied to the asoc tree at

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git 

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.  

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

From 9d6ee3656a9fbfe906be5ce6f828f1639da1ee7f Mon Sep 17 00:00:00 2001
From: Jerome Brunet <jbrunet@baylibre.com>
Date: Wed, 19 Feb 2020 12:50:48 +0100
Subject: [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be()

Now that dpcm_get_be() is used in dpcm_end_walk_at_be(), it is not a error
if this function does not find a BE for the provided widget. Remove the
related dev_err() trace which is confusing since things might be working
as expected.

When called from dpcm_add_paths(), it is an error if dpcm_get_be() fails to
find a BE for the provided widget. The necessary error trace is already
done in this case.

Fixes: 027a48387183 ("ASoC: soc-pcm: use dpcm_get_be() at dpcm_end_walk_at_be()")
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
Tested-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/20200219115048.934678-1-jbrunet@baylibre.com
Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/soc-pcm.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c
index 63f67eb7c077..aff27c8599ef 100644
--- a/sound/soc/soc-pcm.c
+++ b/sound/soc/soc-pcm.c
@@ -1270,9 +1270,7 @@ static struct snd_soc_pcm_runtime *dpcm_get_be(struct snd_soc_card *card,
 		}
 	}
 
-	/* dai link name and stream name set correctly ? */
-	dev_err(card->dev, "ASoC: can't get %s BE for %s\n",
-		stream ? "capture" : "playback", widget->name);
+	/* Widget provided is not a BE */
 	return NULL;
 }
 
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-02-20 12:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-19 11:50 [PATCH] ASoC: dpcm: remove confusing trace in dpcm_get_be() Jerome Brunet
2020-02-19 21:53 ` Pierre-Louis Bossart
2020-02-20  0:02 ` Kuninori Morimoto
2020-02-20 12:52 ` Applied "ASoC: dpcm: remove confusing trace in dpcm_get_be()" to the asoc tree Mark Brown

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).