git: da55f86c6146 - main - x86/iommu: Eliminate redundant wrappers
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 16 Jul 2022 23:07:35 UTC
The branch main has been updated by alc: URL: https://cgit.FreeBSD.org/src/commit/?id=da55f86c61462b119fd1306d12411989d6610650 commit da55f86c61462b119fd1306d12411989d6610650 Author: Alan Cox <alc@FreeBSD.org> AuthorDate: 2022-07-16 04:25:11 +0000 Commit: Alan Cox <alc@FreeBSD.org> CommitDate: 2022-07-16 23:05:37 +0000 x86/iommu: Eliminate redundant wrappers Reviewed by: kib MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D35832 --- sys/x86/iommu/intel_ctx.c | 26 ++++---------------------- sys/x86/iommu/intel_dmar.h | 3 --- 2 files changed, 4 insertions(+), 25 deletions(-) diff --git a/sys/x86/iommu/intel_ctx.c b/sys/x86/iommu/intel_ctx.c index 79e2a15d80c7..bfc607674b57 100644 --- a/sys/x86/iommu/intel_ctx.c +++ b/sys/x86/iommu/intel_ctx.c @@ -868,7 +868,7 @@ dmar_domain_free_entry(struct iommu_map_entry *entry, bool free) } void -dmar_domain_unload_entry(struct iommu_map_entry *entry, bool free) +iommu_domain_unload_entry(struct iommu_map_entry *entry, bool free) { struct dmar_domain *domain; struct dmar_unit *unit; @@ -902,15 +902,15 @@ dmar_domain_unload_emit_wait(struct dmar_domain *domain, } void -dmar_domain_unload(struct dmar_domain *domain, +iommu_domain_unload(struct iommu_domain *iodom, struct iommu_map_entries_tailq *entries, bool cansleep) { + struct dmar_domain *domain; struct dmar_unit *unit; - struct iommu_domain *iodom; struct iommu_map_entry *entry, *entry1; int error __diagused; - iodom = DOM2IODOM(domain); + domain = IODOM2DOM(iodom); unit = DOM2DMAR(domain); TAILQ_FOREACH_SAFE(entry, entries, dmamap_link, entry1) { @@ -975,21 +975,3 @@ iommu_free_ctx(struct iommu_ctx *context) dmar_free_ctx(ctx); } - -void -iommu_domain_unload_entry(struct iommu_map_entry *entry, bool free) -{ - - dmar_domain_unload_entry(entry, free); -} - -void -iommu_domain_unload(struct iommu_domain *iodom, - struct iommu_map_entries_tailq *entries, bool cansleep) -{ - struct dmar_domain *domain; - - domain = IODOM2DOM(iodom); - - dmar_domain_unload(domain, entries, cansleep); -} diff --git a/sys/x86/iommu/intel_dmar.h b/sys/x86/iommu/intel_dmar.h index b34505a4e5d0..05793ed9f238 100644 --- a/sys/x86/iommu/intel_dmar.h +++ b/sys/x86/iommu/intel_dmar.h @@ -277,9 +277,6 @@ int dmar_move_ctx_to_domain(struct dmar_domain *domain, struct dmar_ctx *ctx); void dmar_free_ctx_locked(struct dmar_unit *dmar, struct dmar_ctx *ctx); void dmar_free_ctx(struct dmar_ctx *ctx); struct dmar_ctx *dmar_find_ctx_locked(struct dmar_unit *dmar, uint16_t rid); -void dmar_domain_unload_entry(struct iommu_map_entry *entry, bool free); -void dmar_domain_unload(struct dmar_domain *domain, - struct iommu_map_entries_tailq *entries, bool cansleep); void dmar_domain_free_entry(struct iommu_map_entry *entry, bool free); void dmar_dev_parse_rmrr(struct dmar_domain *domain, int dev_domain,