stm32: flash_unlock_option_bytes is common code.

The keys differ between some familes, but the documentation and
implementation are standard.
This commit is contained in:
Karl Palsson
2018-07-22 21:31:00 +00:00
parent c5a3350a7d
commit 850931dbcd
13 changed files with 18 additions and 68 deletions

View File

@@ -92,16 +92,6 @@ void flash_clear_status_flags(void)
flash_clear_eop_flag();
}
/** @brief Unlock the Option Byte Access
* This enables write access to the option bytes. It is locked by default on
* reset.
*/
void flash_unlock_option_bytes(void)
{
FLASH_OPTKEYR = FLASH_OPTKEYR_KEY1;
FLASH_OPTKEYR = FLASH_OPTKEYR_KEY2;
}
/** @brief Lock the Option Byte Access
* This disables write access to the option bytes. It is locked by default on
* reset.