-
Notifications
You must be signed in to change notification settings - Fork 90
/
x86_fsp_tgl_stage1.ld.in
128 lines (112 loc) · 2.48 KB
/
x86_fsp_tgl_stage1.ld.in
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
FLASH_SIZE = @BOOTLOADER_PARTITION_SIZE@;
FLASH_START = 0x100000000 - @BOOTLOADER_PARTITION_SIZE@;
UCODE0_BASE = @UCODE0_BASE@;
FIT_TABLE = 0xffe00000;
FSP_S_ORIGIN = @FSP_S_BASE@;
WOLFBOOT_ORIGIN = @WOLFBOOT_ORIGIN@;
FSP_T_ORIGIN = @FSP_T_BASE@;
FSP_M_ORIGIN = @FSP_M_BASE@;
JMPTO32_ORIGIN = 0xfffffe00;
FIT_TABLE_PTR = 0xffffffc0;
RESETVECTOR_START = 0xffffffec;
DATA_MEM_START = 0x100000; /* 1Mb */
KEYSTORE_START = 0xffffe000;
MAX_POLICY_SIZE = 512;
OUTPUT_FORMAT(elf32-i386)
MEMORY
{
FLASH (rx) : ORIGIN = FLASH_START LENGTH = FLASH_SIZE
RAM (rwx) : ORIGIN = 0x0 LENGTH = FLASH_START
}
SECTIONS
{
.stage2 FLASH_START :
{
_wolfboot_flash_start = .;
KEEP(*(.sig_wolfboot_raw*))
KEEP(*(.wolfboot))
_wolfboot_flash_end = .;
} > FLASH
.policy :
{
. = ALIGN(4);
_policy_size_u32 = .;
. += 4;
_start_policy = .;
. += MAX_POLICY_SIZE;
_end_policy = .;
} > FLASH
.ucode_update0 UCODE0_BASE :
{
KEEP(*(.ucode0))
} > FLASH
.fit_table FIT_TABLE :
{
KEEP(*(.fit));
. = ALIGN(256*1024);
}
.fsp_s FSP_S_ORIGIN :
{
_fsp_s_hdr = .;
KEEP(*(.sig_fsp_s*))
_start_fsp_s = .;
KEEP(*(.fsp_s))
_end_fsp_s = .;
} > FLASH
.bootloader WOLFBOOT_ORIGIN :
{
KEEP(./tgl_fsp.o(.boot))
KEEP(*(.boot*))
KEYSTORE_START = .;
KEEP(*(.keystore*))
*(.text*)
*(.rodata*)
. = ALIGN(256);
} > FLASH
_stored_data = .;
.data DATA_MEM_START : AT (_stored_data)
{
_start_data = .;
KEEP(*(.data*))
. = ALIGN(4);
KEEP(*(.ramcode))
. = ALIGN(4);
_end_data = .;
} > RAM
.bss(NOLOAD) : AT (_end_data)
{
_start_bss = .;
__bss_start__ = .;
*(.bss*)
. = ALIGN(4);
_end_bss = .;
__bss_end__ = .;
_end = .;
} > RAM
.fsp_t FSP_T_ORIGIN :
AT(FSP_T_ORIGIN)
{
_start_fsp_t = .;
KEEP(*(.fsp_t))
} > FLASH
.fsp_m FSP_M_ORIGIN :
{
_start_fsp_m = .;
KEEP(*(.fsp_m))
_end_fsp_m = .;
} > FLASH
.jmpto32 JMPTO32_ORIGIN :
{
_off_boot = ABSOLUTE(.) & 0xffff;
KEEP(*boot_x86_fsp_start.o(.jmpto32*));
KEEP(*(.jmpto32));
} > FLASH
.fit_table_tr FIT_TABLE_PTR :
{
QUAD(fit_table);
} > FLASH
.reset_vector RESETVECTOR_START :
{
KEEP(*(.reset_vector))
} > FLASH
}