amd_iommu: Turn on XT support only when guest has enabled it
Current code uses 32 bit destination ID irrespective of the fact that guest has enabled x2APIC support through control register[XTEn] and completely depends on command line parameter xtsup=on. This is not a correct hardware behaviour and can cause problems in the guest which has not enabled XT mode. Introduce new flag "xten", which is enabled when guest writes 1 to the control register bit 50 (XTEn). Also, add a new subsection in `VMStateDescription` for backward compatibility during vm migration. Signed-off-by: Sairaj Kodilkar <sarunkod@amd.com> Reviewed-by: Vasant Hegde <vasant.hegde@amd.com> Reviewed-by: Alejandro Jimenez <alejandro.j.jimenez@oracle.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Message-Id: <20260302115130.5903-3-sarunkod@amd.com>