Skip to content

scsi: one configuration and one monitor command for every controller - #313

Merged
techomancer merged 1 commit into
mainfrom
unifyscsi
Oct 24, 2026
Merged

techomancer merged 1 commit into
mainfrom
unifyscsi

Conversation

@techomancer

Copy link
Copy Markdown
Owner

The O2 read its disks from its own o2.disks list and ignored the [scsi.N] tables, so changer lists, scratch volumes, CHD images, CI overlays and the --scsi1/--cdrom4 options never reached it, and the monitor's scsi command did not exist there: it was implemented inside the WD33C93A.

Configuration. Both machines now attach their devices from [scsi.N]. controller names the bus on the O2 as it does on the Indigo2 (0 internal, 1 external); the validator accepts controller 1 on both and refuses a DaynaPort on the O2, whose Ethernet is built in. The key is a slot: N 1-7 is id N on controller 0, N = 16 + id is that id on controller 1, so [scsi.1] and [scsi.17] put a disk at id 1 on each controller; controller = 1 on a low key still works, a slot key contradicted by controller, two tables naming one target, id 0 and controller 2 are refused. Snapshot manifests record disks by slot. o2.disks is deprecated: load_toml folds it into [scsi.N] and says so. The changer-list, CI-overlay-path and scratch-volume logic the Indy loop had inline is now on ScsiDeviceConfig and shared; the Indy loop also honours kind = "cdrom" without cdrom = true. An O2 image that will not open ends the run as on the Indy (an embedder boots without it).

Monitor. src/scsi_monitor.rs implements scsi status, scsi dayna, the changer subcommands, the whole of cow and the DiscChanger operations once, over a controller's target table lent through its ScsiTargets trait. The WD33C93A keeps regs, wdt, defer and debug; the Adaptec 7880 keeps regs (its interrupt status, queues and totals). DiscChanger has one blanket impl over ScsiTargets. On the O2, controller 0 answers to scsi/scsi0/cow and controller 1 to scsi1/cow1; both controllers are registered with the monitor. scsi status lists disks as well as CD-ROMs. The O2 also gains scratch_path and disc_changer, so iris-ci's scratch and cdrom commands and the window's disc change work there.

Docs: HELP.md, FEATURES.md, debug.md, HACKING.md, docs/o2-ip32.md, docs/indigo2-ip22.md, iris.toml, CHANGELOG.md. Tests: slot placement and its refusals, the O2 controller rule, the o2.disks fold.

The O2 read its disks from its own `o2.disks` list and ignored the
`[scsi.N]` tables, so changer lists, scratch volumes, CHD images, CI
overlays and the --scsi1/--cdrom4 options never reached it, and the
monitor's `scsi` command did not exist there: it was implemented inside
the WD33C93A.

Configuration. Both machines now attach their devices from `[scsi.N]`.
`controller` names the bus on the O2 as it does on the Indigo2 (0
internal, 1 external); the validator accepts controller 1 on both and
refuses a DaynaPort on the O2, whose Ethernet is built in. The key is a
slot: N 1-7 is id N on controller 0, N = 16 + id is that id on
controller 1, so `[scsi.1]` and `[scsi.17]` put a disk at id 1 on each
controller; `controller = 1` on a low key still works, a slot key
contradicted by `controller`, two tables naming one target, id 0 and
controller 2 are refused. Snapshot manifests record disks by slot.
`o2.disks` is deprecated: `load_toml` folds it into `[scsi.N]` and says
so. The changer-list, CI-overlay-path and scratch-volume logic the Indy
loop had inline is now on ScsiDeviceConfig and shared; the Indy loop also
honours `kind = "cdrom"` without `cdrom = true`. An O2 image that will
not open ends the run as on the Indy (an embedder boots without it).

Monitor. `src/scsi_monitor.rs` implements `scsi status`, `scsi dayna`,
the changer subcommands, the whole of `cow` and the DiscChanger
operations once, over a controller's target table lent through its
`ScsiTargets` trait. The WD33C93A keeps `regs`, `wdt`, `defer` and
`debug`; the Adaptec 7880 keeps `regs` (its interrupt status, queues and
totals). DiscChanger has one blanket impl over ScsiTargets. On the O2,
controller 0 answers to `scsi`/`scsi0`/`cow` and controller 1 to
`scsi1`/`cow1`; both controllers are registered with the monitor.
`scsi status` lists disks as well as CD-ROMs. The O2 also gains
`scratch_path` and `disc_changer`, so iris-ci's scratch and cdrom
commands and the window's disc change work there.

Docs: HELP.md, FEATURES.md, debug.md, HACKING.md, docs/o2-ip32.md,
docs/indigo2-ip22.md, iris.toml, CHANGELOG.md. Tests: slot placement and
its refusals, the O2 controller rule, the `o2.disks` fold.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@techomancer
techomancer merged commit 66d3b40 into main Oct 24, 2026
7 checks passed
@techomancer
techomancer deleted the unifyscsi branch October 28, 2026 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant