xref: /linux/arch/powerpc/boot/zImage.lds.S (revision bb9707077b4ee5f77bc9939b057ff8a0d410296f)
1#include <asm-generic/vmlinux.lds.h>
2
3#ifdef CONFIG_PPC64_BOOT_WRAPPER
4OUTPUT_ARCH(powerpc:common64)
5#else
6OUTPUT_ARCH(powerpc:common)
7#endif
8ENTRY(_zimage_start)
9EXTERN(_zimage_start)
10SECTIONS
11{
12  .text      :
13  {
14    _start = .;
15    *(.text)
16    *(.fixup)
17    _etext = .;
18  }
19  . = ALIGN(4096);
20  .data    :
21  {
22    *(.rodata*)
23    *(.data*)
24    *(.sdata*)
25#ifndef CONFIG_PPC64_BOOT_WRAPPER
26    *(.got2)
27#endif
28  }
29  .dynsym : { *(.dynsym) }
30  .dynstr : { *(.dynstr) }
31  .dynamic :
32  {
33    __dynamic_start = .;
34    *(.dynamic)
35  }
36  .hash : { *(.hash) }
37  .interp : { *(.interp) }
38  .rela.dyn :
39  {
40#ifdef CONFIG_PPC64_BOOT_WRAPPER
41    __rela_dyn_start = .;
42#endif
43    *(.rela*)
44  }
45
46  . = ALIGN(8);
47  .kernel:dtb :
48  {
49    _dtb_start = .;
50    *(.kernel:dtb)
51    _dtb_end = .;
52  }
53
54  . = ALIGN(4096);
55  .kernel:vmlinux.strip :
56  {
57    _vmlinux_start =  .;
58    *(.kernel:vmlinux.strip)
59    _vmlinux_end =  .;
60  }
61
62  . = ALIGN(4096);
63  .kernel:initrd :
64  {
65    _initrd_start =  .;
66    *(.kernel:initrd)
67    _initrd_end =  .;
68  }
69
70#ifdef CONFIG_PPC64_BOOT_WRAPPER
71  .got :
72  {
73    __toc_start = .;
74    *(.got)
75    *(.toc)
76  }
77#endif
78
79  . = ALIGN(4096);
80  .bss       :
81  {
82    _edata  =  .;
83    __bss_start = .;
84    *(.sbss)
85    *(.bss)
86    *(COMMON)
87    _end = . ;
88  }
89}
90