Port-xen archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: -current currently broken



On Sat, Mar 06, 2021 at 12:01:59PM -0500, Brian Marcotte wrote:
> > ... I find that -current is not currently working in PVH or PV modes.
> 
> I find that if I revert src/sys/arch/x86/x86/identcpu.c to 1.118, it
> works again.
> 
> The commit message for 1.119 is "Identify VirtualBox as a separate guest
> type".

thanks for tracking it down.
Can you try the attached patch ?

-- 
Manuel Bouyer <bouyer%antioche.eu.org@localhost>
     NetBSD: 26 ans d'experience feront toujours la difference
--
Index: identcpu.c
===================================================================
RCS file: /cvsroot/src/sys/arch/x86/x86/identcpu.c,v
retrieving revision 1.119
diff -u -p -u -r1.119 identcpu.c
--- identcpu.c	19 Feb 2021 02:15:24 -0000	1.119
+++ identcpu.c	6 Mar 2021 17:35:30 -0000
@@ -1135,18 +1135,14 @@ identify_hypervisor(void)
 	const char *p;
 	int i;
 
-#if 0	
-	/* 
-	 * This is called from cpu_probe() and cpu_configure()
-	 * During cpu_probe() we have not called platform_init()
-	 * yet, so the bios tables have not been loaded.
-	 * We allow this to be called twice in order to override
-	 * the cpuid setting because some hypervisors don't return
-	 * specific enough info with cpuid it.
-	 */
-	if (vm_guest != VM_GUEST_NO)
+	switch(vm_guest) {
+	case VM_GUEST_XENPV:
+	case VM_GUEST_XENPVH:
+		/* guest type already known, no bios info */
 		return;
-#endif
+	default:
+		break;
+	}
 
 	/*
 	 * [RFC] CPUID usage for interaction between Hypervisors and Linux.


Home | Main Index | Thread Index | Old Index