]> xenbits.xensource.com Git - xen.git/commit
x86/pagewalk: Remove opt_allow_superpage check from guest_can_use_l2_superpages()
authorAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 24 Jul 2017 16:28:25 +0000 (17:28 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 25 Jul 2017 17:48:37 +0000 (18:48 +0100)
commit28d9a9a2d41759b9e5163037b759ac557aea767c
tree3f542cb7c6b34737a750a1652e57022cc2966afc
parentad0890c2bf12f8287765abf0cbf37f54af5b22ad
x86/pagewalk: Remove opt_allow_superpage check from guest_can_use_l2_superpages()

The purpose of guest_walk_tables() is to match the behaviour of real hardware.

A PV guest can have 2M superpages in its pagetables, via the M2P (and for dom0
via the initial P2M), even if the guest isn't permitted to create arbitrary 2M
superpage mappings.

guest_can_use_l2_superpages() checking opt_allow_superpage is a piece of PV
guest policy enforcement, rather than its intended purpose of meaning "would
hardware tolerate finding an L2 superpage with these control settings?"

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Tim Deegan <tim@xen.org>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
xen/include/asm-x86/guest_pt.h