Commit Graph

11 Commits

Author SHA1 Message Date
Andre Richter
f6190f85b7
ASM: Remove use of .equ
The LLVM assembler apparently causes the .equ directive to create symbols
instead of just a local and temporary variable.

Work around this by using const operands with global_asm!.
2022-05-03 23:53:45 +02:00
Andre Richter
d901ae6cfe
Update copyright 2022-01-15 21:50:11 +01:00
Andre Richter
7d02537515
Bump toolchain 2021-12-20 00:01:38 +01:00
Andre Richter
8c2cec00be
Assembly: Use local label syntax for named labels
This prevents that they show up in the symbol table.
2021-07-04 15:50:46 +02:00
Andre Richter
2432c0d283
Revert to assembly boot code
It is too risky to rely on the compiler to not insert any operations using the
stack.

Having a stack-setting call in Rust using the cortex-a crate as the first action
in a Rust-only _start() function does not work if you're subsequently using the
stack, because the compiler often inserts the operations to make room on the
stack to prepare a function call BEFORE the call to set the stack, which crashes
the boot process.

Hence, keep on using a small piece of assembly boot code throughout.
2021-03-20 09:41:43 +01:00
Andre Richter
e7cb61b389
Refactoring
- Don't wildcard-import from arch modules. Make it explicit.
- Put translation table code into its own module.
- Put boot code in boot.rs instead of cpu.rs
- Other minor changes, most memory subsystem.
2021-01-23 22:43:59 +01:00
Andre Richter
44bb3f8942
Update copyright year 2021-01-01 11:28:32 +01:00
Andre Richter
53c1163c51
01: Remove LTO to fix linking bug.
For some reason, LTO caused "_start" to start at 0x00080020
instead of 0x00080000.
2020-12-27 00:20:24 +01:00
Andre Richter
cfc3bfc996
Switch to new Rust inline asm! syntax 2020-06-29 22:27:31 +02:00
Andre Richter
82f97c000b
Switch to llvm_asm! to avoid future breakage 2020-04-22 21:38:34 +02:00
Andre Richter
6588cd9be6
Refactor tutorial 01 2020-03-28 13:27:39 +01:00