diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2011-01-06 10:33:57 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2011-01-06 10:33:57 +0000 |
commit | 7799821b6e4f7c499eac4abc5e50028716da21f1 (patch) | |
tree | 7d9c6b74620c121589407946fb1049d9de9634d4 /os/hal/platforms | |
parent | 6fdb361bf1f8fb772c94e3159d05154b18447908 (diff) | |
download | ChibiOS-7799821b6e4f7c499eac4abc5e50028716da21f1.tar.gz ChibiOS-7799821b6e4f7c499eac4abc5e50028716da21f1.tar.bz2 ChibiOS-7799821b6e4f7c499eac4abc5e50028716da21f1.zip |
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2594 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/platforms')
-rw-r--r-- | os/hal/platforms/STM32/hal_lld.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/os/hal/platforms/STM32/hal_lld.c b/os/hal/platforms/STM32/hal_lld.c index b83262722..df99c3b53 100644 --- a/os/hal/platforms/STM32/hal_lld.c +++ b/os/hal/platforms/STM32/hal_lld.c @@ -113,9 +113,15 @@ void stm32_clock_init(void) { #endif
/* Clock settings.*/
+#if STM32_HAS_USB
RCC->CFGR = STM32_MCO | STM32_USBPRE | STM32_PLLMUL | STM32_PLLXTPRE |
STM32_PLLSRC | STM32_ADCPRE | STM32_PPRE2 | STM32_PPRE1 |
STM32_HPRE;
+#else
+ RCC->CFGR = STM32_MCO | STM32_PLLMUL | STM32_PLLXTPRE |
+ STM32_PLLSRC | STM32_ADCPRE | STM32_PPRE2 | STM32_PPRE1 |
+ STM32_HPRE;
+#endif
/* Flash setup and final clock selection. */
FLASH->ACR = STM32_FLASHBITS; /* Flash wait states depending on clock. */
|