linker64.ld 662 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. OUTPUT_ARCH(riscv)
  2. ENTRY(_start)
  3. BASE_ADDRESS = 0x80200000;
  4. SECTIONS
  5. {
  6. /* Load the kernel at this address: "." means the current address */
  7. . = BASE_ADDRESS;
  8. start = .;
  9. .text : {
  10. stext = .;
  11. *(.text.entry)
  12. *(.text .text.*)
  13. . = ALIGN(4K);
  14. etext = .;
  15. }
  16. .rodata : {
  17. srodata = .;
  18. *(.rodata .rodata.*)
  19. . = ALIGN(4K);
  20. erodata = .;
  21. }
  22. .data : {
  23. sdata = .;
  24. *(.data .data.*)
  25. edata = .;
  26. }
  27. .stack : {
  28. *(.bss.stack)
  29. }
  30. .bss : {
  31. sbss = .;
  32. *(.bss .bss.*)
  33. ebss = .;
  34. }
  35. PROVIDE(end = .);
  36. }