aienux
Aienux, the AienOS kernel: boot, scheduling, IPC and capability boundaries. Pre-alpha; host, emulator and physical evidence are labelled separately.
Brought by drakestapleton
aienux / native / disk / omega_nvme_main.om
| 1 | note SPDX-License-Identifier: Apache-2.0 |
| 2 | note Manifest bytes: serial[20], firmware[8], NSID u32, extent start/count u64, |
| 3 | note request LBA u64, count u32, repetitions u32, approved u32, reserved u32. |
| 4 | note All integers little endian. Approval here is fixture binding, not hardware authority. |
| 5 | fn main to int |
| 6 | getmanifest |
| 7 | if ne man32 68 0 |
| 8 | ret 20 |
| 9 | end |
| 10 | r = initialize |
| 11 | if ne r 0 |
| 12 | report r |
| 13 | ret r |
| 14 | end |
| 15 | n = man32 60 |
| 16 | if or eq n 0 gt n 64 |
| 17 | ret 33 |
| 18 | end |
| 19 | for i ulong n |
| 20 | r = readblocks man64 48 man32 56 |
| 21 | if ne r 0 |
| 22 | report r |
| 23 | ret r |
| 24 | end |
| 25 | end |
| 26 | report 0 |
| 27 | ret 0 |
| 28 | end |