diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2019-01-23 14:56:07 +0800 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2019-03-07 21:45:53 +0100 |
commit | 03b348bdcbd1eda4ce097b2b84527dec774d80c4 (patch) | |
tree | 7baf9ac83aae85696d5a4345f93fbb9ab68fb141 | |
parent | a02c0edb35662de38d400f42b68845540669ca3d (diff) |
scsi: express dependencies with Kconfig
This automatically removes the SCSI subsystem from the
binary altogether if no controllers are selected.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Yang Zhong <yang.zhong@intel.com>
Message-Id: <20190123065618.3520-34-yang.zhong@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r-- | default-configs/arm-softmmu.mak | 1 | ||||
-rw-r--r-- | default-configs/hppa-softmmu.mak | 1 | ||||
-rw-r--r-- | default-configs/mips-softmmu-common.mak | 1 | ||||
-rw-r--r-- | default-configs/sparc-softmmu.mak | 1 | ||||
-rw-r--r-- | default-configs/virtio.mak | 1 | ||||
-rw-r--r-- | hw/scsi/Kconfig | 10 | ||||
-rw-r--r-- | hw/scsi/Makefile.objs | 2 | ||||
-rw-r--r-- | hw/usb/Kconfig | 2 |
8 files changed, 12 insertions, 7 deletions
diff --git a/default-configs/arm-softmmu.mak b/default-configs/arm-softmmu.mak index 0d2aa65266..917b18dd48 100644 --- a/default-configs/arm-softmmu.mak +++ b/default-configs/arm-softmmu.mak @@ -164,5 +164,4 @@ CONFIG_HIGHBANK=y CONFIG_MUSICPAL=y # for realview and versatilepb -CONFIG_SCSI=y CONFIG_LSI_SCSI_PCI=y diff --git a/default-configs/hppa-softmmu.mak b/default-configs/hppa-softmmu.mak index 5089a94866..b7f2b43c24 100644 --- a/default-configs/hppa-softmmu.mak +++ b/default-configs/hppa-softmmu.mak @@ -7,7 +7,6 @@ CONFIG_I8259=y CONFIG_E1000_PCI=y CONFIG_IDE_CMD646=y # CONFIG_IDE_MMIO=y -CONFIG_SCSI=y CONFIG_LSI_SCSI_PCI=y CONFIG_VIRTIO_VGA=y CONFIG_MC146818RTC=y diff --git a/default-configs/mips-softmmu-common.mak b/default-configs/mips-softmmu-common.mak index 90a2412e26..a7a8d4eeb1 100644 --- a/default-configs/mips-softmmu-common.mak +++ b/default-configs/mips-softmmu-common.mak @@ -4,7 +4,6 @@ CONFIG_ISA_BUS=y CONFIG_PCI=y CONFIG_PCI_DEVICES=y CONFIG_ESP=y -CONFIG_SCSI=y CONFIG_VGA_ISA=y CONFIG_VGA_ISA_MM=y CONFIG_VGA_CIRRUS=y diff --git a/default-configs/sparc-softmmu.mak b/default-configs/sparc-softmmu.mak index 59a4a3d693..805c4007ed 100644 --- a/default-configs/sparc-softmmu.mak +++ b/default-configs/sparc-softmmu.mak @@ -2,7 +2,6 @@ CONFIG_ISA_BUS=y CONFIG_ECC=y -CONFIG_SCSI=y CONFIG_ESP=y CONFIG_ESCC=y CONFIG_M48T59=y diff --git a/default-configs/virtio.mak b/default-configs/virtio.mak index 51599ed276..82d07262f8 100644 --- a/default-configs/virtio.mak +++ b/default-configs/virtio.mak @@ -7,6 +7,5 @@ CONFIG_VIRTIO_GPU=y CONFIG_VIRTIO_INPUT=y CONFIG_VIRTIO_NET=y CONFIG_VIRTIO_RNG=y -CONFIG_SCSI=y CONFIG_VIRTIO_SCSI=y CONFIG_VIRTIO_SERIAL=y diff --git a/hw/scsi/Kconfig b/hw/scsi/Kconfig index a7d25d3261..b9cf269764 100644 --- a/hw/scsi/Kconfig +++ b/hw/scsi/Kconfig @@ -5,24 +5,29 @@ config LSI_SCSI_PCI bool default y if PCI_DEVICES depends on PCI + select SCSI config MPTSAS_SCSI_PCI bool default y if PCI_DEVICES depends on PCI + select SCSI config MEGASAS_SCSI_PCI bool default y if PCI_DEVICES depends on PCI + select SCSI config VMW_PVSCSI_SCSI_PCI bool default y if PCI_DEVICES depends on PCI + select SCSI config ESP bool + select SCSI config ESP_PCI bool @@ -34,11 +39,14 @@ config SPAPR_VSCSI bool default y depends on PSERIES + select SCSI config VIRTIO_SCSI bool + select SCSI config VHOST_USER_SCSI bool - default y + # Only PCI devices are provided for now + default y if VIRTIO_PCI depends on VHOST_USER && LINUX diff --git a/hw/scsi/Makefile.objs b/hw/scsi/Makefile.objs index 45167baeaf..54b36ed8b1 100644 --- a/hw/scsi/Makefile.objs +++ b/hw/scsi/Makefile.objs @@ -6,7 +6,7 @@ common-obj-$(CONFIG_MEGASAS_SCSI_PCI) += megasas.o common-obj-$(CONFIG_VMW_PVSCSI_SCSI_PCI) += vmw_pvscsi.o common-obj-$(CONFIG_ESP) += esp.o common-obj-$(CONFIG_ESP_PCI) += esp-pci.o -obj-$(CONFIG_PSERIES) += spapr_vscsi.o +obj-$(CONFIG_SPAPR_VSCSI) += spapr_vscsi.o ifeq ($(CONFIG_VIRTIO_SCSI),y) obj-y += virtio-scsi.o virtio-scsi-dataplane.o diff --git a/hw/usb/Kconfig b/hw/usb/Kconfig index e20670aa5d..a1b7acb12a 100644 --- a/hw/usb/Kconfig +++ b/hw/usb/Kconfig @@ -52,11 +52,13 @@ config USB_STORAGE_BOT bool default y depends on USB + select SCSI config USB_STORAGE_UAS bool default y depends on USB + select SCSI config USB_AUDIO bool |