u-boot-spl.lds 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Copyright (c) 2014 Xilinx, Inc. Michal Simek
  4. * Copyright (c) 2004-2008 Texas Instruments
  5. *
  6. * (C) Copyright 2002
  7. * Gary Jennejohn, DENX Software Engineering, <garyj@denx.de>
  8. */
  9. MEMORY { .sram : ORIGIN = IMAGE_TEXT_BASE,\
  10. LENGTH = IMAGE_MAX_SIZE }
  11. MEMORY { .sdram : ORIGIN = CONFIG_SPL_BSS_START_ADDR, \
  12. LENGTH = CONFIG_SPL_BSS_MAX_SIZE }
  13. OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
  14. OUTPUT_ARCH(arm)
  15. ENTRY(_start)
  16. SECTIONS
  17. {
  18. . = ALIGN(4);
  19. .text :
  20. {
  21. __image_copy_start = .;
  22. *(.vectors)
  23. CPUDIR/start.o (.text*)
  24. *(.text*)
  25. } > .sram
  26. . = ALIGN(4);
  27. .rodata : {
  28. *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
  29. } > .sram
  30. . = ALIGN(4);
  31. .data : {
  32. *(.data*)
  33. } > .sram
  34. . = ALIGN(4);
  35. .u_boot_list : {
  36. KEEP(*(SORT(.u_boot_list*)));
  37. } > .sram
  38. . = ALIGN(4);
  39. _image_binary_end = .;
  40. _end = .;
  41. /* Move BSS section to RAM because of FAT */
  42. .bss (NOLOAD) : {
  43. __bss_start = .;
  44. *(.bss*)
  45. . = ALIGN(4);
  46. __bss_end = .;
  47. } > .sdram
  48. /DISCARD/ : { *(.dynsym) }
  49. /DISCARD/ : { *(.dynstr*) }
  50. /DISCARD/ : { *(.dynamic*) }
  51. /DISCARD/ : { *(.plt*) }
  52. /DISCARD/ : { *(.interp*) }
  53. /DISCARD/ : { *(.gnu*) }
  54. }