Files
low-level-programming/ferrocyanide/raspi_os/kernel.ld
greg 4485fbb579 Add raspi_os here
Eventually this is gonna be part of Ferrocyanide
2017-03-25 22:47:34 -07:00

39 lines
870 B
Plaintext
Executable File

/******************************************************************************
* kernel.ld
* by Alex Chadwick
*
* A linker script for generation of raspberry pi kernel images.
******************************************************************************/
SECTIONS {
/*
* First and formost we need the .init section, containing the code to
* be run first. We allow room for the ATAGs and stack and conform to
* the bootloader's expectation by putting this code at 0x8000.
*/
.init 0x8000 : {
*(.init)
}
/*
* Next we put the rest of the code.
*/
.text : {
*(.text)
}
/*
* Next we put the data.
*/
.data : {
*(.data)
}
/*
* Finally comes everything else. A fun trick here is to put all other
* sections into this section, which will be discarded by default.
*/
/DISCARD/ : {
*(*)
}
}