Files
LithosAnanke/boards/milkv
Claude 3bd81097e1 chore(license): an SPDX header on every source file that had none (LicenseRef-Starship-1.0) [skip ci]
The header scan (Captain Bob, 2026-11-10): 788 source files -- 351 with the
SL-1.0 header, 12 with the old name (docs/working/experiments, kept by
ruling), 31 under someone else's licence (tools/kconfig, Linux's, GPL-2.0:
kept), and 394 with none. Ruled: the SPDX form; capsules (.4th, .f18) and
proofs (.thy) left for a ruling of their own (mkcapsule's 64x16 block format,
content-addressed capsules).

253 files now begin
    SPDX-License-Identifier: LicenseRef-Starship-1.0
    Copyright (c) 2023-2026 Robert A. James
as a /* */ block (C, headers, assembly, linker scripts) or # lines (scripts,
Makefiles, Kconfig; below a shebang or a coding line); tools/mkcapsule.c,
which had the copyright line, gets the SPDX line only.

Not touched: docs/working/ (archive and old campaign material, as the
ruling kept the experiments); v4/system/post_cases.c (generated by
v4/tools/mkpost.py, "do not edit" -- the generator has the header).

Comments only: the kernel builds on amd64, aarch64, riscv64; make -C v4
test-32: 39 programs, 0 failures; every changed script parses.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GE3SDvQn5EoxdGufk84zz2
2026-11-10 04:12:49 +00:00
..
…

Milk-V Mars boot media

make boot_image TARGET=MILKV builds build/boards/milkv/lithos-milkv.img: a GPT disk with one FAT32 EFI System Partition. Write it to an SD card with dd. The partition holds:

  • EFI/BOOT/BOOTRISCV64.EFI: the riscv64 monolithic loader, the same one QEMU boots.
  • startup.nsh: for a UEFI shell, if one is used.
  • starforth.cfg: only present when KERNEL_ARGS="..." is given.

The board's own SPI-flash U-Boot, with OpenSBI underneath, finds the loader through its standard bootefi scan of the removable-media path. U-Boot passes its devicetree to the loader through the EFI configuration table.

Status: booted in QEMU through the same chain the board uses: OpenSBI, then U-Boot qemu-riscv64_smode, then bootefi from this image's ESP, then the loader and the kernel. POST passed, Stadium conservation was exact (resident 43691 + reservoir 21845 = 65536 = Q48_ONE), and Hestia and Artemis came up. Not yet booted on the Mars itself. The JH7110 peripherals (framebuffer, RNG) have only been checked by compiling.

To repeat the QEMU boot (qemu-system-riscv64 is in Ubuntu 26.04's qemu-system-riscv package; OpenSBI and U-Boot come from opensbi and u-boot-qemu). Use a copy, because the kernel writes to its disk:

cp build/boards/milkv/lithos-milkv.img /tmp/mv.img
qemu-system-riscv64 -machine virt -cpu rv64 -m 2048 -nographic \
    -bios /usr/lib/riscv64-linux-gnu/opensbi/generic/fw_dynamic.bin \
    -kernel /usr/lib/u-boot/qemu-riscv64_smode/u-boot.bin \
    -drive if=none,format=raw,file=/tmp/mv.img,id=d0 -device virtio-blk-device,drive=d0