All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
To: Bard Liao <yung-chuan.liao@linux.intel.com>,
	Daniel Baluta <daniel.baluta@nxp.com>,
	Jaroslav Kysela <perex@perex.cz>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	Peter Ujfalusi <peter.ujfalusi@linux.intel.com>,
	Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>,
	Ranjani Sridharan <ranjani.sridharan@linux.intel.com>,
	Takashi Iwai <tiwai@suse.com>
Cc: Kai Vehmanen <kai.vehmanen@linux.intel.com>, alsa-devel@alsa-project.org
Subject: [PATCH v2 42/54] ASoC: sof: intel: convert not to use asoc_xxx()
Date: Tue, 26 Sep 2023 06:25:43 +0000	[thread overview]
Message-ID: <87pm25fo2h.wl-kuninori.morimoto.gx@renesas.com> (raw)
In-Reply-To: <87edilihhg.wl-kuninori.morimoto.gx@renesas.com>

ASoC is now unified asoc_xxx() into snd_soc_xxx().
This patch convert asoc_xxx() to snd_soc_xxx().

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 sound/soc/sof/intel/hda-dai-ops.c | 22 +++++++++++-----------
 sound/soc/sof/intel/hda-dai.c     |  8 ++++----
 sound/soc/sof/intel/hda-pcm.c     |  4 ++--
 sound/soc/sof/intel/hda-stream.c  |  2 +-
 4 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/sound/soc/sof/intel/hda-dai-ops.c b/sound/soc/sof/intel/hda-dai-ops.c
