x86/cpuid: Handle leaf 0x5 in guest_cpuid()
authorAndrew Cooper <andrew.cooper3@citrix.com>
Fri, 17 Feb 2017 17:32:29 +0000 (17:32 +0000)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 13 Mar 2017 13:44:39 +0000 (13:44 +0000)
commit706b2b73679cab37ff253af67e129353a46fdcc1
treec182d78af325fb2aa3aa92027136d3148d9db8ff
parent0b4249e96b458d92bc8f2bade41bf16b468618fb
x86/cpuid: Handle leaf 0x5 in guest_cpuid()

The MONITOR flag isn't exposed to guests.  The existing toolstack logic, and
pv_cpuid() in the hypervisor, zero the MONITOR leaf for queries.

However, the MONITOR leaf is still visible in the hardware domains native
CPUID view, and Linux depends on this to set up C-state information.  Leak the
hosts MONITOR leaf under the same circumstances that the MONITOR feature is
leaked.

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