blob: ef69288c56971586ff58741f0b225f3b15601a08 (
plain)
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
|
#
# CDDL HEADER START
#
# This file and its contents are supplied under the terms of the
# Common Development and Distribution License ("CDDL"), version 1.0.
# You may only use this file in accordance with the terms of version
# 1.0 of the CDDL.
#
# A full copy of the text of the CDDL should have accompanied this
# source. A copy of the CDDL is also available via the Internet at
# http://www.illumos.org/license/CDDL.
#
# CDDL HEADER END
#
#
# Copyright 2022 Oxide Computer Company
#
$mapfile_version 2
# The .eh_frame data was ending up in front of the .text segment, causing issues
# when the guest attempted to start its payload
NULL_SEGMENT discard {
ASSIGN_SECTION eh_discard {
IS_NAME = .eh_frame;
};
};
LOAD_SEGMENT payload {
FLAGS = READ WRITE EXECUTE;
VADDR = 0x800000;
PADDR = 0x800000;
ALIGN = 0x1000;
# Make sure that payload_start.s`_start is the first thing in .text segment,
# since when we "boot", that is where we want to begin running.
ASSIGN_SECTION is_start_text {
IS_NAME = .text;
FILE_BASENAME = payload_start.o;
};
ASSIGN_SECTION is_text {
IS_NAME = .text;
};
ASSIGN_SECTION is_alloc {
FLAGS = ALLOC;
};
IS_ORDER = is_start_text is_text is_alloc;
};
|