mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-11-22 15:38:11 +00:00
trezorhal: update linker scripts
This commit is contained in:
parent
435e96e1b3
commit
a440f3d322
@ -405,7 +405,7 @@ $(BUILD)/$(TARGET).elf: $(OBJ)
|
||||
$(Q)$(SIZE) $@
|
||||
|
||||
$(BUILD)/$(TARGET).bin: $(BUILD)/$(TARGET).elf
|
||||
$(Q)$(OBJCOPY) -O binary -j .flash -j .data $^ $(BUILD)/$(TARGET).bin
|
||||
$(Q)$(OBJCOPY) -O binary -j .header -j .flash -j .data $^ $(BUILD)/$(TARGET).bin
|
||||
|
||||
$(BUILD)/%.o: %.S
|
||||
$(ECHO) "CC $<"
|
||||
|
@ -139,7 +139,7 @@ $(BUILD)/$(TARGET).elf: $(OBJ)
|
||||
$(Q)$(SIZE) $@
|
||||
|
||||
$(BUILD)/$(TARGET).bin: $(BUILD)/$(TARGET).elf
|
||||
$(Q)$(OBJCOPY) -O binary -j .flash -j .data $^ $(BUILD)/$(TARGET).bin
|
||||
$(Q)$(OBJCOPY) -O binary -j .header -j .flash -j .data $^ $(BUILD)/$(TARGET).bin
|
||||
|
||||
$(BUILD)/%.o: %.S
|
||||
$(ECHO) "CC $<"
|
||||
|
@ -25,11 +25,16 @@ ENTRY(Reset_Handler)
|
||||
/* define output sections */
|
||||
SECTIONS
|
||||
{
|
||||
/* Firmware Header */
|
||||
.header :
|
||||
{
|
||||
KEEP(*(.header))
|
||||
} > FLASH
|
||||
|
||||
/* The startup code goes first into FLASH */
|
||||
.flash :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
KEEP(*(.header)) /* Firmware Header */
|
||||
KEEP(*(.isr_vector)) /* Startup code */
|
||||
. = ALIGN(4);
|
||||
*(.text*) /* .text* sections (code) */
|
||||
@ -87,7 +92,7 @@ SECTIONS
|
||||
}
|
||||
|
||||
/* RAM extents for the garbage collector */
|
||||
_codelen = SIZEOF(.flash) + SIZEOF(.data) - 512;
|
||||
_codelen = SIZEOF(.flash) + SIZEOF(.data);
|
||||
_ram_start = ORIGIN(RAM);
|
||||
_ram_end = ORIGIN(RAM) + LENGTH(RAM);
|
||||
_heap_start = _ebss; /* heap starts just after statically allocated memory */
|
||||
|
@ -25,11 +25,16 @@ ENTRY(Reset_Handler)
|
||||
/* define output sections */
|
||||
SECTIONS
|
||||
{
|
||||
/* Firmware Header */
|
||||
.header :
|
||||
{
|
||||
KEEP(*(.header))
|
||||
} > FLASH
|
||||
|
||||
/* The startup code goes first into FLASH */
|
||||
.flash :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
KEEP(*(.header)) /* Firmware Header */
|
||||
KEEP(*(.isr_vector)) /* Startup code */
|
||||
. = ALIGN(4);
|
||||
*(.text*) /* .text* sections (code) */
|
||||
@ -87,7 +92,7 @@ SECTIONS
|
||||
}
|
||||
|
||||
/* RAM extents for the garbage collector */
|
||||
_codelen = SIZEOF(.flash) + SIZEOF(.data) - 512;
|
||||
_codelen = SIZEOF(.flash) + SIZEOF(.data);
|
||||
_ram_start = ORIGIN(RAM);
|
||||
_ram_end = ORIGIN(RAM) + LENGTH(RAM);
|
||||
_heap_start = _ebss; /* heap starts just after statically allocated memory */
|
||||
|
Loading…
Reference in New Issue
Block a user