On 28/03/2019 14:49, Jan Beulich wrote:
> In order to be able to initialize x2APIC mode we need to parse
> respective ACPI tables early. Split amd_iov_detect() into two parts for
> this purpose, and call the initial part earlier on.
>
> Signed-off-by: Jan Beulich <jbeul...@suse.com>

Reviewed-by: Andrew Cooper <andrew.coop...@citrix.com>

> --- a/xen/include/asm-x86/acpi.h
> +++ b/xen/include/asm-x86/acpi.h
> @@ -26,6 +26,7 @@
>  #include <acpi/pdc_intel.h>
>  #include <acpi/acconfig.h>
>  #include <acpi/actbl.h>
> +#include <xen/errno.h>
>  
>  #define COMPILER_DEPENDENT_INT64   long long
>  #define COMPILER_DEPENDENT_UINT64  unsigned long long
> @@ -145,6 +146,15 @@ extern u32 pmtmr_ioport;
>  extern unsigned int pmtmr_width;
>  
>  int acpi_dmar_init(void);
> +int acpi_ivrs_init(void);
> +
> +static inline int acpi_iommu_init(void)
> +{
> +    int ret = acpi_dmar_init();
> +
> +    return ret == -ENODEV ? acpi_ivrs_init() : ret;
> +}
> +

I suppose we really don't have any better option here than to try for
all APCI tables we may be interested in.  I certainly can't think of any
identifying information we could usefully switch() on instead.

~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to