Pad binary file to total flash size
Signed-off-by: Tim Crawford <tcrawford@system76.com>
This commit is contained in:
committed by
Jeremy Soller
parent
64e5b8308d
commit
0d83819a21
@ -33,7 +33,7 @@ sim: $(BUILD)/ec.rom
|
||||
$(BUILD)/ec.rom: $(BUILD)/ec.ihx
|
||||
@echo " OBJCOPY $(subst $(obj)/,,$@)"
|
||||
mkdir -p $(@D)
|
||||
objcopy -I ihex -O binary --gap-fill=0xFF $< $@
|
||||
objcopy -I ihex -O binary --gap-fill=0xFF --pad-to=$(CONFIG_EC_FLASH_SIZE) $< $@
|
||||
|
||||
# Link object files into Intel Hex file
|
||||
$(BUILD)/ec.ihx: $(OBJ)
|
||||
|
@ -27,3 +27,6 @@ ARCH=8051
|
||||
|
||||
# 64 KB is the max without banking
|
||||
CODE_SIZE=65536
|
||||
|
||||
# Total flash size: 128 KiB
|
||||
CONFIG_EC_FLASH_SIZE = 131072
|
||||
|
Reference in New Issue
Block a user