x86/cpuid: do not expand max leaves on restore
authorRoger Pau Monné <roger.pau@citrix.com>
Thu, 29 Apr 2021 14:04:11 +0000 (16:04 +0200)
committerJan Beulich <jbeulich@suse.com>
Thu, 29 Apr 2021 14:04:11 +0000 (16:04 +0200)
commit111c8c33a8a18588f3da3c5dbb7f5c63ddb98ce5
tree0168ae8c3ac9f312907140458421434cc3a7621d
parentec0ec164877be4e99dfef2ae27eea4ca6460cdf7
x86/cpuid: do not expand max leaves on restore

When restoring limit the maximum leaves to the ones supported by Xen
4.12 in order to not expand the maximum leaves a guests sees. Note
this is unlikely to cause real issues.

Guests restored from Xen versions 4.13 or greater will contain CPUID
data on the stream that will override the values set by
xc_cpuid_apply_policy.

Reported-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
tools/libs/guest/xg_cpuid_x86.c