ia64/xen-unstable
changeset 18880:99f01b8184c7
VT-d code cleanup
This patch narrow context caching flush range from the
domain-selective to the device-selective, when unmapping a device.
Signed-off-by: Yu Zhao <yu.zhao@intel.com>
This patch narrow context caching flush range from the
domain-selective to the device-selective, when unmapping a device.
Signed-off-by: Yu Zhao <yu.zhao@intel.com>
author | Keir Fraser <keir.fraser@citrix.com> |
---|---|
date | Fri Dec 05 10:59:41 2008 +0000 (2008-12-05) |
parents | 09160c3bd179 |
children | b44e244d7bb9 |
files | xen/drivers/passthrough/vtd/iommu.c |
line diff
1.1 --- a/xen/drivers/passthrough/vtd/iommu.c Fri Dec 05 15:47:19 2008 +0900 1.2 +++ b/xen/drivers/passthrough/vtd/iommu.c Fri Dec 05 10:59:41 2008 +0000 1.3 @@ -1308,7 +1308,9 @@ static int domain_context_unmap_one( 1.4 context_clear_entry(*context); 1.5 iommu_flush_cache_entry(context); 1.6 1.7 - if ( iommu_flush_context_domain(iommu, domain_iommu_domid(domain), 0) ) 1.8 + if ( iommu_flush_context_device(iommu, domain_iommu_domid(domain), 1.9 + (((u16)bus) << 8) | devfn, 1.10 + DMA_CCMD_MASK_NOBIT, 0) ) 1.11 iommu_flush_write_buffer(iommu); 1.12 else 1.13 iommu_flush_iotlb_dsi(iommu, domain_iommu_domid(domain), 0);