[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1751582677-30930-2-git-send-email-nunodasneves@linux.microsoft.com>
Date: Thu, 3 Jul 2025 15:44:32 -0700
From: Nuno Das Neves <nunodasneves@...ux.microsoft.com>
To: linux-hyperv@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org,
linux-pci@...r.kernel.org,
mhklinux@...look.com,
tglx@...utronix.de,
bhelgaas@...gle.com,
romank@...ux.microsoft.com
Cc: kys@...rosoft.com,
haiyangz@...rosoft.com,
wei.liu@...nel.org,
decui@...rosoft.com,
catalin.marinas@....com,
will@...nel.org,
mingo@...hat.com,
bp@...en8.de,
dave.hansen@...ux.intel.com,
hpa@...or.com,
lpieralisi@...nel.org,
kw@...ux.com,
robh@...nel.org,
jinankjain@...ux.microsoft.com,
skinsburskii@...ux.microsoft.com,
mrathor@...ux.microsoft.com,
x86@...nel.org,
Nuno Das Neves <nunodasneves@...ux.microsoft.com>
Subject: [PATCH v2 1/6] PCI: hv: Don't load the driver for baremetal root partition
From: Mukesh Rathor <mrathor@...ux.microsoft.com>
The root partition only uses VMBus when running nested.
When running on baremetal the Hyper-V PCI driver is not needed,
so do not initialize it.
Signed-off-by: Mukesh Rathor <mrathor@...ux.microsoft.com>
Signed-off-by: Nuno Das Neves <nunodasneves@...ux.microsoft.com>
Reviewed-by: Roman Kisel <romank@...ux.microsoft.com>
---
drivers/pci/controller/pci-hyperv.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/pci/controller/pci-hyperv.c b/drivers/pci/controller/pci-hyperv.c
index b4f29ee75848..4d25754dfe2f 100644
--- a/drivers/pci/controller/pci-hyperv.c
+++ b/drivers/pci/controller/pci-hyperv.c
@@ -4150,6 +4150,9 @@ static int __init init_hv_pci_drv(void)
if (!hv_is_hyperv_initialized())
return -ENODEV;
+ if (hv_root_partition() && !hv_nested)
+ return -ENODEV;
+
ret = hv_pci_irqchip_init();
if (ret)
return ret;
--
2.34.1
Powered by blists - more mailing lists