1.1 --- a/blink.S Wed Oct 17 22:50:15 2018 +0200
1.2 +++ b/blink.S Wed Oct 17 22:54:45 2018 +0200
1.3 @@ -54,7 +54,10 @@
1.4 DEVCFG2<6:4> = FPLLMUL<2:0> = 111;
1.5 DEVCFG2<2:0> = FPLLIDIV<2:0> = 011 */
1.6
1.7 -.text
1.8 +/* The start routine is placed at the boot location. */
1.9 +
1.10 +.section .boot, "a"
1.11 +
1.12 .globl _start
1.13
1.14 _start:
2.1 --- a/blink.ld Wed Oct 17 22:50:15 2018 +0200
2.2 +++ b/blink.ld Wed Oct 17 22:54:45 2018 +0200
2.3 @@ -27,21 +27,17 @@
2.4
2.5 SECTIONS
2.6 {
2.7 - .text : { *(.text*) } > kseg0_boot_mem AT > physical_boot_mem
2.8 - .flash : { *(.flash*) } > kseg0_program_mem AT > physical_program_mem
2.9 - .bss : { *(.bss*) } > kseg1_data_mem
2.10 - .got : {
2.11 - _gp = ALIGN(16);
2.12 - *(.got*)
2.13 - } > kseg0_boot_mem AT > physical_boot_mem
2.14 - .devcfg0 : {
2.15 - *(.devcfg0)
2.16 - } > config0 AT > physical_config0
2.17 - .devcfg1 : {
2.18 - *(.devcfg1)
2.19 - } > config1 AT > physical_config1
2.20 - .devcfg2 : {
2.21 - *(.devcfg2)
2.22 - } > config2 AT > physical_config2
2.23 + .boot : { *(.boot*) } > kseg0_boot_mem AT > physical_boot_mem
2.24 + .vectors : { *(.vectors*) } > kseg0_program_mem AT > physical_program_mem
2.25 + .text : { *(.text*) } > kseg0_program_mem AT > physical_program_mem
2.26 + .bss : { *(.bss*) } > kseg1_data_mem
2.27 + .rodata : { *(.rodata*) } > kseg0_program_mem AT > physical_program_mem
2.28 + .got : {
2.29 + _gp = ALIGN(16);
2.30 + *(.got*)
2.31 + } > kseg0_program_mem AT > physical_program_mem
2.32 + .devcfg0 : { *(.devcfg0) } > config0 AT > physical_config0
2.33 + .devcfg1 : { *(.devcfg1) } > config1 AT > physical_config1
2.34 + .devcfg2 : { *(.devcfg2) } > config2 AT > physical_config2
2.35 /DISCARD/ : { *(.reginfo) *(.MIPS.abiflags) }
2.36 }