Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1233881 > unrolled thread
| Started by | "yitian" <yitian.bu@tangramtek.com> |
|---|---|
| First post | 2015-09-28 08:40 +0200 |
| Last post | 2015-09-28 11:00 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH 1/1] ASoC: dwc: fix dma stop transferring issue "yitian" <yitian.bu@tangramtek.com> - 2015-09-28 08:40 +0200
Re: [PATCH 1/1] ASoC: dwc: fix dma stop transferring issue kbuild test robot <lkp@intel.com> - 2015-09-28 11:00 +0200
| From | "yitian" <yitian.bu@tangramtek.com> |
|---|---|
| Date | 2015-09-28 08:40 +0200 |
| Subject | [PATCH 1/1] ASoC: dwc: fix dma stop transferring issue |
| Message-ID | <qdAgp-6c0-5@gated-at.bofh.it> |
Designware I2S uses tx empty and rx available signals as the DMA
handshaking signals. during music playing, if XRUN occurs,
i2s_stop() function will be executed and both tx and rx irq are
masked, when music contintes to be played, i2s_start() is executed
but both tx and rx irq are not unmasked which cause I2S stop
sending DMA handshaking signal to DMA controller, and it finally
cause music playing will be stopped once XRUN occurs for the first
time.
Signed-off-by: Yitian Bu <yitian.bu@tangramtek.com>
---
sound/soc/dwc/designware_i2s.c | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/sound/soc/dwc/designware_i2s.c b/sound/soc/dwc/designware_i2s.c
index a3e97b4..4d3e1d3 100644
--- a/sound/soc/dwc/designware_i2s.c
+++ b/sound/soc/dwc/designware_i2s.c
@@ -144,10 +144,19 @@ static void i2s_start(struct dw_i2s_dev *dev,
i2s_write_reg(dev->i2s_base, IER, 1);
- if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK)
+ if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) {
+ for (i = 0; i < 4; i++) {
+ irq = i2s_read_reg(dev->i2s_base, IMR(i));
+ i2s_write_reg(dev->i2s_base, IMR(i), irq & ~0x30);
+ }
i2s_write_reg(dev->i2s_base, ITER, 1);
- else
+ } else {
+ for (i = 0; i < 4; i++) {
+ irq = i2s_read_reg(dev->i2s_base, IMR(i));
+ i2s_write_reg(dev->i2s_base, IMR(i), irq & ~0x03);
+ }
i2s_write_reg(dev->i2s_base, IRER, 1);
+ }
i2s_write_reg(dev->i2s_base, CER, 1);
}
--
1.7.12.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | kbuild test robot <lkp@intel.com> |
|---|---|
| Date | 2015-09-28 11:00 +0200 |
| Message-ID | <qdCrU-Qy-11@gated-at.bofh.it> |
| In reply to | #1233881 |
[Multipart message — attachments visible in raw view] — view raw
Hi yitian,
[auto build test results on v4.3-rc3 -- if it's inappropriate base, please ignore]
config: i386-randconfig-r0-201539 (attached as .config)
reproduce:
git checkout 3488a5ee9b79e2ced9fa43b78c9c5d0aa7e052f9
# save the attached .config to linux build tree
make ARCH=i386
All error/warnings (new ones prefixed by >>):
sound/soc/dwc/designware_i2s.c: In function 'i2s_start':
>> sound/soc/dwc/designware_i2s.c:148:8: error: 'i' undeclared (first use in this function)
for (i = 0; i < 4; i++) {
^
sound/soc/dwc/designware_i2s.c:148:8: note: each undeclared identifier is reported only once for each function it appears in
>> sound/soc/dwc/designware_i2s.c:149:4: error: 'irq' undeclared (first use in this function)
irq = i2s_read_reg(dev->i2s_base, IMR(i));
^
vim +/i +148 sound/soc/dwc/designware_i2s.c
142 struct snd_pcm_substream *substream)
143 {
144
145 i2s_write_reg(dev->i2s_base, IER, 1);
146
147 if (substream->stream == SNDRV_PCM_STREAM_PLAYBACK) {
> 148 for (i = 0; i < 4; i++) {
> 149 irq = i2s_read_reg(dev->i2s_base, IMR(i));
150 i2s_write_reg(dev->i2s_base, IMR(i), irq & ~0x30);
151 }
152 i2s_write_reg(dev->i2s_base, ITER, 1);
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web