stm32: flash: move wait_for_last to f2/f4 explicitly.

We're preparing to use all the common code for f2, f4, f7 and large
chunks of l4.  Extract things that we know need to be done differently
there.
This commit is contained in:
Karl Palsson 2018-07-24 22:04:58 +00:00
parent 76d392ee47
commit 46d4103c1d
3 changed files with 10 additions and 5 deletions

View File

@ -26,11 +26,6 @@
#include <libopencm3/stm32/flash.h>
void flash_wait_for_last_operation(void)
{
while ((FLASH_SR & FLASH_SR_BSY) == FLASH_SR_BSY);
}
/*---------------------------------------------------------------------------*/
/** @brief Set the Program Parallelism Size

View File

@ -49,5 +49,10 @@
#include <libopencm3/stm32/flash.h>
void flash_wait_for_last_operation(void)
{
while ((FLASH_SR & FLASH_SR_BSY) == FLASH_SR_BSY);
}
/**@}*/

View File

@ -49,5 +49,10 @@
#include <libopencm3/stm32/flash.h>
void flash_wait_for_last_operation(void)
{
while ((FLASH_SR & FLASH_SR_BSY) == FLASH_SR_BSY);
}
/**@}*/