With CONFIG_HYPERV and CONFIG_HYPERV_VMBUS separated, change CONFIG_HYPERV
to bool from tristate. CONFIG_HYPERV now becomes the core Hyper-V
hypervisor support, such as hypercalls, clocks/timers, Confidential
Computing setup, PCI passthru, etc. that doesn't involve VMBus or VMBus
devices.
Signed-off-by: Mukesh Rathor <mrathor@linux.microsoft.com>
---
drivers/Makefile | 2 +-
drivers/hv/Kconfig | 2 +-
drivers/hv/Makefile | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/Makefile b/drivers/Makefile
index b5749cf67044..7ad5744db0b6 100644
--- a/drivers/Makefile
+++ b/drivers/Makefile
@@ -161,7 +161,7 @@ obj-$(CONFIG_SOUNDWIRE) += soundwire/
# Virtualization drivers
obj-$(CONFIG_VIRT_DRIVERS) += virt/
-obj-$(subst m,y,$(CONFIG_HYPERV)) += hv/
+obj-$(CONFIG_HYPERV) += hv/
obj-$(CONFIG_PM_DEVFREQ) += devfreq/
obj-$(CONFIG_EXTCON) += extcon/
diff --git a/drivers/hv/Kconfig b/drivers/hv/Kconfig
index fe29f8dca2b5..7e56c51c5080 100644
--- a/drivers/hv/Kconfig
+++ b/drivers/hv/Kconfig
@@ -3,7 +3,7 @@
menu "Microsoft Hyper-V guest support"
config HYPERV
- tristate "Microsoft Hyper-V client drivers"
+ bool "Microsoft Hyper-V core hypervisor support"
depends on (X86 && X86_LOCAL_APIC && HYPERVISOR_GUEST) \
|| (ARM64 && !CPU_BIG_ENDIAN)
select PARAVIRT
diff --git a/drivers/hv/Makefile b/drivers/hv/Makefile
index 050517756a82..8b04a33e4dd8 100644
--- a/drivers/hv/Makefile
+++ b/drivers/hv/Makefile
@@ -18,7 +18,7 @@ mshv_root-y := mshv_root_main.o mshv_synic.o mshv_eventfd.o mshv_irq.o \
mshv_vtl-y := mshv_vtl_main.o
# Code that must be built-in
-obj-$(subst m,y,$(CONFIG_HYPERV)) += hv_common.o
+obj-$(CONFIG_HYPERV) += hv_common.o
obj-$(subst m,y,$(CONFIG_MSHV_ROOT)) += hv_proc.o
ifneq ($(CONFIG_MSHV_ROOT) $(CONFIG_MSHV_VTL),)
obj-y += mshv_common.o
--
2.36.1.vfs.0.0
On Fri, Sep 05, 2025 at 06:09:52PM -0700, Mukesh Rathor wrote: > With CONFIG_HYPERV and CONFIG_HYPERV_VMBUS separated, change CONFIG_HYPERV > to bool from tristate. CONFIG_HYPERV now becomes the core Hyper-V > hypervisor support, such as hypercalls, clocks/timers, Confidential > Computing setup, PCI passthru, etc. that doesn't involve VMBus or VMBus > devices. But why are you making it so that this can not be a module anymore? You are now forcing ALL Linux distro users to always have this code in their system, despite not ever using the feature. That feels like a waste to me. What is preventing this from staying as a module? Why must you always have this code loaded at all times for everyone? thanks, greg k-h
On 9/6/25 04:36, Greg KH wrote: > On Fri, Sep 05, 2025 at 06:09:52PM -0700, Mukesh Rathor wrote: >> With CONFIG_HYPERV and CONFIG_HYPERV_VMBUS separated, change CONFIG_HYPERV >> to bool from tristate. CONFIG_HYPERV now becomes the core Hyper-V >> hypervisor support, such as hypercalls, clocks/timers, Confidential >> Computing setup, PCI passthru, etc. that doesn't involve VMBus or VMBus >> devices. > > But why are you making it so that this can not be a module anymore? You > are now forcing ALL Linux distro users to always have this code in their > system, despite not ever using the feature. That feels like a waste to > me. > > What is preventing this from staying as a module? Why must you always > have this code loaded at all times for everyone? This is currently not a module. I assume it was at the beginning. In drivers/Makefile today: obj-$(subst m,y,$(CONFIG_HYPERV)) += hv/ More context: CONFIG_HYPERV doesn't really reflect one module. It is both for kernel built in code and building of stuff in drivers/hv. drivers/hv then builds 4 modules: obj-$(CONFIG_HYPERV) += hv_vmbus.o obj-$(CONFIG_HYPERV_UTILS) += hv_utils.o obj-$(CONFIG_HYPERV_BALLOON) += hv_balloon.o obj-$(CONFIG_MSHV_ROOT) += mshv_root.o Notice vmbus is using CONFIG_HYPERV because there is no CONFIG_HYPERV_VMBUS. We are trying to fix that here. Thanks, -Mukesh > thanks, > > greg k-h
© 2016 - 2025 Red Hat, Inc.