Code: Select all
SECTIONS
{
.text 0x9000 : {
StartOfTEXTSection = .; _StartOfTEXTSection = .; __StartOfTEXTSection = .;
code = .; _code = .; __code = .;
*(.text)
. = ALIGN(512);
EndOfTEXTSection = .; _EndOfTEXTSection = .; __EndOfTEXTSection = .;
}
.data : {
StartOfDATASection = .; _StartOfDATASection = .; __StartOfDATASection = .;
data = .; _data = .; __data = .;
*(.data)
. = ALIGN(512);
EndOfDATASection = .; _EndOfDATASection = .; __EndOfDATASection = .;
}
.bss : {
StartOfBSSSection = .; _StartOfBSSSection = .; __StartOfBSSSection = .;
bss = .; _bss = .; __bss = .;
*(.bss)
. = ALIGN(512);
EndOfBSSSection = .; _EndOfBSSSection = .; __EndOfBSSSection = .;
}
end = .; _end = .; __end = .;
EndOfKernel = .; _EndOfKernel = .; __EndOfKernel = .;
}
Code: Select all
Text Section : 9000 - CA00
Data Section : CA00 - CC00
Bss Section : CC00 - 10E00
Kernel End : 10FF0
And I get the end of kernel with EndOfKernel symbol, how can I get the start point of kernel?
And as a last question, are these sections lies in binary file as the order I put?(text, data, bss..)Or is there any order of sections?(First section must be text, than data...)