xref: /linux/drivers/firmware/efi/libstub/zboot.lds (revision 34dc1baba215b826e454b8d19e4f24adbeb7d00d)
1/* SPDX-License-Identifier: GPL-2.0 */
2
3ENTRY(__efistub_efi_zboot_header);
4
5PROVIDE(zboot_code_size = ABSOLUTE(0));
6
7SECTIONS
8{
9	.head : ALIGN(4096) {
10		*(.head)
11	}
12
13	.text : {
14		*(.text* .init.text*)
15	}
16
17	.rodata : ALIGN(8) {
18		__efistub__gzdata_start = .;
19		*(.gzdata)
20		__efistub__gzdata_end = .;
21		*(.rodata* .init.rodata* .srodata*)
22
23		. = ALIGN(4);
24		__efistub_code_size = .;
25		LONG(zboot_code_size);
26
27		_etext = ALIGN(4096);
28		. = _etext;
29	}
30
31	.data : ALIGN(4096) {
32		*(.data* .init.data*)
33		_edata = ALIGN(512);
34		. = _edata;
35	}
36
37	.bss : {
38		*(.bss* .init.bss*)
39		_end = ALIGN(512);
40		. = _end;
41	}
42
43	/DISCARD/ : {
44		*(.modinfo .init.modinfo)
45	}
46}
47
48PROVIDE(__efistub__gzdata_size =
49		ABSOLUTE(__efistub__gzdata_end - __efistub__gzdata_start));
50
51PROVIDE(__data_rawsize = ABSOLUTE(_edata - _etext));
52PROVIDE(__data_size = ABSOLUTE(_end - _etext));
53