-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathkernel.ld
More file actions
43 lines (39 loc) · 910 Bytes
/
kernel.ld
File metadata and controls
43 lines (39 loc) · 910 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/******************************************************************************
* 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 IVT.
*/
.init 0x8000 : {
*(.init)
} = 0x3F3F3F3F
/*
* Next we put the data.
*/
.data 0x9080 : {
*(.data)
*.c.o(*)
} = 0x3F3F3F3F
/*
* We allow room for the ATAGs and the stack and then start our code at
* 0x8000.
*/
.text : {
*.c.o(.text)
*(.text)
} = 0x3F3F3F3F
/*
* Finally comes everything else. A fun trick here is to put all other
* sections into this section, which will be discarded by default.
* Note - discards debug symbols, removed for now...
*/
/*
/DISCARD/ : {
*(*)
}
*/
}