x86/pvh: reorder PVH dom0 iommu initialization
authorRoger Pau Monné <roger.pau@citrix.com>
Mon, 18 Feb 2019 12:43:50 +0000 (13:43 +0100)
committerJan Beulich <jbeulich@suse.com>
Mon, 18 Feb 2019 12:43:50 +0000 (13:43 +0100)
commit036c6cbddca28be5a526da045bb379fedfad8255
tree1af9652cc014a2fc092b45dd029f08150b57fef4
parentdc0b0b1f2d5792ecd9e26f2e65b36682f8ec2b27
x86/pvh: reorder PVH dom0 iommu initialization

So that the iommu is initialized before populating the p2m, and
entries added get the corresponding iommu page table entries if
required. This requires splitting the current pvh_setup_p2m into two
different functions. One that crafts dom0 physmap and sets the paging
allocation, and another one that actually populates the p2m with RAM
regions.

Note that this allows to remove the special casing done for the low
1MB in hwdom_iommu_map.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
Release-acked-by: Juergen Gross <jgross@suse.com>
xen/arch/x86/hvm/dom0_build.c
xen/drivers/passthrough/x86/iommu.c