|
|
|
|
|
|
|
|
|
|
xen-devel
Re: [Xen-devel] [PATCH 6 of 7] IOMMU: add crash_shutdown iommu_op
On 14/06/11 23:15, Kay, Allen M wrote:
> +static void vtd_crash_shutdown(void)
> +{
> + struct acpi_drhd_unit *drhd;
> + struct iommu *iommu;
> +
> + if ( !iommu_enabled )
> + return;
> +
> + iommu_flush_all();
> +
> + for_each_drhd_unit ( drhd )
> + {
> + iommu = drhd->iommu;
> + iommu_disable_translation(iommu);
> + }
> +
> + iommu_disable_x2apic_IR();
> +}
> +
>
> Iommu_disable_x2apic_IR() check for iommu_supports_eim() before entering.
> What happens when x2apic is not enabled but interrupt remapping is enabled?
>
> Maybe you should just create disable_intremap() and disable_qi() functions
> and call from vtd_crash_shutdown() and iommu_disable_x2apic_IR().
>
> Allen
Well spotted - I missed that. My suggestion would be to remove the
check for eim and deal with it in the relevant disable_intremap and
disable_qi functions. My feeling is that a call to "iommu_disable_IR"
should be able to deal whether or not you have eim.
If there are no objections, I will go ahead and try this and integrate
it into the patch 5 of the series which is already dealing with eim, and
needs some refactoring following my chat with Ian Campbell this morning.
--
Andrew Cooper - Dom0 Kernel Engineer, Citrix XenServer
T: +44 (0)1223 225 900, http://www.citrix.com
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|
|
|