Move the actual code to the front of the segment and make sure the IVT

can be put right at the front when put in its own section. This makes
sure that when the loader can only map a relatively small part of the
PBVM, the IVT and the startup code is wired.
This commit is contained in:
Marcel Moolenaar 2011-03-14 05:16:12 +00:00
parent 69be896a5e
commit f195d1e30c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/projects/altix/; revision=219630

View File

@ -9,6 +9,22 @@ SECTIONS
/* Read-only sections, merged into text segment: */
. = kernel_text + SIZEOF_HEADERS;
.interp : { *(.interp) }
PROVIDE (btext = .);
.ivt : { *(.ivt) }
.text :
{
*(.text.ivt)
*(.text .stub .text.* .gnu.linkonce.t.*)
/* .gnu.warning sections are handled specially by elf32.em. */
*(.gnu.warning)
} = 0x00300000010070000002000001000400
.init : { *(.init) } = 0x00300000010070000002000001000400
.plt : { *(.plt) }
.fini : { *(.fini) } = 0x00300000010070000002000001000400
_etext = .;
PROVIDE (etext = .);
.hash : { *(.hash) }
.dynsym : { *(.dynsym) }
.dynstr : { *(.dynstr) }
@ -30,34 +46,20 @@ SECTIONS
.rela.bss : { *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) }
.rela.plt : { *(.rela.plt) }
.rela.IA_64.pltoff : { *(.rela.IA_64.pltoff) }
PROVIDE (btext = .);
.init :
{
*(.init)
} =0x00300000010070000002000001000400
.plt : { *(.plt) }
.text :
{
*(.text .stub .text.* .gnu.linkonce.t.*)
/* .gnu.warning sections are handled specially by elf32.em. */
*(.gnu.warning)
} =0x00300000010070000002000001000400
.fini :
{
*(.fini)
} =0x00300000010070000002000001000400
_etext = .;
PROVIDE (etext = .);
.IA_64.unwind_info : { *(.IA_64.unwind_info* .gnu.linkonce.ia64unwi.*) }
.IA_64.unwind : { *(.IA_64.unwind* .gnu.linkonce.ia64unw.*) }
.rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) }
.rodata1 : { *(.rodata1) }
.sdata2 : { *(.sdata2 .sdata2.* .gnu.linkonce.s2.*) }
.sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
.opd : { *(.opd) }
.IA_64.unwind_info : { *(.IA_64.unwind_info* .gnu.linkonce.ia64unwi.*) }
.IA_64.unwind : { *(.IA_64.unwind* .gnu.linkonce.ia64unw.*) }
/* Adjust the address for the data segment. We want to start in the next
page in the loader virtual memory. */
. = ALIGN(65536);
.data :
{
*(.data.kstack .data .data.* .gnu.linkonce.d.*)