linker: nios2: align rodata section
During testing with sorting section by alignment with qemu_nios2, if rodata section is not aligned on 4-byte boundary and its size not of multiple of 4, it would never boot correctly. So align the rodata here. This is in preparation to enable the linker option to sort sections by alignment. Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
parent
bbe6fa04b5
commit
8328d6df76
|
@ -141,6 +141,8 @@ SECTIONS
|
|||
|
||||
SECTION_PROLOGUE(_RODATA_SECTION_NAME,,)
|
||||
{
|
||||
. = ALIGN(4);
|
||||
|
||||
*(.rodata)
|
||||
*(".rodata.*")
|
||||
*(.gnu.linkonce.r.*)
|
||||
|
@ -154,6 +156,7 @@ SECTIONS
|
|||
#include <custom-rodata.ld>
|
||||
#endif
|
||||
|
||||
. = ALIGN(4);
|
||||
} GROUP_LINK_IN(ROMABLE_REGION)
|
||||
|
||||
_image_rom_end = .;
|
||||
|
|
Loading…
Reference in a new issue