source: rtems/c/src/lib/libbsp/powerpc/shared/bootloader/ppcboot.lds @ eba2e4f

4.104.114.84.95
Last change on this file since eba2e4f was ef99210e, checked in by Joel Sherrill <joel.sherrill@…>, on Jun 29, 2000 at 4:27:47 PM

Patch from Eric Valette to do some cleanup.

  • Property mode set to 100644
File size: 2.1 KB
Line 
1OUTPUT_ARCH(powerpc)
2/* OUTPUT_FORMAT(ppcboot) */
3/* Do we need any of these for elf?
4   __DYNAMIC = 0;    */
5SECTIONS
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)
43  }
44/*  . = ALIGN(16); */
45  .image :
46  {
47    rtems.gz(*)
48    . = ALIGN(4);
49    *.gz(*)
50  }
51  /* Read-write section, merged into data segment: */
52  /* . = ALIGN(4096); */
53  .reloc   :
54  {
55    *(.got)
56    _GOT2_TABLE_ = .;
57    *(.got2)
58    _FIXUP_TABLE_ = .;
59    *(.fixup)
60  }
61
62  __got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
63  __fixup_entries = (. - _FIXUP_TABLE_)>>2;
64
65  .handlers :
66  {
67    *(.exception)
68  }
69
70  .data    :
71  {
72    *(.data)
73    *(.sdata)
74    . = ALIGN(4);
75    _edata = .;
76  }
77  PROVIDE(_binary_initrd_gz_start = 0);
78  PROVIDE(_binary_initrd_gz_end = 0);
79  _rtems_gz_size = _binary_rtems_gz_end - _binary_rtems_gz_start;
80  _rtems_size = __rtems_end - __rtems_start;
81  .bss :
82  {
83    *(.sbss)
84    *(.bss)
85    . = ALIGN(4);
86  }
87  __bss_words = SIZEOF(.bss)>>2;
88  __size = . ;
89  /DISCARD/ :
90  {
91    *(.comment)
92  }
93}
94
Note: See TracBrowser for help on using the repository browser.