vmlinux.lds.S 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. #include <asm-generic/vmlinux.lds.h>
  2. #include <asm/page.h>
  3. #include <asm/thread_info.h>
  4. #define ROMTOP 0x000000
  5. #define RAMTOP 0x400000
  6. jiffies = jiffies_64 + 4;
  7. ENTRY(_start)
  8. SECTIONS
  9. {
  10. #if defined(CONFIG_ROMKERNEL)
  11. . = ROMTOP;
  12. .vectors :
  13. {
  14. _vector = . ;
  15. *(.vector*)
  16. }
  17. #else
  18. . = RAMTOP;
  19. _ramstart = .;
  20. . = . + CONFIG_OFFSET;
  21. #endif
  22. _text = .;
  23. HEAD_TEXT_SECTION
  24. .text : {
  25. _stext = . ;
  26. TEXT_TEXT
  27. SCHED_TEXT
  28. LOCK_TEXT
  29. #if defined(CONFIG_ROMKERNEL)
  30. *(.int_redirect)
  31. #endif
  32. _etext = . ;
  33. }
  34. EXCEPTION_TABLE(16)
  35. NOTES
  36. RO_DATA_SECTION(4)
  37. ROMEND = .;
  38. #if defined(CONFIG_ROMKERNEL)
  39. . = RAMTOP;
  40. _ramstart = .;
  41. #define ADDR(x) ROMEND
  42. #endif
  43. _sdata = . ;
  44. __data_start = . ;
  45. RW_DATA_SECTION(0, PAGE_SIZE, THREAD_SIZE)
  46. #if defined(CONFIG_ROMKERNEL)
  47. #undef ADDR
  48. #endif
  49. . = ALIGN(0x4) ;
  50. __init_begin = .;
  51. INIT_TEXT_SECTION(4)
  52. INIT_DATA_SECTION(4)
  53. SECURITY_INIT
  54. __init_end = .;
  55. _edata = . ;
  56. _begin_data = LOADADDR(.data);
  57. _sbss =.;
  58. BSS_SECTION(0, 0 ,0)
  59. _ebss =.;
  60. _ramend = .;
  61. _end = .;
  62. DISCARDS
  63. }