index 012a75f366ab..87935554b1e4 100644
--- a/sound/soc/sof/intel/hda-dai-ops.c
+++ b/sound/soc/sof/intel/hda-dai-ops.c
@@ -43,7 +43,7 @@ static bool hda_check_fes(struct snd_soc_pcm_runtime *rtd,
 static struct hdac_ext_stream *
 hda_link_stream_assign(struct hdac_bus *bus, struct snd_pcm_substream *substream)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
 	struct sof_intel_hda_stream *hda_stream;
 	const struct sof_intel_dsp_desc *chip;
 	struct snd_sof_dev *sdev;
@@ -145,12 +145,12 @@ static struct hdac_ext_stream *hda_assign_hext_stream(struct snd_sof_dev *sdev,
 						      struct snd_soc_dai *cpu_dai,
 						      struct snd_pcm_substream *substream)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
 	struct snd_soc_dai *dai;
 	struct hdac_ext_stream *hext_stream;
 
 	/* only allocate a stream_tag for the first DAI in the dailink */
-	dai = asoc_rtd_to_cpu(rtd, 0);
+	dai = snd_soc_rtd_to_cpu(rtd, 0);
 	if (dai == cpu_dai)
 		hext_stream = hda_link_stream_assign(sof_to_bus(sdev), substream);
 	else
@@ -168,11 +168,11 @@ static void hda_release_hext_stream(struct snd_sof_dev *sdev, struct snd_soc_dai
 				    struct snd_pcm_substream *substream)
 {
 	struct hdac_ext_stream *hext_stream = hda_get_hext_stream(sdev, cpu_dai, substream);
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
 	struct snd_soc_dai *dai;
 
 	/* only release a stream_tag for the first DAI in the dailink */
-	dai = asoc_rtd_to_cpu(rtd, 0);
+	dai = snd_soc_rtd_to_cpu(rtd, 0);
 	if (dai == cpu_dai)
 		snd_hdac_ext_stream_release(hext_stream, HDAC_EXT_STREAM_TYPE_LINK);
 	snd_soc_dai_set_dma_data(cpu_dai, substream, NULL);
@@ -193,8 +193,8 @@ static void hda_codec_dai_set_stream(struct snd_sof_dev *sdev,
 				     struct snd_pcm_substream *substream,
 				     struct hdac_stream *hstream)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
-	struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
+	struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
 
 	/* set the hdac_stream in the codec dai */
 	snd_soc_dai_set_stream(codec_dai, hstream, substream->stream);
@@ -204,8 +204,8 @@ static unsigned int hda_calc_stream_format(struct snd_sof_dev *sdev,
 					   struct snd_pcm_substream *substream,
 					   struct snd_pcm_hw_params *params)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
-	struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
+	struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
 	unsigned int link_bps;
 	unsigned int format_val;
 
@@ -226,8 +226,8 @@ static unsigned int hda_calc_stream_format(struct snd_sof_dev *sdev,
 static struct hdac_ext_link *hda_get_hlink(struct snd_sof_dev *sdev,
 					   struct snd_pcm_substream *substream)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
-	struct snd_soc_dai *codec_dai = asoc_rtd_to_codec(rtd, 0);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
+	struct snd_soc_dai *codec_dai = snd_soc_rtd_to_codec(rtd, 0);
 	struct hdac_bus *bus = sof_to_bus(sdev);
 
 	return snd_hdac_ext_bus_get_hlink_by_name(bus, codec_dai->component->name);
diff --git a/sound/soc/sof/intel/hda-dai.c b/sound/soc/sof/intel/hda-dai.c
index 318a21c12cd0..a20deaf3b428 100644
--- a/sound/soc/sof/intel/hda-dai.c
+++ b/sound/soc/sof/intel/hda-dai.c
@@ -316,7 +316,7 @@ static int __maybe_unused hda_dai_trigger(struct snd_pcm_substream *substream, i
 
 static int hda_dai_prepare(struct snd_pcm_substream *substream, struct snd_soc_dai *dai)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
 	int stream = substream->stream;
 
 	return hda_dai_hw_params(substream, &rtd->dpcm[stream].hw_params, dai);
@@ -408,7 +408,7 @@ static int non_hda_dai_hw_params(struct snd_pcm_substream *substream,
 static int non_hda_dai_prepare(struct snd_pcm_substream *substream,
 			       struct snd_soc_dai *cpu_dai)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
 	int stream = substream->stream;
 
 	return non_hda_dai_hw_params(substream, &rtd->dpcm[stream].hw_params, cpu_dai);
@@ -526,8 +526,8 @@ static int hda_dai_suspend(struct hdac_bus *bus)
 			struct snd_sof_dev *sdev;
 			struct snd_sof_dai *sdai;
 
-			rtd = asoc_substream_to_rtd(hext_stream->link_substream);
-			cpu_dai = asoc_rtd_to_cpu(rtd, 0);
+			rtd = snd_soc_substream_to_rtd(hext_stream->link_substream);
+			cpu_dai = snd_soc_rtd_to_cpu(rtd, 0);
 			w = snd_soc_dai_get_widget(cpu_dai, hdac_stream(hext_stream)->direction);
 			swidget = w->dobj.private;
 			sdev = widget_to_sdev(w);
diff --git a/sound/soc/sof/intel/hda-pcm.c b/sound/soc/sof/intel/hda-pcm.c
index f23c72cdff48..18f07364d219 100644
--- a/sound/soc/sof/intel/hda-pcm.c
+++ b/sound/soc/sof/intel/hda-pcm.c
@@ -177,7 +177,7 @@ int hda_dsp_pcm_trigger(struct snd_sof_dev *sdev,
 snd_pcm_uframes_t hda_dsp_pcm_pointer(struct snd_sof_dev *sdev,
 				      struct snd_pcm_substream *substream)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
 	struct snd_soc_component *scomp = sdev->component;
 	struct hdac_stream *hstream = substream->runtime->private_data;
 	struct sof_intel_hda_dev *hda = sdev->pdata->hw_pdata;
@@ -208,7 +208,7 @@ snd_pcm_uframes_t hda_dsp_pcm_pointer(struct snd_sof_dev *sdev,
 int hda_dsp_pcm_open(struct snd_sof_dev *sdev,
 		     struct snd_pcm_substream *substream)
 {
-	struct snd_soc_pcm_runtime *rtd = asoc_substream_to_rtd(substream);
+	struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
 	struct snd_pcm_runtime *runtime = substream->runtime;
 	struct snd_soc_component *scomp = sdev->component;
 	struct hdac_ext_stream *dsp_stream;
diff --git a/sound/soc/sof/intel/hda-stream.c b/sound/soc/sof/intel/hda-stream.c
index 65e9242365be..f2ebadbbcc10 100644
--- a/sound/soc/sof/intel/hda-stream.c
+++ b/sound/soc/sof/intel/hda-stream.c
@@ -38,7 +38,7 @@ static char *hda_hstream_dbg_get_stream_info_str(struct hdac_stream *hstream)
 	struct snd_soc_pcm_runtime *rtd;
 
 	if (hstream->substream)
-		rtd = asoc_substream_to_rtd(hstream->substream);
+		rtd = snd_soc_substream_to_rtd(hstream->substream);
 	else if (hstream->cstream)
 		rtd = hstream->cstream->private_data;
 	else
-- 
2.25.1


  parent reply	other threads:[~2023-09-26 15:14 UTC|newest]

Thread overview: 57+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-26  6:19 [PATCH v2 00/54] ASoC: convert asoc_xxx() to snd_soc_xxx() Kuninori Morimoto
2023-09-26  6:20 ` [PATCH v2 01/54] ASoC: soc.h: " Kuninori Morimoto
2023-09-26  6:20 ` [PATCH v2 02/54] ASoC: simple_card_utils.h: convert not to use asoc_xxx() Kuninori Morimoto
2023-09-26  6:20 ` [PATCH v2 03/54] ASoC: sh: " Kuninori Morimoto
2023-09-26  6:20 ` [PATCH v2 04/54] ASoC: ti: " Kuninori Morimoto
2023-09-26  6:20 ` [PATCH v2 05/54] ASoC: arm: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 06/54] ASoC: amd: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 07/54] ASoC: bcm: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 08/54] ASoC: dwc: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 09/54] ASoC: fsl: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 10/54] ASoC: img: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 11/54] ASoC: mxs: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 12/54] ASoC: pxa: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 13/54] ASoC: stm: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 14/54] ASoC: au1x: " Kuninori Morimoto
2023-09-26  6:21 ` [PATCH v2 15/54] ASoC: qcom: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 16/54] ASoC: sprd: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 17/54] ASoC: apple: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 18/54] ASoC: atmel: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 19/54] ASoC: meson: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 20/54] ASoC: sunxi: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 21/54] ASoC: tegra: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 22/54] ASoC: ux500: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 23/54] ASoC: google: " Kuninori Morimoto
2023-09-26  6:22 ` [PATCH v2 24/54] ASoC: cirrus: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 25/54] ASoC: generic: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 26/54] ASoC: samsung: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 27/54] ASoC: extensa: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 28/54] ASoC: kirkwood: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 29/54] ASoC: loongson: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 30/54] ASoC: mediatek: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 31/54] ASoC: rockchip: " Kuninori Morimoto
2023-09-26  6:23 ` [PATCH v2 32/54] ASoC: starfive: " Kuninori Morimoto
2023-09-26  6:24 ` [PATCH v2 33/54] ASoC: uniphier: " Kuninori Morimoto
2023-09-26  6:24 ` [PATCH v2 34/54] ASoC: soundwire: " Kuninori Morimoto
2023-09-26  6:24 ` [PATCH v2 35/54] ASoC: intel: " Kuninori Morimoto
2023-09-26  6:24 ` [PATCH v2 36/54] ASoC: intel: avs: " Kuninori Morimoto
2023-09-26  6:24 ` [PATCH v2 37/54] ASoC: codec: wm: " Kuninori Morimoto
2023-09-26  6:24 ` [PATCH v2 38/54] ASoC: codec: rt5677: " Kuninori Morimoto
2023-09-26  6:25 ` [PATCH v2 39/54] ASoC: codec: cs47lxx: " Kuninori Morimoto
2023-09-26  8:33   ` Charles Keepax
2023-09-26  6:25 ` [PATCH v2 40/54] ASoC: sof: " Kuninori Morimoto
2023-09-26  6:25 ` [PATCH v2 41/54] ASoC: sof: amd: " Kuninori Morimoto
2023-09-26  6:25 ` Kuninori Morimoto [this message]
2023-09-26  6:25 ` [PATCH v2 43/54] ASoC: sof: mediatek: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 44/54] ASoC: soc-dai: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 45/54] ASoC: soc-pcm: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 46/54] ASoC: soc-core: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 47/54] ASoC: soc-dapm: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 48/54] ASoC: soc-link: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 49/54] ASoC: soc-utils: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 50/54] ASoC: soc-topology: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 51/54] ASoC: soc-compress: " Kuninori Morimoto
2023-09-26  6:26 ` [PATCH v2 52/54] ASoC: soc-component: " Kuninori Morimoto
2023-09-26  6:27 ` [PATCH v2 53/54] ASoC: soc-generic-dmaengine-pcm: " Kuninori Morimoto
2023-09-26  6:27 ` [PATCH v2 54/54] ASoC: remove asoc_xxx() compatible macro Kuninori Morimoto
2023-09-27  8:50 ` [PATCH v2 00/54] ASoC: convert asoc_xxx() to snd_soc_xxx() 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=87pm25fo2h.wl-kuninori.morimoto.gx@renesas.com \
    --to=kuninori.morimoto.gx@renesas.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=daniel.baluta@nxp.com \
    --cc=kai.vehmanen@linux.intel.com \
    --cc=lgirdwood@gmail.com \
    --cc=perex@perex.cz \
    --cc=peter.ujfalusi@linux.intel.com \
    --cc=pierre-louis.bossart@linux.intel.com \
    --cc=ranjani.sridharan@linux.intel.com \
    --cc=tiwai@suse.com \
    --cc=yung-chuan.liao@linux.intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.