1
0

bootrom: follow SBI (a0=hartid, a1=dtb)

This commit is contained in:
Wesley W. Terpstra
2017-03-24 15:55:57 -07:00
parent 9a2f0d01a1
commit 34f8ce653a
7 changed files with 36 additions and 28 deletions

View File

@ -5,8 +5,11 @@ OBJCOPY=riscv64-unknown-elf-objcopy
all: $(bootrom_img)
%.img: %.elf
$(OBJCOPY) -O binary --change-addresses=-0x1000 --only-section .text $< $@
%.img: %.bin
dd if=$< of=$@ bs=128 count=1
%.bin: %.elf
$(OBJCOPY) -O binary $< $@
%.elf: %.S linker.ld
$(GCC) -Tlinker.ld $< -nostdlib -static -o $@
$(GCC) -Tlinker.ld $< -nostdlib -static -Wl,--no-gc-sections -o $@