uml.lds.S 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. #include <asm-generic/vmlinux.lds.h>
  2. OUTPUT_FORMAT(ELF_FORMAT)
  3. OUTPUT_ARCH(ELF_ARCH)
  4. ENTRY(_start)
  5. jiffies = jiffies_64;
  6. SECTIONS
  7. {
  8. /*This must contain the right address - not quite the default ELF one.*/
  9. PROVIDE (__executable_start = START);
  10. . = START + SIZEOF_HEADERS;
  11. /* Used in arch/um/kernel/mem.c. Any memory between START and __binary_start
  12. * is remapped.*/
  13. __binary_start = .;
  14. #ifdef MODE_TT
  15. .remap_data : { UNMAP_PATH (.data .bss) }
  16. .remap : { UNMAP_PATH (.text) }
  17. . = ALIGN(4096); /* Init code and data */
  18. #endif
  19. _stext = .;
  20. __init_begin = .;
  21. .init.text : {
  22. _sinittext = .;
  23. *(.init.text)
  24. _einittext = .;
  25. }
  26. . = ALIGN(4096);
  27. .text :
  28. {
  29. *(.text)
  30. SCHED_TEXT
  31. LOCK_TEXT
  32. *(.fixup)
  33. /* .gnu.warning sections are handled specially by elf32.em. */
  34. *(.gnu.warning)
  35. *(.gnu.linkonce.t*)
  36. . = ALIGN(4096);
  37. __syscall_stub_start = .;
  38. *(.__syscall_stub*)
  39. __syscall_stub_end = .;
  40. . = ALIGN(4096);
  41. }
  42. #include "asm/common.lds.S"
  43. init.data : { *(init.data) }
  44. .data :
  45. {
  46. . = ALIGN(KERNEL_STACK_SIZE); /* init_task */
  47. *(.data.init_task)
  48. *(.data)
  49. *(.gnu.linkonce.d*)
  50. CONSTRUCTORS
  51. }
  52. .data1 : { *(.data1) }
  53. .ctors :
  54. {
  55. *(.ctors)
  56. }
  57. .dtors :
  58. {
  59. *(.dtors)
  60. }
  61. .got : { *(.got.plt) *(.got) }
  62. .dynamic : { *(.dynamic) }
  63. .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
  64. .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
  65. /* We want the small data sections together, so single-instruction offsets
  66. can access them all, and initialized data all before uninitialized, so
  67. we can shorten the on-disk segment size. */
  68. .sdata : { *(.sdata) }
  69. _edata = .;
  70. PROVIDE (edata = .);
  71. . = ALIGN(0x1000);
  72. .sbss :
  73. {
  74. __bss_start = .;
  75. PROVIDE(_bss_start = .);
  76. *(.sbss)
  77. *(.scommon)
  78. }
  79. .bss :
  80. {
  81. *(.dynbss)
  82. *(.bss)
  83. *(COMMON)
  84. }
  85. _end = . ;
  86. PROVIDE (end = .);
  87. /* Stabs debugging sections. */
  88. .stab 0 : { *(.stab) }
  89. .stabstr 0 : { *(.stabstr) }
  90. .stab.excl 0 : { *(.stab.excl) }
  91. .stab.exclstr 0 : { *(.stab.exclstr) }
  92. .stab.index 0 : { *(.stab.index) }
  93. .stab.indexstr 0 : { *(.stab.indexstr) }
  94. .comment 0 : { *(.comment) }
  95. }