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: tiwai@suse.de, patches.audio@intel.com,
	liam.r.girdwood@linux.intel.com,
	Vinod Koul <vinod.koul@intel.com>,
	broonie@kernel.org,
	"Subhransu S. Prusty" <subhransu.s.prusty@intel.com>
Subject: [PATCH v2 2/8] ASoC: Intel: Move the busy check to ops for Baytrail
Date: Tue, 19 May 2015 15:00:34 +0530	[thread overview]
Message-ID: <1432027840-18711-3-git-send-email-vinod.koul@intel.com> (raw)
In-Reply-To: <1432027840-18711-1-git-send-email-vinod.koul@intel.com>

From: "Subhransu S. Prusty" <subhransu.s.prusty@intel.com>

Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
---
 sound/soc/intel/baytrail/sst-baytrail-ipc.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/sound/soc/intel/baytrail/sst-baytrail-ipc.c b/sound/soc/intel/baytrail/sst-baytrail-ipc.c
index 1efb33b36303..799b804f3e34 100644
--- a/sound/soc/intel/baytrail/sst-baytrail-ipc.c
+++ b/sound/soc/intel/baytrail/sst-baytrail-ipc.c
@@ -679,6 +679,14 @@ static u64 byt_reply_msg_match(u64 header, u64 *mask)
 	return header;
 }
 
+static bool byt_is_dsp_busy(struct sst_dsp *dsp)
+{
+	u64 ipcx;
+
+	ipcx = sst_dsp_shim_read_unlocked(dsp, SST_IPCX);
+	return (ipcx & (SST_IPCX_BUSY | SST_IPCX_DONE));
+}
+
 int sst_byt_dsp_init(struct device *dev, struct sst_pdata *pdata)
 {
 	struct sst_byt *byt;
@@ -699,6 +707,7 @@ int sst_byt_dsp_init(struct device *dev, struct sst_pdata *pdata)
 	ipc->ops.shim_dbg = byt_shim_dbg;
 	ipc->ops.tx_data_copy = byt_tx_data_copy;
 	ipc->ops.reply_msg_match = byt_reply_msg_match;
+	ipc->ops.is_dsp_busy = byt_is_dsp_busy;
 
 	err = sst_ipc_init(ipc);
 	if (err != 0)
-- 
1.9.1

  parent reply	other threads:[~2015-05-19  9:29 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-19  9:30 [PATCH v2 0/8] ASoC: Intel: refactor common SST IPC handling Vinod Koul
2015-05-19  9:30 ` [PATCH v2 1/8] ASoC: Intel: Create an ops to check for DSP busy Vinod Koul
2015-05-19  9:30 ` Vinod Koul [this message]
2015-05-19  9:30 ` [PATCH v2 3/8] ASoC: Intel: Move the busy check to ops for HSW Vinod Koul
2015-05-19  9:30 ` [PATCH v2 4/8] ASoC: Intel: Remove the direct register reference from common ipc Vinod Koul
2015-05-19  9:30 ` [PATCH v2 5/8] ASoC: Intel: Allow to configure max size for mailbox data Vinod Koul
2015-05-19  9:30 ` [PATCH v2 6/8] ASoC: Intel: Initialize max mailbox size for baytrail Vinod Koul
2015-05-19  9:30 ` [PATCH v2 7/8] ASoC: Intel: Initialize max mailbox size for haswell Vinod Koul
2015-05-22 18:23   ` Mark Brown
2015-05-19  9:30 ` [PATCH v2 8/8] ASoC: Intel: Allocate for the mailbox with max size Vinod Koul
2015-05-19 10:42   ` Takashi Iwai
2015-05-19 11:07     ` Vinod Koul
2015-05-21 21:14 ` [PATCH v2 0/8] ASoC: Intel: refactor common SST IPC handling Liam Girdwood

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=1432027840-18711-3-git-send-email-vinod.koul@intel.com \
    --to=vinod.koul@intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=liam.r.girdwood@linux.intel.com \
    --cc=patches.audio@intel.com \
    --cc=subhransu.s.prusty@intel.com \
    --cc=tiwai@suse.de \
    /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).