alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: Vinod Koul <vinod.koul@intel.com>
To: alsa-devel@alsa-project.org
Cc: liam.r.girdwood@linux.intel.com, patches.audio@intel.com,
	broonie@kernel.org, Vinod Koul <vinod.koul@intel.com>,
	Jeeja KP <jeeja.kp@intel.com>
Subject: [PATCH 1/3] ASoC: Intel: Skylake: correct direction in blob query
Date: Tue,  1 Mar 2016 07:59:10 +0530	[thread overview]
Message-ID: <1456799352-22653-2-git-send-email-vinod.koul@intel.com> (raw)
In-Reply-To: <1456799352-22653-1-git-send-email-vinod.koul@intel.com>

From: Jeeja KP <jeeja.kp@intel.com>

The blob query for BE skl_tplg_update_be_blob() was not using
right values for direction for blob query, so fix that.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
---
 sound/soc/intel/skylake/skl-topology.c | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff --git a/sound/soc/intel/skylake/skl-topology.c b/sound/soc/intel/skylake/skl-topology.c
index c95bbce8ad5d..af7722ab7207 100644
--- a/sound/soc/intel/skylake/skl-topology.c
+++ b/sound/soc/intel/skylake/skl-topology.c
@@ -273,10 +273,11 @@ static int skl_tplg_update_be_blob(struct snd_soc_dapm_widget *w,
 	if (m_cfg->formats_config.caps_size > 0)
 		return 0;
 
+	dev_dbg(ctx->dev, "Applying default cfg blob\n");
 	switch (m_cfg->dev_type) {
 	case SKL_DEVICE_DMIC:
 		link_type = NHLT_LINK_DMIC;
-		dir = 1;
+		dir = SNDRV_PCM_STREAM_CAPTURE;
 		s_freq = m_cfg->in_fmt[0].s_freq;
 		s_fmt = m_cfg->in_fmt[0].bit_depth;
 		ch = m_cfg->in_fmt[0].channels;
@@ -285,15 +286,15 @@ static int skl_tplg_update_be_blob(struct snd_soc_dapm_widget *w,
 	case SKL_DEVICE_I2S:
 		link_type = NHLT_LINK_SSP;
 		if (m_cfg->hw_conn_type == SKL_CONN_SOURCE) {
-			dir = 1;
-			s_freq = m_cfg->in_fmt[0].s_freq;
-			s_fmt = m_cfg->in_fmt[0].bit_depth;
-			ch = m_cfg->in_fmt[0].channels;
-		} else {
-			dir = 0;
+			dir = SNDRV_PCM_STREAM_PLAYBACK;
 			s_freq = m_cfg->out_fmt[0].s_freq;
 			s_fmt = m_cfg->out_fmt[0].bit_depth;
 			ch = m_cfg->out_fmt[0].channels;
+		} else {
+			dir = SNDRV_PCM_STREAM_CAPTURE;
+			s_freq = m_cfg->in_fmt[0].s_freq;
+			s_fmt = m_cfg->in_fmt[0].bit_depth;
+			ch = m_cfg->in_fmt[0].channels;
 		}
 		break;
 
-- 
1.9.1

  reply	other threads:[~2016-03-01  2:26 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-01  2:29 [PATCH 0/3] ASoC: Intel: Skylake: Update the IVI feedback path Vinod Koul
2016-03-01  2:29 ` Vinod Koul [this message]
2016-03-02  4:00   ` Applied "ASoC: Intel: Skylake: correct direction in blob query" to the asoc tree Mark Brown
2016-03-01  2:29 ` [PATCH 2/3] ASoC: Intel: Skylake: Add IVI feedback path in nau88125_ssm4567 machine Vinod Koul
2016-03-02  4:00   ` Applied "ASoC: Intel: Skylake: Add IVI feedback path in nau88125_ssm4567 machine" to the asoc tree Mark Brown
2016-03-01  2:29 ` [PATCH 3/3] ASoC: Intel: Skylake: remove IVI codec loop in skl_nau88l25_ssm4567 machine Vinod Koul
2016-03-02  4:00   ` Applied "ASoC: Intel: Skylake: remove IVI codec loop in skl_nau88l25_ssm4567 machine" to the asoc tree 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=1456799352-22653-2-git-send-email-vinod.koul@intel.com \
    --to=vinod.koul@intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=jeeja.kp@intel.com \
    --cc=liam.r.girdwood@linux.intel.com \
    --cc=patches.audio@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).