forked from wolfSSL/wolfBoot
-
Notifications
You must be signed in to change notification settings - Fork 0
/
RISCV.ld
55 lines (47 loc) · 1006 Bytes
/
RISCV.ld
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
OUTPUT_ARCH( "riscv" )
ENTRY( _reset )
MEMORY
{
FLASH(rxai!w) : ORIGIN = @WOLFBOOT_TEST_APP_ADDRESS@, LENGTH = @WOLFBOOT_TEST_APP_SIZE@
RAM(wxa!ri) : ORIGIN = 0x80001000, LENGTH = 12K
}
SECTIONS
{
.text :
{
_start_text = .;
KEEP(*(.init))
. = ORIGIN(FLASH) + 0x100;
_start_vector = .;
KEEP(*(.isr_vector))
*(.text*)
*(.rodata*)
*(.srodata*)
. = ALIGN(4);
_end_text = .;
} > FLASH
_stored_data = .;
.data : AT (_stored_data)
{
. = ALIGN(4096);
_start_data = .;
KEEP(*(.ramcode*))
. = ALIGN(4);
*(.data*)
_global_pointer = . + 0x800;
*(.sdata*)
. = ALIGN(4);
_end_data = .;
} > RAM
.bss :
{
_start_bss = .;
*(.bss*)
*(COMMON)
. = ALIGN(4);
_end_bss = .;
_end = .;
} > RAM
}
PROVIDE(_start_heap = _end);
PROVIDE(_end_stack = ORIGIN(RAM) + (LENGTH(RAM)) );