aboutsummaryrefslogtreecommitdiff
path: root/PL0_test.ld
diff options
context:
space:
mode:
authorWojtek Kosior <kwojtus@protonmail.com>2019-11-12 17:56:10 +0100
committerWojtek Kosior <kwojtus@protonmail.com>2019-11-12 17:56:10 +0100
commit533976feb8ea79c15fa905642d75adb58a0e6996 (patch)
tree11d5b9b56754e3457256d23c25535d19fc0402e1 /PL0_test.ld
parent30b44ef0b1177d13dd4f58c47979e7a6e598d81a (diff)
downloadrpi-MMU-example-533976feb8ea79c15fa905642d75adb58a0e6996.tar.gz
rpi-MMU-example-533976feb8ea79c15fa905642d75adb58a0e6996.zip
TEST CODE: prepare for switching to PL0
Diffstat (limited to 'PL0_test.ld')
-rw-r--r--PL0_test.ld44
1 files changed, 44 insertions, 0 deletions
diff --git a/PL0_test.ld b/PL0_test.ld
new file mode 100644
index 0000000..430e098
--- /dev/null
+++ b/PL0_test.ld
@@ -0,0 +1,44 @@
+ENTRY(_start)
+
+SECTIONS
+{
+ /* 0b10101010101000000000000000000000 */
+ . = 0xaaa00000;
+ __start = .;
+ __text_start = .;
+ .text :
+ {
+ /* have entry point at the beginning */
+ KEEP(*(.text.PL0main))
+ *(.text)
+ }
+ . = ALIGN(4096); /* align to page size */
+ __text_end = .;
+
+ __rodata_start = .;
+ .rodata :
+ {
+ *(.rodata)
+ }
+ . = ALIGN(4096); /* align to page size */
+ __rodata_end = .;
+
+ __data_start = .;
+ .data :
+ {
+ *(.data)
+ }
+ . = ALIGN(4096); /* align to page size */
+ __data_end = .;
+
+ __bss_start = .;
+ .bss :
+ {
+ bss = .;
+ *(.bss)
+ }
+ . = ALIGN(4096); /* align to page size */
+ __bss_end = .;
+ __bss_size = __bss_end - __bss_start;
+ __end = .;
+}