Skip to content

scadm shouldn't hardcode legacy virtio 9p device ID for SoftNPU #1214

Description

@sion42x

scadm finds propolis SoftNPU 9p devices by matching device ID 0x1009 with a legacy subsystem ID. Changing subsystem ID to single out SoftNPU from other 9p devices breaks scadm's lookup and vio9p binding.

Moving the device to transitional or modern virtio with device ID 0x1049 will also break lookup. Both of these things came up as blockers in oxidecomputer/omicron#11237.

scadm should discover a device without depending on PCI identity. Similar to how the aforementioned PR approaches it, we can walk devinfo for virtio 9p nodes that accept both 0x1009 and 0x1049, and identify SoftNPU by its version string (9P2000.P4) with a Tversion exchange.

There may be better ways of doing it as well. As @iximeow mentioned to me in passing, there's nothing inherently wrong with it being a Legacy ID. But that plus hardcoding and intolerance of subsystem ID changes makes it a blocker.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions