Skip to content

Releases: manishklach/openflash-controller-lab

OpenFlash v0.4.0 - Linux Data Path and Recovery

Choose a tag to compare

@manishklach manishklach released this 12 Jul 12:33

OpenFlash v0.4.0 - Linux Data Path and Recovery

OpenFlash v0.4.0 turns the controller lab's negotiated I/O queue into a usable experimental
Linux block path. This is a systems milestone, not a production storage release: it provides
an end-to-end host/controller transport for controlled QEMU experiments, with explicit
failure behavior and reproducible validation.

Highlights

  • Exposes an experimental /dev/openflash0 disk through Linux blk-mq.
  • Negotiates queue 1 through the admin queue and assigns its own MSI-X vector.
  • Maps reads, writes, flushes, and discards to phase-tagged DMA queue commands.
  • Advances the shared host/controller ABI to v0.2 with 16-entry scatter-gather lists.
  • Maps and unmaps every SGL entry safely during completion and teardown.
  • Detects timed-out I/O, freezes new submissions, fails ambiguous requests, resets the
    controller, rebuilds the queue transport, and resumes only after recovery succeeds.
  • Adds a QEMU two-segment SGL read/write round-trip test.

Compatibility

  • Linux driver ABI: OpenFlash v0.2 (0x00000002).
  • QEMU integration target: official QEMU 11.0.2 source, checksum-verified in CI.
  • Linux validation: module build and checkpatch against the configured WSL kernel tree.
  • Python validation: 22 tests plus Ruff linting.

Important limits

  • The QEMU media remains RAM-backed and is not persistent.
  • FUA and durable flush guarantees are not implemented in the Linux driver.
  • There is no command-abort opcode yet; recovery intentionally fails timed-out commands
    rather than replaying work whose media execution is unknown.
  • This release must not be used for valuable data or unverified hardware.

Verification

GitHub Actions builds the pinned QEMU integration and runs its controller QTests, in addition
to the Python test suite. The final validated workflow for this release lineage is
29192430598.

Upgrade notes

The ABI minor version changes from v0.1 to v0.2. Hosts must validate the ABI register and use
the SGL flag only when both driver and controller support v0.2. Direct single-buffer commands
remain valid under v0.2.

OpenFlash v0.3.0 - Queued Controller Bring-up

Choose a tag to compare

@manishklach manishklach released this 11 Jul 18:43

OpenFlash v0.3.0: Queued Controller Bring-up

OpenFlash v0.3.0 is the first packaged public release. It joins the NAND/FTL simulator,
behavioral controller, queue ABI, initial QEMU device, and Linux PCI bring-up path into a
single reproducible systems lab.

Highlights

  • A seeded NAND model measures channel/die parallelism, latency distributions, GC, wear,
    write amplification, ECC correction, retries, and uncorrectable reads.
  • A page-mapped FTL performs deterministic striping, invalidation, victim selection,
    live-page relocation, erase, and reclamation.
  • FIFO and bounded read-priority policies provide repeatable scheduler comparisons.
  • ABI v0.1 defines 64-byte little-endian commands/completions, feature bits, queue BARs,
    phase ownership, status codes, reset, and flush/FUA durability.
  • The reference device and queue engine execute identify/read/write/flush/FUA/discard,
    distinguish volatile and durable state, inject faults, batch interrupts, and test wrap.
  • The initial QEMU source implements BAR0, one DMA queue, one MSI-X vector, reset, and a
    RAM-backed data path.
  • The Linux module validates ABI v0.1, allocates coherent admin rings, registers MSI-X,
    publishes queue addresses, enables the controller, and waits for readiness.

Validation

  • 22 Python unit, durability, queue, and ABI consistency tests passed.
  • Ruff lint passed.
  • Linux sources passed strict checkpatch.pl after style fixes.
  • The GPL driver compiled and linked as openflash.ko against Linux
    6.6.87.2-microsoft-standard-WSL2+ headers.
  • GitHub Actions passed for commit 796ec27.

Reproducible model result

With 10,000 requests, 70% reads, 8 channels, 4 dies/channel, and seed 7, the current model
reported approximately 644.5 MiB/s and 211.4 ms read p99 for FIFO versus 817.6 MiB/s and
112.9 ms read p99 for bounded read-priority. These are simulator outputs for comparing
policies; they are not measurements from NAND silicon.

Compatibility and licensing

  • Python 3.10 or newer is required.
  • ABI version is 0.1; it remains experimental and may evolve before a stable hardware
    contract.
  • Simulator, QEMU source, tools, and documentation are Apache-2.0.
  • The Linux kernel driver subtree is GPL-2.0-only.

Known limitations

  • QEMU source is not yet pinned and compiled against a specific upstream revision.
  • QEMU supports one queue with volatile RAM backing and has no QTests yet.
  • Linux does not yet submit identify, drain completions, or register a block device.
  • FTL metadata is volatile and lacks journal/checkpoint recovery.
  • NAND timing/error parameters need calibration against a real part.

Next milestone

The next release will pin QEMU, add MMIO/DMA QTests, submit identify through the Linux
admin queue, negotiate I/O queues, and expose the first data-verified blk-mq disk.

Upgrade notes

This is the first tagged release, so no migration is required. Existing clones should
pull main, recreate the editable Python install, and rerun tests. Do not load the driver
against arbitrary hardware or use the emulated path for valuable data.