vmlinux.lds.S 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  1. #define VMLINUX_SYMBOL(_sym_) _##_sym_
  2. #include <asm-generic/vmlinux.lds.h>
  3. /* target memory map */
  4. #ifdef CONFIG_H8300H_GENERIC
  5. #define ROMTOP 0x000000
  6. #define ROMSIZE 0x400000
  7. #define RAMTOP 0x400000
  8. #define RAMSIZE 0x400000
  9. #endif
  10. #ifdef CONFIG_H8300H_AKI3068NET
  11. #define ROMTOP 0x000000
  12. #define ROMSIZE 0x080000
  13. #define RAMTOP 0x400000
  14. #define RAMSIZE 0x200000
  15. #endif
  16. #ifdef CONFIG_H8300H_H8MAX
  17. #define ROMTOP 0x000000
  18. #define ROMSIZE 0x080000
  19. #define RAMTOP 0x400000
  20. #define RAMSIZE 0x200000
  21. #endif
  22. #ifdef CONFIG_H8300H_SIM
  23. #define ROMTOP 0x000000
  24. #define ROMSIZE 0x400000
  25. #define RAMTOP 0x400000
  26. #define RAMSIZE 0x400000
  27. #endif
  28. #ifdef CONFIG_H8S_SIM
  29. #define ROMTOP 0x000000
  30. #define ROMSIZE 0x400000
  31. #define RAMTOP 0x400000
  32. #define RAMSIZE 0x800000
  33. #endif
  34. #ifdef CONFIG_H8S_EDOSK2674
  35. #define ROMTOP 0x000000
  36. #define ROMSIZE 0x400000
  37. #define RAMTOP 0x400000
  38. #define RAMSIZE 0x800000
  39. #endif
  40. #if defined(CONFIG_H8300H_SIM) || defined(CONFIG_H8S_SIM)
  41. INPUT(romfs.o)
  42. #endif
  43. _jiffies = _jiffies_64 + 4;
  44. ENTRY(__start)
  45. SECTIONS
  46. {
  47. #if defined(CONFIG_ROMKERNEL)
  48. . = ROMTOP;
  49. .vectors :
  50. {
  51. __vector = . ;
  52. *(.vectors*)
  53. }
  54. #else
  55. . = RAMTOP;
  56. .bootvec :
  57. {
  58. *(.bootvec)
  59. }
  60. #endif
  61. .text :
  62. {
  63. #if defined(CONFIG_ROMKERNEL)
  64. *(.int_redirect)
  65. #endif
  66. __stext = . ;
  67. *(.text)
  68. SCHED_TEXT
  69. LOCK_TEXT
  70. __etext = . ;
  71. . = ALIGN(16); /* Exception table */
  72. ___start___ex_table = .;
  73. *(__ex_table)
  74. ___stop___ex_table = .;
  75. }
  76. RODATA
  77. #if defined(CONFIG_ROMKERNEL)
  78. SECURITY_INIT
  79. #endif
  80. ROEND = .;
  81. #if defined(CONFIG_ROMKERNEL)
  82. . = RAMTOP;
  83. .data : AT(ROEND)
  84. #else
  85. .data :
  86. #endif
  87. {
  88. __sdata = . ;
  89. ___data_start = . ;
  90. . = ALIGN(0x2000) ;
  91. *(.data.init_task)
  92. . = ALIGN(0x4) ;
  93. *(.data)
  94. . = ALIGN(0x4) ;
  95. *(.data.*)
  96. . = ALIGN(0x4) ;
  97. ___init_begin = .;
  98. __sinittext = .;
  99. *(.init.text)
  100. __einittext = .;
  101. *(.init.data)
  102. . = ALIGN(0x4) ;
  103. ___setup_start = .;
  104. *(.init.setup)
  105. . = ALIGN(0x4) ;
  106. ___setup_end = .;
  107. ___initcall_start = .;
  108. INITCALLS
  109. ___initcall_end = .;
  110. ___con_initcall_start = .;
  111. *(.con_initcall.init)
  112. ___con_initcall_end = .;
  113. *(.exit.text)
  114. *(.exit.data)
  115. . = ALIGN(4);
  116. ___initramfs_start = .;
  117. *(.init.ramfs)
  118. ___initramfs_end = .;
  119. . = ALIGN(0x4) ;
  120. ___init_end = .;
  121. __edata = . ;
  122. }
  123. #if defined(CONFIG_RAMKERNEL)
  124. SECURITY_INIT
  125. #endif
  126. __begin_data = LOADADDR(.data);
  127. .bss :
  128. {
  129. . = ALIGN(0x4) ;
  130. __sbss = . ;
  131. *(.bss*)
  132. . = ALIGN(0x4) ;
  133. *(COMMON)
  134. . = ALIGN(0x4) ;
  135. __ebss = . ;
  136. __end = . ;
  137. __ramstart = .;
  138. }
  139. /DISCARD/ : {
  140. *(.exitcall.exit)
  141. }
  142. .romfs :
  143. {
  144. *(.romfs*)
  145. }
  146. . = RAMTOP+RAMSIZE;
  147. .dummy :
  148. {
  149. COMMAND_START = . - 0x200 ;
  150. __ramend = . ;
  151. }
  152. }