View on GitHub

magnetite_os

An experimental Rust OS development project

Past decisions

Past decisions that were made before the decisions record was established can be found here. The decisions may not have an exact date of introduction, so the retrospective descriptions are instead labeled by the date they were authored.

(interactive - up one level: magnetite_os/)

Retrospect 2025-08-30, part 2

Title

Implement self-contained volume boot record with file system parsing capability

Introduction date

Status

Sustained

Rationale

Normally, loading raw sectors appended to the volume boot record (VBR) would be enough, but if real-world support is desired, then the VBR should be capable of parsing file systems and loading a second-stage loader from indeterminate locations.

From a more personal angle, implementing a self-contained VBR would prove to be a productive challenge: making a boot sector program both space-efficient and resillient.

Consequence

Retrospect 2025-08-30, part 1

Title

Implement Relocatable HAL with ABI+API Contracts

Introduction date

Unknown; gradual

Status

Reversed (through curating)

Rationale

The initial thought process was that the bootloader and the kernel should be able to reuse the same hardware drivers not just at the source level, but also at the binary level.

It was envisioned that the second-stage loader should have a HAL and a vector table (VT) packaged together with it. In addition, the HAL and VT should be relocatable, so that they can still be used by the kernel after copying them into kernel memory: relocatability was, and still is, a key concern, as some memory accesses are still absolute (as opposed to relative).

It wasn’t until much later that key concerns became evident, among them being ABI compatibility and HAL extensibility.

In addition, the kernel would be loading its own drivers later in the boot process, so sharing a minimal HAL would be redundant.

As the core kernel logic should in principle be platform-agnostic, it follows that the kernel executable should be self-sufficient whenever possible. Dynamically linking a HAL using platform-specific contracts would go against both principles.

Consequence