1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-14 03:50:02 +03:00

Fixed start / end addresses for custom defaults.

This commit is contained in:
mikeller 2019-09-01 13:35:10 +12:00
parent e38d460acf
commit 3128328224
3 changed files with 9 additions and 12 deletions

View file

@ -34,13 +34,6 @@ SECTIONS
. = ALIGN(4);
} >FLASH AT >AXIM_FLASH
/* Storage for the address for the configuration section so we can grab it out of the hex file */
.custom_defaults :
{
. = ALIGN(4);
*(.custom_defaults_address)
} >FLASH1 AT >AXIM_FLASH1
/* The program code and other data goes into FLASH */
.text :
{
@ -103,7 +96,9 @@ SECTIONS
.custom_defaults :
{
. = ALIGN(4);
KEEP (*(.custom_defaults_address))
KEEP (*(.custom_defaults_start_address))
. = ALIGN(4);
KEEP (*(.custom_defaults_end_address))
. = ALIGN(4);
__custom_defaults_internal_start = .;
*(.custom_defaults);

View file

@ -120,7 +120,9 @@ SECTIONS
.custom_defaults :
{
. = ALIGN(4);
KEEP (*(.custom_defaults_address))
KEEP (*(.custom_defaults_start_address))
. = ALIGN(4);
KEEP (*(.custom_defaults_end_address))
. = ALIGN(4);
__custom_defaults_internal_start = .;
*(.custom_defaults);

View file

@ -228,8 +228,8 @@ static char cliBufferTemp[CLI_IN_BUFFER_SIZE];
#endif
#if defined(USE_CUSTOM_DEFAULTS_ADDRESS)
static char __attribute__ ((section(".custom_defaults_address"))) *customDefaultsStart = CUSTOM_DEFAULTS_START;
static char __attribute__ ((section(".custom_defaults_address"))) *customDefaultsEnd = CUSTOM_DEFAULTS_END;
static char __attribute__ ((section(".custom_defaults_start_address"))) *customDefaultsStart = CUSTOM_DEFAULTS_START;
static char __attribute__ ((section(".custom_defaults_end_address"))) *customDefaultsEnd = CUSTOM_DEFAULTS_END;
#endif
#ifndef USE_QUAD_MIXER_ONLY