blkvalidate

command
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2026 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Overview

Headless go-virtio blk validate harness: boots tamago/amd64 under QEMU, drives a real virtio-blk-pci device through the go-virtio/blk driver, and performs an entirely in-guest write/read-back equality proof over a scratch raw disk. No host-side observation is needed — the guest writes a deterministic, LBA-stamped pattern to several sectors (including a non-zero LBA and a multi-block run), Flushes, reads them back, asserts byte-equality itself, and reports BLK-VALIDATE: ... PASS/FAIL plus a checksum over the serial console. run-blk.sh parses the verdict and exits non-zero on FAIL.

This mirrors the gpu harness: a *real* virtio-blk-pci device (not the fake transport the unit tests use) is what exercises the descriptor-chain build, the device-written status byte, capacity/devcfg reads, and DMA alignment on actual QEMU emulation.

The 8 MiB scratch image (run-blk.sh creates it) is 8*1024*1024/512 = 16384 sectors; the harness sanity-checks the reported capacity against that.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL