diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-09-11 10:27:40 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-09-11 10:27:40 -0600 |
commit | ff8a0746c9cfb9ade638a4e707c206b2f6be8e35 (patch) | |
tree | 771215d237256adeb9939af7eec32754ccf50126 /nuttx | |
parent | f218d0b4371e79ccb2fb4247420b8e3f0812ff43 (diff) | |
download | px4-nuttx-ff8a0746c9cfb9ade638a4e707c206b2f6be8e35.tar.gz px4-nuttx-ff8a0746c9cfb9ade638a4e707c206b2f6be8e35.tar.bz2 px4-nuttx-ff8a0746c9cfb9ade638a4e707c206b2f6be8e35.zip |
Fix for UART7 and UART8 on STM32 clock enable from Aton
Diffstat (limited to 'nuttx')
-rw-r--r-- | nuttx/arch/arm/src/stm32/chip/stm32f20xxx_rcc.h | 4 | ||||
-rw-r--r-- | nuttx/arch/arm/src/stm32/stm32_serial.c | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/nuttx/arch/arm/src/stm32/chip/stm32f20xxx_rcc.h b/nuttx/arch/arm/src/stm32/chip/stm32f20xxx_rcc.h index 837094d01..6dbb7f1d7 100644 --- a/nuttx/arch/arm/src/stm32/chip/stm32f20xxx_rcc.h +++ b/nuttx/arch/arm/src/stm32/chip/stm32f20xxx_rcc.h @@ -1,7 +1,7 @@ /**************************************************************************************************** * arch/arm/src/stm32/chip/stm32f20xxx_rcc.h * - * Copyright (C) 2012 Gregory Nutt. All rights reserved. + * Copyright (C) 2012, 2014 Gregory Nutt. All rights reserved. * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without @@ -357,6 +357,8 @@ #define RCC_APB1ENR_CAN2EN (1 << 26) /* Bit 26: CAN 2 clock enable */ #define RCC_APB1ENR_PWREN (1 << 28) /* Bit 28: Power interface clock enable */ #define RCC_APB1ENR_DACEN (1 << 29) /* Bit 29: DAC interface clock enable */ +#define RCC_APB1ENR_UART7EN (1 << 30) /* Bit 30: UART7 clock enable */ +#define RCC_APB1ENR_UART8EN (1 << 31) /* Bit 31: UART8 clock enable */ /* APB2 Peripheral Clock enable register */ diff --git a/nuttx/arch/arm/src/stm32/stm32_serial.c b/nuttx/arch/arm/src/stm32/stm32_serial.c index 42973bce1..de499ab08 100644 --- a/nuttx/arch/arm/src/stm32/stm32_serial.c +++ b/nuttx/arch/arm/src/stm32/stm32_serial.c @@ -1,7 +1,7 @@ /**************************************************************************** * arch/arm/src/stm32/stm32_serial.c * - * Copyright (C) 2009-2013 Gregory Nutt. All rights reserved. + * Copyright (C) 2009-2014 Gregory Nutt. All rights reserved. * Author: Gregory Nutt <gnutt@nuttx.org> * * Redistribution and use in source and binary forms, with or without @@ -1375,13 +1375,13 @@ static void up_set_apb_clock(struct uart_dev_s *dev, bool on) #endif #ifdef CONFIG_STM32_UART7 case STM32_UART7_BASE: - rcc_en = RCC_APB1ENR_USART5EN; + rcc_en = RCC_APB1ENR_UART7EN; regaddr = STM32_RCC_APB1ENR; break; #endif #ifdef CONFIG_STM32_UART8 case STM32_UART8_BASE: - rcc_en = RCC_APB1ENR_USART5EN; + rcc_en = RCC_APB1ENR_UART8EN; regaddr = STM32_RCC_APB1ENR; break; #endif |