kconfig: Add PCIe devices to s390x machines
authorCédric Le Goater <clg@redhat.com>
Wed, 12 Jul 2023 08:01:46 +0000 (10:01 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 14 Jul 2023 09:10:57 +0000 (11:10 +0200)
It is useful to extend the number of available PCIe devices to KVM guests
for passthrough scenarios and also to expose these models to a different
(big endian) architecture. Introduce a new config PCIE_DEVICES to select
models, Intel Ethernet adapters and one USB controller. These devices all
support MSI-X which is a requirement on s390x as legacy INTx are not
supported.

Cc: Matthew Rosato <mjrosato@linux.ibm.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Thomas Huth <thuth@redhat.com>
Signed-off-by: Cédric Le Goater <clg@redhat.com>
Message-ID: <20230712080146.839113-1-clg@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
configs/devices/s390x-softmmu/default.mak
hw/net/Kconfig
hw/pci/Kconfig
hw/s390x/Kconfig
hw/usb/Kconfig

index f2287a133f366f64ecdf7a25f24daab725f533cf..6d87bc8b4b05c3580825a596b47a7b04b2960c6b 100644 (file)
@@ -7,6 +7,7 @@
 #CONFIG_VFIO_CCW=n
 #CONFIG_VIRTIO_PCI=n
 #CONFIG_WDT_DIAG288=n
+#CONFIG_PCIE_DEVICES=n
 
 # Boards:
 #
index 98e00be4f9379c5168ebfc1f71a28a1ddc46af9c..7fcc0d7faa2977655e84a2a83198c76db661bfaa 100644 (file)
@@ -41,12 +41,12 @@ config E1000_PCI
 
 config E1000E_PCI_EXPRESS
     bool
-    default y if PCI_DEVICES
+    default y if PCI_DEVICES || PCIE_DEVICES
     depends on PCI_EXPRESS && MSI_NONBROKEN
 
 config IGB_PCI_EXPRESS
     bool
-    default y if PCI_DEVICES
+    default y if PCI_DEVICES || PCIE_DEVICES
     depends on PCI_EXPRESS && MSI_NONBROKEN
 
 config RTL8139_PCI
index 77f8b005ffb10c5d49b7433146985a559c198b8b..fe70902cd821a3fd2c0199a28f9a4eae55cc39d4 100644 (file)
@@ -8,6 +8,9 @@ config PCI_EXPRESS
 config PCI_DEVICES
     bool
 
+config PCIE_DEVICES
+    bool
+
 config MSI_NONBROKEN
     # selected by interrupt controllers that do not support MSI,
     # or support it and have a good implementation. See commit
index 5e7d8a2bae8b488b6aa1d93747df6774278de1b4..e8d4d68ece0bdccf1cd1f37a2e8a648625879253 100644 (file)
@@ -5,7 +5,8 @@ config S390_CCW_VIRTIO
     imply VFIO_AP
     imply VFIO_CCW
     imply WDT_DIAG288
-    select PCI
+    imply PCIE_DEVICES
+    select PCI_EXPRESS
     select S390_FLIC
     select SCLPCONSOLE
     select VIRTIO_CCW
index 0ec6def4b8b89f20a40b708fcdf4a4a6094eceb1..0f486764ed69ec24a0c7b92aebe7594772e97b8b 100644 (file)
@@ -36,7 +36,7 @@ config USB_XHCI
 
 config USB_XHCI_PCI
     bool
-    default y if PCI_DEVICES
+    default y if PCI_DEVICES || PCIE_DEVICES
     depends on PCI
     select USB_XHCI