Revert "stm32 FLASH allow non blocking operation on constrained devices"
This reverts commit ad2ef95ddf
.
This commit is contained in:
parent
9fc283526a
commit
91d473b816
@ -2832,14 +2832,6 @@ config STM32_FLASH_PREFETCH
|
||||
on F1 parts). Some early revisions of F4 parts do not support FLASH pre-fetch
|
||||
properly and enabling this option may interfere with ADC accuracy.
|
||||
|
||||
config STM32_FLASH_NONBLOCKING
|
||||
bool "Remove Blocking operation in FLASH driver"
|
||||
default n
|
||||
---help---
|
||||
Enable this on single task platforms to conserve code space.
|
||||
It removes the sem_wait and post operations that are not
|
||||
needed in a single task environment.
|
||||
|
||||
config STM32_FLASH_WORKAROUND_DATA_CACHE_CORRUPTION_ON_RWW
|
||||
bool "Workaround for FLASH data cache corruption"
|
||||
default n
|
||||
|
@ -100,29 +100,23 @@
|
||||
* Private Data
|
||||
************************************************************************************/
|
||||
|
||||
#if !defined(CONFIG_STM32_FLASH_NONBLOCKING)
|
||||
static sem_t g_sem = SEM_INITIALIZER(1);
|
||||
#endif
|
||||
|
||||
/************************************************************************************
|
||||
* Private Functions
|
||||
************************************************************************************/
|
||||
|
||||
static inline void sem_lock(void)
|
||||
static void sem_lock(void)
|
||||
{
|
||||
#if !defined(CONFIG_STM32_FLASH_NONBLOCKING)
|
||||
while (sem_wait(&g_sem) < 0)
|
||||
{
|
||||
DEBUGASSERT(errno == EINTR);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline void sem_unlock(void)
|
||||
{
|
||||
#if !defined(CONFIG_STM32_FLASH_NONBLOCKING)
|
||||
sem_post(&g_sem);
|
||||
#endif
|
||||
}
|
||||
|
||||
#if !defined(CONFIG_STM32_STM32L15XX)
|
||||
|
Loading…
Reference in New Issue
Block a user