linux-stable/sound/soc/sh
Kuninori Morimoto 0246c661b6
ASoC: rsnd: use ring buffer for rsnd_mod_name()
commit c0ea089dba ("ASoC: rsnd: rsnd_mod_name() handles both name and
ID") merged "name" and "ID" on rsnd_mod_name() to handle sub-ID
(= for CTU/BUSIF).
Then, it decided to share static char to avoid pointless memory.
But, it doesn't work correctry in below case, because last called
name will be used.

	dev_xxx(dev, "%s is connected to %s\n",
		rsnd_mod_name(mod_a),  /* ssiu[00] */
		rsnd_mod_name(mod_b)); /* ssi[0]   */
	->
	rcar_sound ec500000.sound: ssi[0] is connected to ssi[0]
	                           ~~~~~~                 ~~~~~~
We still don't want to have pointless memory, so let's use ring buffer.
16byte x 5 is very enough for this purpose.

	dev_xxx(dev, "%s is connected to %s\n",
		rsnd_mod_name(mod_a),  /* ssiu[00] */
		rsnd_mod_name(mod_b)); /* ssi[0]   */
	->
	rcar_sound ec500000.sound: ssiu[00] is connected to ssi[0]
	                           ~~~~~~~~                 ~~~~~~
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Signed-off-by: Mark Brown <broonie@kernel.org>
2018-11-09 15:45:11 +00:00
..
rcar ASoC: rsnd: use ring buffer for rsnd_mod_name() 2018-11-09 15:45:11 +00:00
dma-sh7760.c ASoC: dma-sh7760: convert to SPDX identifiers 2018-06-18 12:16:57 +01:00
fsi.c ASoC: fsi: convert to SPDX identifiers 2018-06-18 12:16:25 +01:00
hac.c ASoC: sh: use devm_snd_soc_register_component() 2018-09-10 15:14:38 +01:00
Kconfig ASoC: sh: Kconfig: convert to SPDX identifiers 2018-07-30 12:02:29 +01:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
migor.c ASoC: migor: convert to SPDX identifiers 2018-06-18 12:16:50 +01:00
sh7760-ac97.c ASoC: sh7760-ac97: convert to SPDX identifiers 2018-06-18 12:17:01 +01:00
siu.h ASoC: siu: convert to SPDX identifiers 2018-06-18 12:16:42 +01:00
siu_dai.c ASoC: siu: convert to SPDX identifiers 2018-06-18 12:16:42 +01:00
siu_pcm.c ASoC: siu: convert to SPDX identifiers 2018-06-18 12:16:42 +01:00
ssi.c ASoC: ssi: convert to SPDX identifiers 2018-06-18 12:16:37 +01:00