[acc25ee] | 1 | OUTPUT_ARCH(powerpc) |
---|
[697a6ca] | 2 | OUTPUT_FORMAT ("elf32-powerpc", "elf32-powerpc", "elf32-powerpc") |
---|
[acc25ee] | 3 | /* Do we need any of these for elf? |
---|
| 4 | __DYNAMIC = 0; */ |
---|
| 5 | SECTIONS |
---|
| 6 | { |
---|
| 7 | .text : |
---|
| 8 | { |
---|
| 9 | /* We have to build the header by hand, painful since ppcboot |
---|
| 10 | format support is very poor in binutils. |
---|
| 11 | objdump -b ppcboot zImage --all-headers can be used to check. */ |
---|
| 12 | /* The following line can be added as a branch to use the same image |
---|
| 13 | * for netboot as for prepboots, the only problem is that objdump |
---|
| 14 | * did not in this case recognize the format since it insisted |
---|
| 15 | * in checking the x86 code area held only zeroes. |
---|
| 16 | */ |
---|
| 17 | LONG(0x48000000+start); |
---|
| 18 | . = 0x1be; BYTE(0x80); BYTE(0) |
---|
| 19 | BYTE(2); BYTE(0); BYTE(0x41); BYTE(1); |
---|
| 20 | BYTE(0x12); BYTE(0x4f); LONG(0); |
---|
| 21 | BYTE(((_edata + 0x1ff)>>9)&0xff); |
---|
| 22 | BYTE(((_edata + 0x1ff)>>17)&0xff); |
---|
| 23 | BYTE(((_edata + 0x1ff)>>25)&0xff); |
---|
| 24 | . = 0x1fe; |
---|
| 25 | BYTE(0x55); |
---|
| 26 | BYTE(0xaa); |
---|
| 27 | BYTE(start&0xff); |
---|
| 28 | BYTE((start>>8)&0xff); |
---|
| 29 | BYTE((start>>16)&0xff); |
---|
| 30 | BYTE((start>>24)&0xff); |
---|
| 31 | BYTE(_edata&0xff); |
---|
| 32 | BYTE((_edata>>8)&0xff); |
---|
| 33 | BYTE((_edata>>16)&0xff); |
---|
| 34 | BYTE((_edata>>24)&0xff); |
---|
| 35 | BYTE(0); /* flags */ |
---|
| 36 | BYTE(0); /* os_id */ |
---|
| 37 | BYTE(0x4C); BYTE(0x69); BYTE(0x6e); |
---|
| 38 | BYTE(0x75); BYTE(0x78); /* Partition name */ |
---|
| 39 | . = 0x400; |
---|
| 40 | *(.text) |
---|
| 41 | *(.sdata2) |
---|
| 42 | *(.rodata) |
---|
[c75f2d1] | 43 | *(.rodata*) |
---|
[acc25ee] | 44 | } |
---|
| 45 | /* . = ALIGN(16); */ |
---|
| 46 | .image : |
---|
| 47 | { |
---|
| 48 | rtems.gz(*) |
---|
| 49 | . = ALIGN(4); |
---|
| 50 | *.gz(*) |
---|
| 51 | } |
---|
| 52 | /* Read-write section, merged into data segment: */ |
---|
| 53 | /* . = ALIGN(4096); */ |
---|
| 54 | .reloc : |
---|
| 55 | { |
---|
| 56 | *(.got) |
---|
| 57 | _GOT2_TABLE_ = .; |
---|
| 58 | *(.got2) |
---|
| 59 | _FIXUP_TABLE_ = .; |
---|
| 60 | *(.fixup) |
---|
| 61 | } |
---|
| 62 | |
---|
| 63 | __got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2; |
---|
| 64 | __fixup_entries = (. - _FIXUP_TABLE_)>>2; |
---|
| 65 | |
---|
| 66 | .handlers : |
---|
| 67 | { |
---|
| 68 | *(.exception) |
---|
| 69 | } |
---|
| 70 | |
---|
| 71 | .data : |
---|
| 72 | { |
---|
| 73 | *(.data) |
---|
[c75f2d1] | 74 | *(.data*) |
---|
[acc25ee] | 75 | *(.sdata) |
---|
| 76 | . = ALIGN(4); |
---|
| 77 | _edata = .; |
---|
| 78 | } |
---|
| 79 | PROVIDE(_binary_initrd_gz_start = 0); |
---|
| 80 | PROVIDE(_binary_initrd_gz_end = 0); |
---|
| 81 | _rtems_gz_size = _binary_rtems_gz_end - _binary_rtems_gz_start; |
---|
| 82 | _rtems_size = __rtems_end - __rtems_start; |
---|
| 83 | .bss : |
---|
| 84 | { |
---|
| 85 | *(.sbss) |
---|
| 86 | *(.bss) |
---|
| 87 | . = ALIGN(4); |
---|
| 88 | } |
---|
| 89 | __bss_words = SIZEOF(.bss)>>2; |
---|
| 90 | __size = . ; |
---|
| 91 | /DISCARD/ : |
---|
| 92 | { |
---|
| 93 | *(.comment) |
---|
| 94 | } |
---|
| 95 | } |
---|
| 96 | |
---|