Commit 9d563eb9 authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Mark Brown

Revert "ASoC: core: use component driver name as component name"

Using component driver as a name is not unique and it breaks audio in
certain configurations, e.g. Hardkernel Odroid XU3 board where following
components are registered:
 - "3830000.i2s" with driver name "snd_dmaengine_pcm"
 - "3830000.i2s-sec" with driver name "snd_dmaengine_pcm"
 - "3830000.i2s" with driver name "samsung-i2s"

This reverts commit b19671d6.
Signed-off-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 1d9c95c1
...@@ -3113,10 +3113,7 @@ static int snd_soc_component_initialize(struct snd_soc_component *component, ...@@ -3113,10 +3113,7 @@ static int snd_soc_component_initialize(struct snd_soc_component *component,
{ {
struct snd_soc_dapm_context *dapm; struct snd_soc_dapm_context *dapm;
if (driver->name) component->name = fmt_single_name(dev, &component->id);
component->name = kstrdup(driver->name, GFP_KERNEL);
else
component->name = fmt_single_name(dev, &component->id);
if (!component->name) { if (!component->name) {
dev_err(dev, "ASoC: Failed to allocate name\n"); dev_err(dev, "ASoC: Failed to allocate name\n");
return -ENOMEM; return -ENOMEM;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment