Skip to content

Commit 94b0435

Browse files
mrathor99liuw
authored andcommitted
Drivers: hv: Add CONFIG_HYPERV_VMBUS option
At present VMBus driver is hinged off of CONFIG_HYPERV which entails lot of builtin code and encompasses too much. It's not always clear what depends on builtin hv code and what depends on VMBus. Setting CONFIG_HYPERV as a module and fudging the Makefile to switch to builtin adds even more confusion. VMBus is an independent module and should have its own config option. Also, there are scenarios like baremetal dom0/root where support is built in with CONFIG_HYPERV but without VMBus. Lastly, there are more features coming down that use CONFIG_HYPERV and add more dependencies on it. So, create a fine grained HYPERV_VMBUS option and update Kconfigs for dependency on VMBus. Signed-off-by: Mukesh Rathor <mrathor@linux.microsoft.com> Acked-by: Bjorn Helgaas <bhelgaas@google.com> # drivers/pci Signed-off-by: Wei Liu <wei.liu@kernel.org>
1 parent a3a4d6c commit 94b0435

12 files changed

Lines changed: 25 additions & 16 deletions

File tree

drivers/gpu/drm/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ source "drivers/gpu/drm/imagination/Kconfig"
398398

399399
config DRM_HYPERV
400400
tristate "DRM Support for Hyper-V synthetic video device"
401-
depends on DRM && PCI && HYPERV
401+
depends on DRM && PCI && HYPERV_VMBUS
402402
select DRM_CLIENT_SELECTION
403403
select DRM_KMS_HELPER
404404
select DRM_GEM_SHMEM_HELPER

drivers/hid/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1162,7 +1162,7 @@ config GREENASIA_FF
11621162

11631163
config HID_HYPERV_MOUSE
11641164
tristate "Microsoft Hyper-V mouse driver"
1165-
depends on HYPERV
1165+
depends on HYPERV_VMBUS
11661166
help
11671167
Select this option to enable the Hyper-V mouse driver.
11681168

drivers/hv/Kconfig

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,18 +45,25 @@ config HYPERV_TIMER
4545

4646
config HYPERV_UTILS
4747
tristate "Microsoft Hyper-V Utilities driver"
48-
depends on HYPERV && CONNECTOR && NLS
48+
depends on HYPERV_VMBUS && CONNECTOR && NLS
4949
depends on PTP_1588_CLOCK_OPTIONAL
5050
help
5151
Select this option to enable the Hyper-V Utilities.
5252

5353
config HYPERV_BALLOON
5454
tristate "Microsoft Hyper-V Balloon driver"
55-
depends on HYPERV
55+
depends on HYPERV_VMBUS
5656
select PAGE_REPORTING
5757
help
5858
Select this option to enable Hyper-V Balloon driver.
5959

60+
config HYPERV_VMBUS
61+
tristate "Microsoft Hyper-V VMBus driver"
62+
depends on HYPERV
63+
default HYPERV
64+
help
65+
Select this option to enable Hyper-V Vmbus driver.
66+
6067
config MSHV_ROOT
6168
tristate "Microsoft Hyper-V root partition support"
6269
depends on HYPERV && (X86_64 || ARM64)

drivers/hv/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# SPDX-License-Identifier: GPL-2.0
2-
obj-$(CONFIG_HYPERV) += hv_vmbus.o
2+
obj-$(CONFIG_HYPERV_VMBUS) += hv_vmbus.o
33
obj-$(CONFIG_HYPERV_UTILS) += hv_utils.o
44
obj-$(CONFIG_HYPERV_BALLOON) += hv_balloon.o
55
obj-$(CONFIG_MSHV_ROOT) += mshv_root.o

drivers/input/serio/Kconfig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -276,8 +276,8 @@ config SERIO_OLPC_APSP
276276

277277
config HYPERV_KEYBOARD
278278
tristate "Microsoft Synthetic Keyboard driver"
279-
depends on HYPERV
280-
default HYPERV
279+
depends on HYPERV_VMBUS
280+
default HYPERV_VMBUS
281281
help
282282
Select this option to enable the Hyper-V Keyboard driver.
283283

drivers/net/hyperv/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: GPL-2.0-only
22
config HYPERV_NET
33
tristate "Microsoft Hyper-V virtual network driver"
4-
depends on HYPERV
4+
depends on HYPERV_VMBUS
55
select UCS2_STRING
66
select NLS
77
help

drivers/pci/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ config PCI_LABEL
221221

222222
config PCI_HYPERV
223223
tristate "Hyper-V PCI Frontend"
224-
depends on ((X86 && X86_64) || ARM64) && HYPERV && PCI_MSI && SYSFS
224+
depends on ((X86 && X86_64) || ARM64) && HYPERV_VMBUS && PCI_MSI && SYSFS
225225
select PCI_HYPERV_INTERFACE
226226
select IRQ_MSI_LIB
227227
help

drivers/scsi/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -589,7 +589,7 @@ config XEN_SCSI_FRONTEND
589589

590590
config HYPERV_STORAGE
591591
tristate "Microsoft Hyper-V virtual storage driver"
592-
depends on SCSI && HYPERV
592+
depends on SCSI && HYPERV_VMBUS
593593
depends on m || SCSI_FC_ATTRS != m
594594
default HYPERV
595595
help

drivers/uio/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ config UIO_MF624
140140

141141
config UIO_HV_GENERIC
142142
tristate "Generic driver for Hyper-V VMBus"
143-
depends on HYPERV
143+
depends on HYPERV_VMBUS
144144
help
145145
Generic driver that you can bind, dynamically, to any
146146
Hyper-V VMBus device. It is useful to provide direct access

drivers/video/fbdev/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1774,7 +1774,7 @@ config FB_BROADSHEET
17741774

17751775
config FB_HYPERV
17761776
tristate "Microsoft Hyper-V Synthetic Video support"
1777-
depends on FB && HYPERV
1777+
depends on FB && HYPERV_VMBUS
17781778
select DMA_CMA if HAVE_DMA_CONTIGUOUS && CMA
17791779
select FB_IOMEM_HELPERS_DEFERRED
17801780
help

0 commit comments

Comments
 (0)