Advertisement
Guest User

Untitled

a guest
Dec 14th, 2022
32
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.86 KB | None | 0 0
  1. ENTRY(_start)
  2.  
  3. SECTIONS
  4. {
  5. .init 0x80000 :
  6. {
  7. PROVIDE (__start = .);
  8. *(.init)
  9. }
  10.  
  11. .text ALIGN(4096) :
  12. {
  13. *(.text.unlikely .text.*_unlikely)
  14. *(.text.exit .text.exit.*)
  15. *(.text.startup text.startup.*)
  16. *(.text.hot .text.hot.*)
  17. *(.text .stub .text.* .gnu.linkonce.t.*)
  18. *(.gnu.warning)
  19. }
  20.  
  21. . += CONSTANT(COMMONPAGESIZE);
  22.  
  23. .rodata ALIGN(4096) :
  24. {
  25. *(.rodata .rodata.* .gnu.linkonce.r*)
  26. }
  27.  
  28. .data ALIGN(4096) :
  29. {
  30. PROVIDE (__startup_begin = .);
  31. *(.startup)
  32. PROVIDE (__startup_end = .);
  33. PROVIDE (__shutdown_begin = .);
  34. *(.shutdown)
  35. PROVIDE (__shutdown_end = .);
  36.  
  37. *(.data .data.* .gnu.linkonce.d)
  38. SORT(CONSTRUCTORS)
  39.  
  40. PROVIDE(__ctors_begin = .);
  41. *(.ctors)
  42. PROVIDE(__ctors_end = .);
  43. }
  44.  
  45. .bss ALIGN(4096) :
  46. {
  47. bss = .;
  48. __bss_start = .;
  49. *(COMMON)
  50. *(.bss .bss.* .gnu.linkonce.b.*)
  51. }
  52. __bss_end = .;
  53. __bss_size = __bss_end - __bss_start;
  54.  
  55. __kernel_end = .;
  56. }
  57.  
  58. ----------------------------
  59. $ readelf -l build-rpi4/apollo/kernel.mod -l
  60.  
  61. Elf file type is EXEC (Executable file)
  62. Entry point 0x80000
  63. There is 1 program header, starting at offset 64
  64.  
  65. Program Headers:
  66. Type Offset VirtAddr PhysAddr
  67. FileSiz MemSiz Flags Align
  68. LOAD 0x0000000000000080 0x0000000000080000 0x0000000000080000
  69. 0x00000000000062b0 0x0000000000008818 RWE 0x10
  70.  
  71. Section to Segment mapping:
  72. Segment Sections...
  73. 00 .init .text .rodata .data drivers modules .bss
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement