vmlinux.lds.S 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /* ld script to make M32R Linux kernel
  3. */
  4. #include <asm-generic/vmlinux.lds.h>
  5. #include <asm/addrspace.h>
  6. #include <asm/page.h>
  7. #include <asm/thread_info.h>
  8. OUTPUT_ARCH(m32r)
  9. #if defined(__LITTLE_ENDIAN__)
  10. jiffies = jiffies_64;
  11. #else
  12. jiffies = jiffies_64 + 4;
  13. #endif
  14. kernel_entry = boot - 0x80000000;
  15. ENTRY(kernel_entry)
  16. SECTIONS
  17. {
  18. . = CONFIG_MEMORY_START + __PAGE_OFFSET;
  19. eit_vector = .;
  20. . = . + 0x1000;
  21. .empty_zero_page : { *(.empty_zero_page) } = 0
  22. /* read-only */
  23. _text = .; /* Text and read-only data */
  24. .boot : { *(.boot) } = 0
  25. .text : {
  26. HEAD_TEXT
  27. TEXT_TEXT
  28. SCHED_TEXT
  29. CPUIDLE_TEXT
  30. LOCK_TEXT
  31. *(.fixup)
  32. *(.gnu.warning)
  33. } = 0x9090
  34. #ifdef CONFIG_SMP
  35. . = ALIGN(65536);
  36. .eit_vector4 : { *(.eit_vector4) }
  37. #endif
  38. _etext = .; /* End of text section */
  39. EXCEPTION_TABLE(16)
  40. NOTES
  41. _sdata = .; /* Start of data section */
  42. RODATA
  43. RW_DATA_SECTION(32, PAGE_SIZE, THREAD_SIZE)
  44. _edata = .; /* End of data section */
  45. /* will be freed after init */
  46. . = ALIGN(PAGE_SIZE); /* Init code and data */
  47. __init_begin = .;
  48. INIT_TEXT_SECTION(PAGE_SIZE)
  49. INIT_DATA_SECTION(16)
  50. PERCPU_SECTION(32)
  51. . = ALIGN(PAGE_SIZE);
  52. __init_end = .;
  53. /* freed after init ends here */
  54. BSS_SECTION(0, 0, 4)
  55. _end = . ;
  56. /* Stabs debugging sections. */
  57. .stab 0 : { *(.stab) }
  58. .stabstr 0 : { *(.stabstr) }
  59. .stab.excl 0 : { *(.stab.excl) }
  60. .stab.exclstr 0 : { *(.stab.exclstr) }
  61. .stab.index 0 : { *(.stab.index) }
  62. .stab.indexstr 0 : { *(.stab.indexstr) }
  63. .comment 0 : { *(.comment) }
  64. /* Sections to be discarded */
  65. DISCARDS
  66. }