x86/cpuid: Handle the long vendor string in guest_cpuid()
authorAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 18 Jan 2017 18:13:17 +0000 (18:13 +0000)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 25 Jan 2017 10:24:40 +0000 (10:24 +0000)
Leaves 0x80000002 through 0x80000004 are plain ASCII text, and are left
exactly as the toolstack chooses.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Doug Goldstein <cardoe@cardoe.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/cpuid.c

index c06b5a6a8eaca73b9aa73ea03c4aa5773468cb85..9cea13c11e7697ba47cd1e31b6b79861d51e0a02 100644 (file)
@@ -698,7 +698,7 @@ static void pv_cpuid(uint32_t leaf, uint32_t subleaf, struct cpuid_leaf *res)
     case 0x2 ... 0x3:
     case 0x7 ... 0x9:
     case 0xc ... XSTATE_CPUID:
-    case 0x80000000 ... 0x80000001:
+    case 0x80000000 ... 0x80000004:
         ASSERT_UNREACHABLE();
         /* Now handled in guest_cpuid(). */
     }
@@ -815,7 +815,7 @@ static void hvm_cpuid(uint32_t leaf, uint32_t subleaf, struct cpuid_leaf *res)
     case 0x2 ... 0x3:
     case 0x7 ... 0x9:
     case 0xc ... XSTATE_CPUID:
-    case 0x80000000 ... 0x80000001:
+    case 0x80000000 ... 0x80000004:
         ASSERT_UNREACHABLE();
         /* Now handled in guest_cpuid(). */
     }
@@ -898,7 +898,7 @@ void guest_cpuid(const struct vcpu *v, uint32_t leaf,
         default:
             goto legacy;
 
-        case 0x80000000 ... 0x80000001:
+        case 0x80000000 ... 0x80000004:
             *res = p->extd.raw[leaf & 0xffff];
             break;
         }