diff options
author | Subhransu S. Prusty <subhransu.s.prusty@intel.com> | 2015-05-19 12:30:34 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2015-05-22 21:24:20 +0300 |
commit | 2709bdbc4d7ffae3bcd3e24e214475fcc3d4f77e (patch) | |
tree | 8ee8067daa3538a4a9fe10a6d5f51017f000b91d /sound/soc/intel/baytrail/sst-baytrail-ipc.c | |
parent | 6022d330a59735adbdcb917d1428a306dbba577b (diff) | |
download | linux-2709bdbc4d7ffae3bcd3e24e214475fcc3d4f77e.tar.xz |
ASoC: Intel: Move the busy check to ops for Baytrail
Signed-off-by: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Acked-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/baytrail/sst-baytrail-ipc.c')
-rw-r--r-- | sound/soc/intel/baytrail/sst-baytrail-ipc.c | 9 |
1 files changed, 9 insertions, 0 deletions
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) |