From 157936199385fbd16d5e25152ac07a246e64a6e1 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Thu, 23 Jul 2026 06:35:01 +0000 Subject: [PATCH] ASoC: soc-core: remove dev from soc_component_initialize() Component already has component->dev. No longer need to set dev on soc_component_initialize(). Remove it. Signed-off-by: Kuninori Morimoto Reviewed-by: Cezary Rojewski Link: https://patch.msgid.link/87h5lqrz6z.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown --- sound/soc/soc-core.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index ec23ba261897..b9c70268d49f 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -2708,9 +2708,10 @@ static void snd_soc_del_component_unlocked(struct snd_soc_component *component) } static int soc_component_initialize(struct snd_soc_component *component, - const struct snd_soc_component_driver *driver, - struct device *dev) + const struct snd_soc_component_driver *driver) { + struct device *dev = component->dev; + component->dapm = snd_soc_dapm_alloc(dev); if (!component->dapm) return -ENOMEM; @@ -2730,7 +2731,6 @@ static int soc_component_initialize(struct snd_soc_component *component, } } - component->dev = dev; component->driver = driver; return 0; @@ -2785,7 +2785,7 @@ int snd_soc_register_component_c(struct snd_soc_component *component, { int ret; - ret = soc_component_initialize(component, component_driver, component->dev); + ret = soc_component_initialize(component, component_driver); if (ret < 0) return ret;