summaryrefslogtreecommitdiffstats
path: root/firmware/target/arm/as3525
diff options
context:
space:
mode:
authorMihail Zenkov <mihail.zenkov@gmail.com>2015-02-15 00:42:24 +0000
committerGerrit Rockbox <gerrit@rockbox.org>2015-04-09 19:26:05 +0200
commitf775870a5a373f8ff68d9b3a4150f18b369ac7a9 (patch)
tree4a3dcbc242b1faf25a3b5f1902aeb0b7fd9fe205 /firmware/target/arm/as3525
parent926829cba33671a37f1eceade54be410ac6927e3 (diff)
downloadrockbox-f775870a5a373f8ff68d9b3a4150f18b369ac7a9.tar.gz
rockbox-f775870a5a373f8ff68d9b3a4150f18b369ac7a9.tar.bz2
rockbox-f775870a5a373f8ff68d9b3a4150f18b369ac7a9.zip
AMS: Fix pop-clicks noise on play/stop.
This noise itroduced by starting/stopping I2SO MCLK. Enable MCLK permanently fix it. Change-Id: I6d9c51e5ea5bca13026833d2bfdda49d94c6b723
Diffstat (limited to 'firmware/target/arm/as3525')
-rw-r--r--firmware/target/arm/as3525/pcm-as3525.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/firmware/target/arm/as3525/pcm-as3525.c b/firmware/target/arm/as3525/pcm-as3525.c
index eb22fc2016..0f077b825b 100644
--- a/firmware/target/arm/as3525/pcm-as3525.c
+++ b/firmware/target/arm/as3525/pcm-as3525.c
@@ -132,8 +132,6 @@ void pcm_play_dma_start(const void *addr, size_t size)
/* force writeback */
commit_dcache_range(dma_start_addr, dma_start_size);
- bitset32(&CGU_AUDIO, (1<<11));
-
play_start_pcm();
}
@@ -151,11 +149,6 @@ void pcm_play_dma_stop(void)
dma_release();
-#ifdef HAVE_RECORDING
- if (!is_recording)
- bitclr32(&CGU_AUDIO, (1<<11));
-#endif
-
play_callback_pending = false;
}
@@ -221,10 +214,10 @@ void pcm_dma_apply_settings(void)
(0<<23) | /* I2SI_MCLK_EN = disabled */
(0<<14) | /* I2SI_MCLK_DIV_SEL = unused */
(0<<12) | /* I2SI_MCLK_SEL = clk_main */
- /* I2SO_MCLK_EN = unchanged */
+ (1<<11) | /* I2SO_MCLK_EN */
(mclk_divider() << 2) | /* I2SO_MCLK_DIV_SEL */
(AS3525_MCLK_SEL << 0), /* I2SO_MCLK_SEL */
- 0x01fff7ff);
+ 0x01ffffff);
}
size_t pcm_get_bytes_waiting(void)
@@ -386,9 +379,6 @@ void pcm_rec_dma_stop(void)
rec_dma_addr = NULL;
rec_dma_size = 0;
- if (!is_playing)
- bitclr32(&CGU_AUDIO, (1<<11));
-
bitclr32(&CGU_PERI, CGU_I2SIN_APB_CLOCK_ENABLE);
}
@@ -397,8 +387,6 @@ void pcm_rec_dma_start(void *addr, size_t size)
{
is_recording = true;
- bitset32(&CGU_AUDIO, (1<<11));
-
rec_dma_addr = addr;
rec_dma_size = size;