On 10/21/25 10:08 AM, Thomas Huth wrote:
On 20/10/2025 18.20, [email protected] wrote:
From: Jared Rossi <[email protected]>

Search for a corresponding S390PCIBusDevice and build an IPLB if a device has
been indexed for boot but does not identify as a CCW device,

PCI devices are not yet included in boot probing (they must have a boot index).
Per-device loadparm is not yet supported for PCI devices.

Could you add it? Something similar to what has been done in scsi_property_add_specifics() in hw/scsi/scsi-disk.c for the SCSI disks?

Sure. It will be included in the next version.

...
@@ -346,7 +349,7 @@ static void s390_ipl_set_boot_menu(S390IPLState *ipl)   static CcwDevice *s390_get_ccw_device(DeviceState *dev_st, int *devtype)
  {
      CcwDevice *ccw_dev = NULL;
-    int tmp_dt = CCW_DEVTYPE_NONE;
+    int tmp_dt = S390_DEVTYPE_NONE;
        if (dev_st) {
          VirtIONet *virtio_net_dev = (VirtIONet *)
@@ -393,6 +396,31 @@ static CcwDevice *s390_get_ccw_device(DeviceState *dev_st, int *devtype)
      return ccw_dev;
  }
  +#define PCI_DEVTYPE_VIRTIO       0x05

Is this for virtio-block only ? If so, I'd maybe rather name it PCI_DEVTYPE_VIRTIO_BLK or so. Or will this be used for virtio-scsi-pci etc., too?
I named it this way because it is the PCI equivalent of CCW_DEVTYPE_VIRTIO used in the above s390_get_ccw_device() function.  Although The CCW function also has a different designation for virtio-net devices I don't think that will be useful for PCI (due to the change with the netboot binary).  So, this device type could be used for both virtio-blk-pci and virtio-net-pci.  Virtio-scsi-pci would need a different designation though (much like how there exists CCW_DEVTYPE_SCSI).

Regards,
Jared Rossi



Reply via email to