mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Syed Saba Kareem <Syed.SabaKareem@amd.com>
To: <broonie@kernel.org>, <alsa-devel@alsa-project.org>
Cc: <Vijendar.Mukunda@amd.com>, <Basavaraj.Hiregoudar@amd.com>,
	<Sunil-kumar.Dommati@amd.com>,
	Syed Saba Kareem <Syed.SabaKareem@amd.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
	Venkata Prasad Potturu <venkataprasad.potturu@amd.com>,
	V sujith kumar Reddy <Vsujithkumar.Reddy@amd.com>,
	Ajit Kumar Pandey <AjitKumar.Pandey@amd.com>,
	open list <linux-kernel@vger.kernel.org>
Subject: [PATCH 08/12] ASoC: amd: acp: store xfer_resolution of the stream
Date: Thu, 22 Jun 2023 20:53:53 +0530	[thread overview]
Message-ID: <20230622152406.3709231-16-Syed.SabaKareem@amd.com> (raw)
In-Reply-To: <20230622152406.3709231-1-Syed.SabaKareem@amd.com>

Store the 'xfer_resolution' of the stream in private data structure,
it will be used to reprogram the xfer_resolution for the active stream
during system level resume.

Signed-off-by: Syed Saba Kareem <Syed.SabaKareem@amd.com>
---
 sound/soc/amd/acp/acp-i2s.c | 2 ++
 sound/soc/amd/acp/amd.h     | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/sound/soc/amd/acp/acp-i2s.c b/sound/soc/amd/acp/acp-i2s.c
index 09b6511c0a26..09dc5f2c0bfc 100644
--- a/sound/soc/amd/acp/acp-i2s.c
+++ b/sound/soc/amd/acp/acp-i2s.c
@@ -149,6 +149,7 @@ static int acp_i2s_hwparams(struct snd_pcm_substream *substream, struct snd_pcm_
 			dev_err(dev, "Invalid dai id %x\n", dai->driver->id);
 			return -EINVAL;
 		}
+		adata->xfer_tx_resolution[dai->driver->id - 1] = xfer_resolution;
 	} else {
 		switch (dai->driver->id) {
 		case I2S_BT_INSTANCE:
@@ -167,6 +168,7 @@ static int acp_i2s_hwparams(struct snd_pcm_substream *substream, struct snd_pcm_
 			dev_err(dev, "Invalid dai id %x\n", dai->driver->id);
 			return -EINVAL;
 		}
+		adata->xfer_rx_resolution[dai->driver->id - 1] = xfer_resolution;
 	}
 
 	val = readl(adata->acp_base + reg_val);
diff --git a/sound/soc/amd/acp/amd.h b/sound/soc/amd/acp/amd.h
index f53613216397..38c152c6c8c6 100644
--- a/sound/soc/amd/acp/amd.h
+++ b/sound/soc/amd/acp/amd.h
@@ -166,6 +166,8 @@ struct acp_dev_data {
 	struct acp_resource *rsrc;
 	u32 tdm_tx_fmt[3];
 	u32 tdm_rx_fmt[3];
+	u32 xfer_tx_resolution[3];
+	u32 xfer_rx_resolution[3];
 };
 
 union acp_i2stdm_mstrclkgen {
-- 
2.25.1


  parent reply	other threads:[~2023-06-22 15:27 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-22 15:23 [PATCH 01/12] ASoC: amd: acp: clear pdm dma interrupt mask Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 01/11] ASoC: amd: acp: remove acp poweroff function Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 02/11] ASoC: amd: acp: refactor the acp init and de-init sequence Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 02/12] ASoC: amd: acp: remove acp poweroff function Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 03/11] ASoC: amd: acp: add acp i2s master clock generation for rembrandt platform Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 03/12] ASoC: amd: acp: refactor the acp init and de-init sequence Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 04/12] ASoC: amd: acp: add acp i2s master clock generation for rembrandt platform Syed Saba Kareem
2023-06-22 22:30   ` Mark Brown
2023-06-23 14:07     ` Saba Kareem, Syed
2023-06-22 22:30   ` kernel test robot
2023-06-22 15:23 ` [PATCH 04/11] ASoC: amd: acp: remove the redundant acp enable/disable interrupts functions Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 05/12] " Syed Saba Kareem
2023-06-23  4:13   ` kernel test robot
2023-06-22 15:23 ` [PATCH 05/11] ASoC: amd: acp: store platform device reference created in pci probe call Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 06/11] ASoC: amd: acp: add pm ops support for acp pci driver Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 06/12] ASoC: amd: acp: store platform device reference created in pci probe call Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 07/12] ASoC: amd: acp: add pm ops support for acp pci driver Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 07/11] ASoC: amd: acp: store xfer_resolution of the stream Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 08/11] ASoC: amd: acp: export config_acp_dma() and config_pte_for_stream() symbols Syed Saba Kareem
2023-06-22 15:23 ` Syed Saba Kareem [this message]
2023-06-22 15:23 ` [PATCH 09/12] " Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 09/11] ASoC: amd: acp: store the pdm stream channel mask Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 10/11] ASoC: amd: acp: move pdm macros to common header file Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 10/12] ASoC: amd: acp: store the pdm stream channel mask Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 11/11] ASoC: amd: acp: add pm ops support for rembrandt platform Syed Saba Kareem
2023-06-22 15:23 ` [PATCH 11/12] ASoC: amd: acp: move pdm macros to common header file Syed Saba Kareem
2023-06-22 15:24 ` [PATCH 12/12] ASoC: amd: acp: add pm ops support for rembrandt platform Syed Saba Kareem
2023-06-23  0:49 ` [PATCH 01/12] ASoC: amd: acp: clear pdm dma interrupt mask 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=20230622152406.3709231-16-Syed.SabaKareem@amd.com \
    --to=syed.sabakareem@amd.com \
    --cc=AjitKumar.Pandey@amd.com \
    --cc=Basavaraj.Hiregoudar@amd.com \
    --cc=Sunil-kumar.Dommati@amd.com \
    --cc=Vijendar.Mukunda@amd.com \
    --cc=Vsujithkumar.Reddy@amd.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.com \
    --cc=venkataprasad.potturu@amd.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

all inboxes | Powered by JetHome®