[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 3/7] x86/ACPI: also parse AMD IOMMU tables early



>>> On 28.03.19 at 17:43, <andrew.cooper3@xxxxxxxxxx> wrote:
> 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 <jbeulich@xxxxxxxx>
> 
> Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

Thanks.

>> @@ -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.

Yeah, I've been trying to think of some way to sensibly avoid
either of the attempts, but keying this off of the CPU vendor
doesn't seem right. Since we can't tolerate a mixture of IOMMUs,
the above seemed the most reasonable thing we can do, thus
ensuring that even in a strange (virtualized?) environment
where both tables exist we'd enable only one of the two kinds.

Jan



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

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.