@@ -858,9 +858,6 @@ int arch_domain_create(struct domain *d,
if ( (rc = init_domain_irq_mapping(d)) != 0 )
goto fail;
- if ( (rc = iommu_domain_init(d, config->iommu_opts)) != 0 )
- goto fail;
-
psr_domain_init(d);
if ( is_hvm_domain(d) )
@@ -879,6 +876,9 @@ int arch_domain_create(struct domain *d,
else
ASSERT_UNREACHABLE(); /* Not HVM and not PV? */
+ if ( (rc = iommu_domain_init(d, config->iommu_opts)) != 0 )
+ goto fail;
+
if ( (rc = tsc_set_info(d, XEN_CPUID_TSC_MODE_DEFAULT, 0, 0, 0)) != 0 )
{
ASSERT_UNREACHABLE();
For the IOMMU redesign, the iommu context pagetable is defined once during initialization. When reusing P2M pagetable, we want to ensure that this pagetable is properly initialized. Signed-off-by: Teddy Astie <teddy.astie@vates.tech> --- xen/arch/x86/domain.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)