summaryrefslogtreecommitdiffstats
path: root/sound/soc/amd/raven
diff options
context:
space:
mode:
authorRavulapati Vishnu vardhan rao <Vishnuvardhanrao.Ravulapati@amd.com>2019-12-28 19:10:58 +0530
committerMark Brown <broonie@kernel.org>2019-12-31 00:22:59 +0000
commitcea5f40d4e7ae711622ba7ee3caa60c315f101c0 (patch)
treec537fa5cb58dea3285074d4f5b00cf671ecefd47 /sound/soc/amd/raven
parenta43ea44ddda94bc6c4dbe257fcbdeecde8cb06f1 (diff)
downloadlinux-cea5f40d4e7ae711622ba7ee3caa60c315f101c0.tar.bz2
ASoC: amd: Handle ACP3x I2S-SP Interrupts.
Enabled support for I2S-SP interrupt handling. Previous to this implementation, driver supports only interrupts on BT instance. Signed-off-by: Ravulapati Vishnu vardhan rao <Vishnuvardhanrao.Ravulapati@amd.com> Link: https://lore.kernel.org/r/1577540460-21438-5-git-send-email-Vishnuvardhanrao.Ravulapati@amd.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/amd/raven')
-rw-r--r--sound/soc/amd/raven/acp3x-pcm-dma.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/sound/soc/amd/raven/acp3x-pcm-dma.c b/sound/soc/amd/raven/acp3x-pcm-dma.c
index 040a8be593f0..c5d7f3558867 100644
--- a/sound/soc/amd/raven/acp3x-pcm-dma.c
+++ b/sound/soc/amd/raven/acp3x-pcm-dma.c
@@ -176,6 +176,13 @@ static irqreturn_t i2s_irq_handler(int irq, void *dev_id)
snd_pcm_period_elapsed(rv_i2s_data->play_stream);
play_flag = 1;
}
+ if ((val & BIT(I2S_TX_THRESHOLD)) &&
+ rv_i2s_data->i2ssp_play_stream) {
+ rv_writel(BIT(I2S_TX_THRESHOLD),
+ rv_i2s_data->acp3x_base + mmACP_EXTERNAL_INTR_STAT);
+ snd_pcm_period_elapsed(rv_i2s_data->i2ssp_play_stream);
+ play_flag = 1;
+ }
if ((val & BIT(BT_RX_THRESHOLD)) && rv_i2s_data->capture_stream) {
rv_writel(BIT(BT_RX_THRESHOLD), rv_i2s_data->acp3x_base +
@@ -183,6 +190,13 @@ static irqreturn_t i2s_irq_handler(int irq, void *dev_id)
snd_pcm_period_elapsed(rv_i2s_data->capture_stream);
cap_flag = 1;
}
+ if ((val & BIT(I2S_RX_THRESHOLD)) &&
+ rv_i2s_data->i2ssp_capture_stream) {
+ rv_writel(BIT(I2S_RX_THRESHOLD),
+ rv_i2s_data->acp3x_base + mmACP_EXTERNAL_INTR_STAT);
+ snd_pcm_period_elapsed(rv_i2s_data->i2ssp_capture_stream);
+ cap_flag = 1;
+ }
if (play_flag | cap_flag)
return IRQ_HANDLED;