Releases: derfsss/VirtualSCSIDevice
Release list
virtioscsi.device 1.12 (beta)
Beta release of virtioscsi.device — VirtIO SCSI block device driver for AmigaOS 4.1 Final Edition under QEMU.
⚠️ Beta — actively under development. Validated on QEMU Pegasos2, AmigaOne, and SAM460ex (50/50 automated checks). Use at your own risk.
Highlights of 1.12
- Full code-review pass: >32 MiB transfer fix (READ/WRITE 16), modern-endian residual/used_event handling, cross-task race fixes, held-request hardening
- Single
-device virtio-scsi-pci,id=scsi0works on all supported QEMU machines — the driver auto-detects the best transport at boot - New AmigaOS Installation Utility wizard (
install.py— double-click its icon): copies the driver toSYS:Kickstart/and updates Kicklayout automatically (with backup)
Install: extract VirtualSCSIDevice.lha, open the drawer, double-click install.py. Full details in the bundled README_os4depot.txt.
See CHANGELOG.md for the complete changelog.
virtioscsi.device v1.10
Changes since v1.9
SFS 1.290 compatibility
- Explicit 68k jump table (
CLT_Vector68K) for BeginIO/AbortIO Residentstruct in writable.data(matches shipping OS4 IDE drivers)DriveGeometryzeroed before filling (dg_Reservedchecked by SFS)dg_BufMemType = MEMF_PUBLIC|MEMF_LOCALfor BPTR-safe DOSEnvVecTD_GETDRIVETYPEreturnsDRIVE3_5(matching a1ide.device)dev_Unitproperly initialised withNT_MSGPORT+UNITF_ACTIVElib_Versionpinned to 53 (SFS 1.290 rejects low version numbers)
RDB geometry caching
TD_GETGEOMETRYreads the RDB header and first PartitionBlock to report CHS that matches the on-disk partition layout
Build
- Makefile dual-build: separate release (stripped) and debug (DPRINTF + symbols) targets
- Both binaries included in the LHA
Stress suite
- Updated to accept
--port,--monitor,--volumeCLI args - Hot-plug tests skip gracefully when QEMU occupies all targets
Test results
| Machine | Checks | Soak drift |
|---|---|---|
| AmigaOne | 14/14 | -6.3 MB (no leak) |
| Pegasos2 | 14/14 | -5.4 MB (no leak) |
| SAM460ex | 14/14 | -11.6 MB (no leak) |
v1.9 - Modern MMIO on AmigaOne, hot-plug events
virtioscsi.device v1.9 (15 April 2026)
Validated 12/12 against the automated stress suite on all three QEMU PowerPC machines (AmigaOne, Pegasos2, SAM460ex). SCSI memory drift stays below the IDE baseline on every machine - no per-I/O leak signal.
What's new
- Modern VirtIO MMIO on AmigaOne. Runtime workaround in
pci_discovery.cfor a 64-bit BAR firmware bug that previously left BAR4 outside Articia's PCI memory window. AmigaOne now uses the ~10-20x faster modern transport, matching Pegasos2 and SAM460ex. - VIRTIO_RING_F_INDIRECT_DESC accepted on the modern path. Scatter-gather chains consume one vring descriptor regardless of SG count. Fixes latent byte-swap bugs in the indirect-table writes.
- HOTPLUG / CHANGE event queue. VQ1 is active when the device negotiates the feature. A dedicated consumer task drains events and handles
TRANSPORT_RESET(rescan / removed),PARAM_CHANGE(media or size change), andASYNC_NOTIFY. - CD / DVD media-change end-to-end.
TD_CHANGENUMandTD_CHANGESTATEreport real values, and any heldTD_ADDCHANGEINTis woken on eject/insert via the AmigaOS held-request convention. - Full mounter.library integration. Hot-added disks (
device_add scsi-hdin QEMU monitor) appear on the Workbench without a reboot.device_deldenounces them.mounter.libraryis opened lazily on first hot-add so the old boot-time MediaToolbox crash can't come back. - Shell-run diagnostic. Running the device directly from shell now prints an error via
IExec->DebugPrintFand returnsRETURN_FAILinstead of 0.
LHA contents
| File | Purpose |
|---|---|
virtioscsi.device |
Stripped release binary (goes in Kickstart/) |
virtioscsi.device.debug |
Unstripped same-source build, for decoding grim-reaper reports |
Autoinstall |
Installer script |
README_os4depot.txt |
Full documentation, install steps, changelog |
Install
Follow the Autoinstall script, then add MODULE Kickstart/virtioscsi.device before the diskboot.config / diskboot.kmod lines in your Kicklayout, and add virtioscsi.device 8 3 to diskboot.config.
AmiUpdate
Both binaries carry the standard $VER: virtioscsi.device 1.9 (15.04.2026) string; AmiUpdate will detect the new version from the existing LHA URL.
v53.8 — Boot Drive Support
What's New in v53.8
Boot Drive Support
VirtIO SCSI disks can now be used as boot drives. Resident priority changed to 0 (matching other AmigaOS disk device drivers). Major version bumped to 53 (AmigaOS 4.1 FE SDK convention). Tested as boot drive on AmigaOne, Pegasos2, and SAM460ex.
Installation
- Add
virtioscsi.devicetoKickstart/folder - Add
MODULE Kickstart/virtioscsi.deviceto Kicklayout beforediskboot.configanddiskboot.kmod - Add
virtioscsi.device 8 3todiskboot.config
QEMU Setup (all machines)
-device virtio-scsi-pci,id=scsi0 \
-drive file=image_file.img,if=none,id=vd0,format=raw \
-device scsi-hd,drive=vd0,bus=scsi0.0,channel=0,scsi-id=0,lun=0
Build
Dynamic build date/time stamps — each build embeds the actual build timestamp.
Previous Release (v1.8)
See v1.8 release for unified platform support, performance optimizations, and debug instrumentation changes.
🤖 Generated with Claude Code
v1.8 — Unified Platform Support & Performance
What's New
Unified QEMU Platform Support
Single -device virtio-scsi-pci works on all three QEMU PowerPC machines — AmigaOne, Pegasos2, and SAM460ex. The driver auto-detects modern vs legacy VirtIO transport at boot via an MMIO probe. No platform-specific QEMU configuration required.
Performance Optimizations
- Cacheable bounce buffers:
CopyMem+CacheClearEreplaces non-cacheable volatile copy (~10-20x faster for ≤64KB I/O) - O(1) cross-unit cookie routing: unit number encoded in
req_cmd->id, eliminates O(128) search - ISR occupancy bitmask: skips units with no inflight I/O
Debug Instrumentation
- Error-path DPRINTF added to all command handlers for serial debug output
- Boot version line includes build time
QEMU Setup (all machines)
-device virtio-scsi-pci,id=scsi0 \
-drive file=image_file.img,if=none,id=vd0,format=raw \
-device scsi-hd,drive=vd0,bus=scsi0.0,channel=0,scsi-id=0,lun=0
Installation
Add virtioscsi.device to your BBoot Kickstart zip or SYS:Kickstart/ folder and add MODULE Kickstart/virtioscsi.device to the Kicklayout file.
🤖 Generated with Claude Code
virtioscsi.device v1.5 build 1079
Pegasos2 support via VirtIO 1.0 Modern PCI transport.
- Dual VirtIO transport: Legacy PCI for AmigaOne, Modern VirtIO 1.0 for Pegasos2, auto-detected at boot
- MMIO via stwbrx/lwbrx inline assembly on Pegasos2 MV64361 bridge
- PCI capability chain walk for COMMON/NOTIFY/ISR/DEVICE config regions
- Full VirtIO 1.0 status handshake and three-address queue setup
- LE vring byte-swap wrappers for modern mode
- Bug fixes: PCI Memory Space enable, NULL-safe BAR0, modern queue notify
- Updated installation docs with BBoot and Kickstart instructions
- QEMU setup for both amigaone and pegasos2 machines
Installation: Add virtioscsi.device to your Kickstart folder and update Kicklayout.
See README for full instructions.
v1.4 build 1070
What's New in v1.4
Build 1067 — READ CAPACITY (16) for disks >= 2TB
READ CAPACITY (10) returns a 32-bit last LBA capped at 0xFFFFFFFF (~2TB). ensure_geometry_cached() now falls back automatically to READ CAPACITY (16) when it detects the sentinel, obtaining the true 64-bit last LBA. total_blocks is now uint64 throughout. dg_TotalSectors in TD_GETGEOMETRY is clamped to 0xFFFFFFFF for compatibility with the 32-bit DriveGeometry field.
Build 1068 — Accurate SCSI Error -> io_Error Mapping
All non-GOOD SCSI completions previously mapped to the generic HFERR_BadStatus (45), losing sense-key information that filesystems use for error recovery. A new map_scsi_error() helper decodes the fixed-format sense key and returns the appropriate AmigaOS error code: TDERR_WriteProt, TDERR_DiskChanged, TDERR_BadSecHdr, TDERR_BadDriveType, IOERR_NOCMD, etc. Applied at all four completion sites in Harvest and DoIO.
Build 1069 — SCSI INQUIRY VPD Pages
Standard INQUIRY (EVPD=0) still passes through to VirtIO unchanged. For EVPD=1 (Vital Product Data), three pages are now synthesised locally:
- Page 0x00 — Supported VPD Pages list (0x00, 0x80, 0x83)
- Page 0x80 — Unit Serial Number: VIRTIOSCSI-T
- Page 0x83 — Device Identification: T10 vendor designation
Unsupported EVPD page codes return CHECK CONDITION ILLEGAL REQUEST / INVALID FIELD IN CDB (ASC 0x24).
Build 1070 — MAX_INFLIGHT Increased to 16
MAX_INFLIGHT increased from 8 to 16, doubling concurrent block I/O requests each unit task can sustain. Memory overhead is approximately 34 KB additional MEMF_SHARED per unit (~68 KB total for two units). No code changes required beyond the single #define.
Full changelog: https://github.com/derfsss/VirtualSCSIDevice/blob/master/HISTORY.md
v1.3 build 1042
virtioscsi.device v1.3 build 1042
AmigaOS 4.1 FE VirtIO SCSI device driver for QEMU/KVM virtual machines.
Changes in this release
- Interrupt-driven I/O via PCI INTx (replaces polling)
- Pre-allocated per-unit MEMF_SHARED DMA buffers (eliminates per-request alloc overhead)
- Fixed VIRTIO_F_EVENT_IDX kick-suppression bug that caused all I/O after the first request to timeout
- Replaced deprecated CachePreDMA/CachePostDMA with StartDMA/EndDMA/GetDMAList
- GCC 11 fix: -fno-tree-loop-distribute-patterns prevents memset substitution in -nostartfiles builds
Hardware requirements
- AmigaOS 4.1 Final Edition (PowerPC)
- QEMU/KVM with
-device virtio-scsi-pci(legacy PCI, VendorID 0x1AF4 DeviceID 0x1004)
Installation
Copy virtioscsi.device to DEVS: on your AmigaOS system.