[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [xen master] VT-d: replace flush_all_cache()
commit 89d5b779a854068a3194170b505f5e1f418ec082 Author: Jan Beulich <jbeulich@xxxxxxxx> AuthorDate: Fri Feb 18 14:18:51 2022 +0100 Commit: Jan Beulich <jbeulich@xxxxxxxx> CommitDate: Fri Feb 18 14:18:51 2022 +0100 VT-d: replace flush_all_cache() Let's use infrastructure we have available instead of an open-coded wbinvd() invocation. Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> Reviewed-by: Paul Durrant <paul@xxxxxxx> Reviewed-by: Kevin Tian <kevin.tian@xxxxxxxxx> --- xen/drivers/passthrough/vtd/extern.h | 2 -- xen/drivers/passthrough/vtd/iommu.c | 3 ++- xen/drivers/passthrough/vtd/x86/vtd.c | 5 ----- 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/xen/drivers/passthrough/vtd/extern.h b/xen/drivers/passthrough/vtd/extern.h index 5e9cc935c4..52b82f7132 100644 --- a/xen/drivers/passthrough/vtd/extern.h +++ b/xen/drivers/passthrough/vtd/extern.h @@ -78,8 +78,6 @@ int __must_check qinval_device_iotlb_sync(struct vtd_iommu *iommu, struct pci_dev *pdev, u16 did, u16 size, u64 addr); -void flush_all_cache(void); - uint64_t alloc_pgtable_maddr(unsigned long npages, nodeid_t node); void free_pgtable_maddr(u64 maddr); void *map_vtd_domain_page(u64 maddr); diff --git a/xen/drivers/passthrough/vtd/iommu.c b/xen/drivers/passthrough/vtd/iommu.c index 698b09d070..566b0e2a7e 100644 --- a/xen/drivers/passthrough/vtd/iommu.c +++ b/xen/drivers/passthrough/vtd/iommu.c @@ -623,7 +623,8 @@ static int __must_check iommu_flush_all(void) bool_t flush_dev_iotlb; int rc = 0; - flush_all_cache(); + flush_local(FLUSH_CACHE); + for_each_drhd_unit ( drhd ) { int context_rc, iotlb_rc; diff --git a/xen/drivers/passthrough/vtd/x86/vtd.c b/xen/drivers/passthrough/vtd/x86/vtd.c index 55f0faa521..76f12adc23 100644 --- a/xen/drivers/passthrough/vtd/x86/vtd.c +++ b/xen/drivers/passthrough/vtd/x86/vtd.c @@ -46,8 +46,3 @@ void unmap_vtd_domain_page(const void *va) { unmap_domain_page(va); } - -void flush_all_cache() -{ - wbinvd(); -} -- generated by git-patchbot for /home/xen/git/xen.git#master
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |