From 04cbfa485be5f26777e9c2e381b474c5ff361018 Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Sun, 12 May 2019 15:16:55 +0000 Subject: [PATCH] Fixed bug #1029. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@12789 27425a3e-05d8-49a3-a47f-9c15f0e5edd8 --- os/hal/ports/STM32/STM32F4xx/stm32_rcc.h | 8 ++++++++ readme.txt | 2 ++ 2 files changed, 10 insertions(+) diff --git a/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h b/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h index e4eb67a2a..cc401ce05 100644 --- a/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h +++ b/os/hal/ports/STM32/STM32F4xx/stm32_rcc.h @@ -429,14 +429,22 @@ * * @api */ +#ifdef RCC_AHB1ENR_BKPSRAMEN #define rccEnableBKPSRAM(lp) rccEnableAHB1(RCC_AHB1ENR_BKPSRAMEN, lp) +#else +#define rccEnableBKPSRAM(lp) +#endif /** * @brief Disables the BKPSRAM peripheral clock. * * @api */ +#ifdef RCC_AHB1ENR_BKPSRAMEN #define rccDisableBKPSRAM() rccDisableAHB1(RCC_AHB1ENR_BKPSRAMEN) +#else +#define rccDisableBKPSRAM() +#endif /** @} */ /** diff --git a/readme.txt b/readme.txt index 9ad6c14ca..e2aa4744b 100644 --- a/readme.txt +++ b/readme.txt @@ -94,6 +94,8 @@ - HAL: Added a new interface for range-finder devices (used by EX). - HAL: Added mcuconf.h updater tool for STM32F407 (backported to 19.1.1). - NIL: Integrated NIL 4.0. +- FIX: Fixed RCC_AHB1ENR_BKPSRAMEN not present in all STMF4xx devices + (bug #1029)(backported to 19.1.3)(backported to 18.2.3). - FIX: Fixed MPU fix #1027 broke stack checking on Cortex-M devices without MPU (bug #1028)(backported to 19.1.3)(backported to 18.2.3). - FIX: Fixed MPU setup missing on thread start (bug #1027)