]> xenbits.xensource.com Git - people/royger/freebsd.git/commitdiff
madt_setup_local: skip further checks if ACPI DMAR table already disabled x2APIC
authorKonstantin Belousov <kib@FreeBSD.org>
Wed, 2 Jun 2021 22:01:28 +0000 (01:01 +0300)
committerKonstantin Belousov <kib@FreeBSD.org>
Thu, 3 Jun 2021 19:47:31 +0000 (22:47 +0300)
Reviewed by: markj
Tested by: David Sebek <dasebek@gmail.com>
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D30624

sys/x86/acpica/madt.c

index 5683f7eb321d57fd018cd7414a33f7b4d5a4af59..11c7b9de52d74067d3c3d64b66fcbf614782a0c0 100644 (file)
@@ -158,7 +158,9 @@ madt_setup_local(void)
                                reason = "by DMAR table";
                        acpi_unmap_table(dmartbl);
                }
-               if (vm_guest == VM_GUEST_VMWARE) {
+               if (reason != NULL) {
+                       /* Already disabled */
+               } else if (vm_guest == VM_GUEST_VMWARE) {
                        vmware_hvcall(VMW_HVCMD_GETVCPU_INFO, p);
                        if ((p[0] & VMW_VCPUINFO_VCPU_RESERVED) != 0 ||
                            (p[0] & VMW_VCPUINFO_LEGACY_X2APIC) == 0)