Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
To: lgirdwood@gmail.com, broonie@kernel.org,
	kuninori.morimoto.gx@renesas.com,
	amadeuszx.slawinski@linux.intel.com
Cc: pierre-louis.bossart@linux.intel.com, cezary.rojewski@intel.com,
	kai.vehmanen@linux.intel.com, alsa-devel@alsa-project.org,
	tiwai@suse.com, ranjani.sridharan@linux.intel.com
Subject: [PATCH 2/2] ASoC: topology: Set correct unload callback for graph type
Date: Wed,  1 Feb 2023 13:28:46 +0200	[thread overview]
Message-ID: <20230201112846.27707-3-peter.ujfalusi@linux.intel.com> (raw)
In-Reply-To: <20230201112846.27707-1-peter.ujfalusi@linux.intel.com>

Using the control_unload for graph type of elem will lead surprises on
module unload.

The correct callback to use is the dapm_route_unload.

Fixes: 31e9273912bf ("ASoC: topology: Use unload() op directly")
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
---
 sound/soc/soc-topology.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/soc-topology.c b/sound/soc/soc-topology.c
index caf547816ea7..78223603088e 100644
--- a/sound/soc/soc-topology.c
+++ b/sound/soc/soc-topology.c
@@ -1081,7 +1081,7 @@ static int soc_tplg_dapm_graph_elems_load(struct soc_tplg *tplg,
 		/* add route dobj to dobj_list */
 		route->dobj.type = SND_SOC_DOBJ_GRAPH;
 		if (tplg->ops)
-			route->dobj.unload = tplg->ops->control_unload;
+			route->dobj.unload = tplg->ops->dapm_route_unload;
 		route->dobj.index = tplg->index;
 		list_add(&route->dobj.list, &tplg->comp->dobj_list);
 
-- 
2.39.1


  parent reply	other threads:[~2023-02-01 11:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-01 11:28 [PATCH 0/2] ASoC: (SOF) topology: Regression fixes for next Peter Ujfalusi
2023-02-01 11:28 ` [PATCH 1/2] ASoC: SOF: topology: Add missed "else" in sof_connect_dai_widget Peter Ujfalusi
2023-02-01 23:59   ` Kuninori Morimoto
2023-02-01 11:28 ` Peter Ujfalusi [this message]
2023-02-01 11:47   ` [PATCH 2/2] ASoC: topology: Set correct unload callback for graph type Amadeusz Sławiński
2023-02-03 14:55 ` [PATCH 0/2] ASoC: (SOF) topology: Regression fixes for next Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230201112846.27707-3-peter.ujfalusi@linux.intel.com \
    --to=peter.ujfalusi@linux.intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=amadeuszx.slawinski@linux.intel.com \
    --cc=broonie@kernel.org \
    --cc=cezary.rojewski@intel.com \
    --cc=kai.vehmanen@linux.intel.com \
    --cc=kuninori.morimoto.gx@renesas.com \
    --cc=lgirdwood@gmail.com \
    --cc=pierre-louis.bossart@linux.intel.com \
    --cc=ranjani.sridharan@linux.intel.com \
    --cc=tiwai@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox