summaryrefslogtreecommitdiff
path: root/chip/stm32/dma.c
diff options
context:
space:
mode:
authorDaisuke Nojiri <dnojiri@chromium.org>2016-04-20 14:49:56 -0700
committerchrome-bot <chrome-bot@chromium.org>2016-04-25 16:49:02 -0700
commit40c02e3ff2477df1aca7657a92905816e5a13d0c (patch)
tree57f05231828259506bf8bfdd2c494e533715e01f /chip/stm32/dma.c
parentcb0d8108e5a5b630ec05a8d21a824cb601246bf5 (diff)
downloadchrome-ec-40c02e3ff2477df1aca7657a92905816e5a13d0c.tar.gz
Bring up STM32L476G-Eval
This patch adds initial set of files to bring up STM32L476G-Eval board. BUG=none BRANCH=tot TEST=Tested console. make buildall && make tests Change-Id: I0c0f73f31e84099746fced4214c5ed7f45468cef Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/340100 Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'chip/stm32/dma.c')
-rw-r--r--chip/stm32/dma.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/chip/stm32/dma.c b/chip/stm32/dma.c
index d169cf7f45..3b45544190 100644
--- a/chip/stm32/dma.c
+++ b/chip/stm32/dma.c
@@ -230,7 +230,11 @@ void dma_test(enum dma_channel channel)
void dma_init(void)
{
+#ifdef CHIP_FAMILY_STM32L4
+ STM32_RCC_AHB1ENR |= STM32_RCC_AHB1ENR_DMA1EN;
+#else
STM32_RCC_AHBENR |= STM32_RCC_HB_DMA1;
+#endif
#ifdef CHIP_FAMILY_STM32F3
STM32_RCC_AHBENR |= STM32_RCC_HB_DMA2;
#endif