From addd264880fd4e598695dd7f4c3a845941adc103 Mon Sep 17 00:00:00 2001 From: Daniel Samson <12231216+daniel-samson@users.noreply.github.com> Date: Sun, 9 Aug 2026 22:42:56 +0100 Subject: [PATCH] =?UTF-8?q?docs:=20storage=20plan=20=E2=80=94=20volumes=20?= =?UTF-8?q?named=20by=20identity;=20exFAT=20implemented=20in=20full?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two decisions settled: (1) a volume's mount name is its own content identity (FAT label / GPT name, else identity-hex), never a port name (/volumes/usb) or role name (/volumes/boot); volumes.csv stays as an explicit override. This makes S1 precede S2 and folds the /volumes/usb fixture+regex migration into S2. (2) exFAT is a complete implementation — full read+write, directories, rename, and the on-disk up-case table — not a read-first/ASCII-only subset; the only limit is the vfs u32 offset surface (a 4 GiB cap on all filesystems), flagged as a separate vfs change. --- docs/storage-stack-plan.md | 125 ++++++++++++++++++++----------------- 1 file changed, 68 insertions(+), 57 deletions(-) diff --git a/docs/storage-stack-plan.md b/docs/storage-stack-plan.md index 6eabcff..9851683 100644 --- a/docs/storage-stack-plan.md +++ b/docs/storage-stack-plan.md @@ -26,24 +26,22 @@ bench-pending. ## The five phases and how they depend ``` -S1 identity ladder ─────┐ - ├──► S2 mount map ──► S3 multi-volume ──► S4 exFAT -(S2 keys on rung-4, so │ (needs S2+S3) - is independent of S1) │ - └──► S5 removal robustness (independent; single-volume) +S1 identity ladder ──► S2 mount map ──► S3 multi-volume ──► S4 exFAT + (needs S2+S3) +S5 removal robustness ── independent; single-volume ── may land any time ``` -- **S1** grows the identity read off the medium (GPT GUID, FAT serial+label). +- **S1** grows the identity read off the medium (GPT GUID, FAT serial+label). It + comes FIRST because a volume's mount name is now its identity (below), and the + friendly form of that name is the FAT label / GPT name S1 parses. - **S2** moves the last policy out of hardcode into `volumes.csv` + - `filesystems.csv`, keyed on today's rung-4 identity — so it does **not** wait - on S1; S1 only enriches the identity values the same map consumes. + `filesystems.csv`, and names each volume by its identity — no port-name. - **S3** generalizes to N volumes across N devices. -- **S4** adds exFAT — the second engine that proves the V1 harness extraction. - Needs S2 (to route by signature) and S3 (to run a second volume in the VM). +- **S4** adds exFAT — a COMPLETE second engine that proves the V1 harness + extraction. Needs S2 (to route by signature) and S3 (to run a second volume). - **S5** closes the removal-lifecycle gaps. Independent of the rest; single-volume. -Recommended build order is S1 → S2 → S3 → S4 → S5. S5 may be pulled earlier if -removal robustness matters more than multi-volume; S1 and S2 may swap. +Recommended build order is S1 → S2 → S3 → S4 → S5. S5 may be pulled earlier. --- @@ -101,12 +99,18 @@ never drift onto magic constants). **Goal.** Move the last two pieces of storage policy out of hardcode into configuration read by the volume manager. `filesystems.csv` (content signature → filesystem binary) so the VM picks the binary from the probed signature; -`volumes.csv` (identity → mount prefix(es), danos's fstab) so the VM decides -mount placement, with a `/volumes/vol-` anonymous fallback. Parsed with -`library/csv` exactly as `device-registry` parses `devices.csv`. The VM hands the -binary + volume-id + mount specs to fat at spawn (the argv channel V3b already -uses for the volume id); fat retires `fat_mounts` and reads mounts from -argv[2..]. Keyed on rung-4 identity, so independent of S1 and forward-compatible. +`volumes.csv` (identity → mount prefix, danos's fstab) as the explicit override +for a volume the user wants at a fixed path. **The default mount name is the +volume's own identity, never a port or role name**: `/volumes/