vmlinux-nommu.lds 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  1. /*
  2. * vmlinux.lds.S -- master linker script for m68knommu arch
  3. *
  4. * (C) Copyright 2002-2012, Greg Ungerer <gerg@snapgear.com>
  5. *
  6. * This linker script is equipped to build either ROM loaded or RAM
  7. * run kernels.
  8. */
  9. #if defined(CONFIG_RAMKERNEL)
  10. #define KTEXT_ADDR CONFIG_KERNELBASE
  11. #endif
  12. #if defined(CONFIG_ROMKERNEL)
  13. #define KTEXT_ADDR CONFIG_ROMSTART
  14. #define KDATA_ADDR CONFIG_KERNELBASE
  15. #define LOAD_OFFSET KDATA_ADDR + (ADDR(.text) + SIZEOF(.text))
  16. #endif
  17. #include <asm/page.h>
  18. #include <asm/thread_info.h>
  19. #include <asm-generic/vmlinux.lds.h>
  20. OUTPUT_ARCH(m68k)
  21. ENTRY(_start)
  22. jiffies = jiffies_64 + 4;
  23. SECTIONS {
  24. #ifdef CONFIG_ROMVEC
  25. . = CONFIG_ROMVEC;
  26. .romvec : {
  27. __rom_start = .;
  28. _romvec = .;
  29. *(.romvec)
  30. *(.data..initvect)
  31. }
  32. #endif
  33. . = KTEXT_ADDR;
  34. _text = .;
  35. _stext = .;
  36. .text : {
  37. HEAD_TEXT
  38. TEXT_TEXT
  39. IRQENTRY_TEXT
  40. SOFTIRQENTRY_TEXT
  41. SCHED_TEXT
  42. CPUIDLE_TEXT
  43. LOCK_TEXT
  44. *(.fixup)
  45. . = ALIGN(16);
  46. }
  47. _etext = .;
  48. #ifdef KDATA_ADDR
  49. . = KDATA_ADDR;
  50. #endif
  51. _sdata = .;
  52. RO_DATA_SECTION(PAGE_SIZE)
  53. RW_DATA_SECTION(16, PAGE_SIZE, THREAD_SIZE)
  54. _edata = .;
  55. EXCEPTION_TABLE(16)
  56. NOTES
  57. . = ALIGN(PAGE_SIZE);
  58. __init_begin = .;
  59. INIT_TEXT_SECTION(PAGE_SIZE)
  60. INIT_DATA_SECTION(16)
  61. PERCPU_SECTION(16)
  62. .m68k_fixup : {
  63. __start_fixup = .;
  64. *(.m68k_fixup)
  65. __stop_fixup = .;
  66. }
  67. .init.data : {
  68. . = ALIGN(PAGE_SIZE);
  69. __init_end = .;
  70. }
  71. BSS_SECTION(0, 0, 0)
  72. _end = .;
  73. STABS_DEBUG
  74. .comment 0 : { *(.comment) }
  75. /* Sections to be discarded */
  76. DISCARDS
  77. }