mirror of https://github.com/ARMmbed/mbed-os.git
Formatting tidy up.
parent
65ab95572c
commit
ed51bcb1d0
|
|
@ -116,7 +116,8 @@ int32_t flash_program_page(flash_t *obj, uint32_t address,
|
|||
return 0;
|
||||
}
|
||||
|
||||
uint32_t flash_get_sector_size(const flash_t *obj, uint32_t address) {
|
||||
uint32_t flash_get_sector_size(const flash_t *obj, uint32_t address)
|
||||
{
|
||||
/* considering 1 sector = 1 page */
|
||||
if ((address >= (FLASH_BASE + FLASH_SIZE)) || (address < FLASH_BASE)) {
|
||||
return MBED_FLASH_INVALID_SIZE;
|
||||
|
|
@ -125,16 +126,19 @@ uint32_t flash_get_sector_size(const flash_t *obj, uint32_t address) {
|
|||
}
|
||||
}
|
||||
|
||||
uint32_t flash_get_page_size(const flash_t *obj) {
|
||||
uint32_t flash_get_page_size(const flash_t *obj)
|
||||
{
|
||||
/* considering 1 sector = 1 page */
|
||||
return FLASH_PAGE_SIZE;
|
||||
}
|
||||
|
||||
uint32_t flash_get_start_address(const flash_t *obj) {
|
||||
uint32_t flash_get_start_address(const flash_t *obj)
|
||||
{
|
||||
return FLASH_BASE;
|
||||
}
|
||||
|
||||
uint32_t flash_get_size(const flash_t *obj) {
|
||||
uint32_t flash_get_size(const flash_t *obj)
|
||||
{
|
||||
return FLASH_SIZE;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue