iommu.lists.linux-foundation.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] iommu/vt-d: No need to export dmar_platform_optin()
@ 2024-04-24 13:05 Mika Westerberg
  0 siblings, 0 replies; only message in thread
From: Mika Westerberg @ 2024-04-24 13:05 UTC (permalink / raw)
  To: David Woodhouse, Lu Baolu
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, iommu, Mika Westerberg

This function is not called anymore outside of this driver so we can
drop the export and move the declaration to the driver private header.

No functional changes.

Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
---
 drivers/iommu/intel/dmar.c  | 1 -
 drivers/iommu/intel/iommu.h | 2 ++
 include/linux/dmar.h        | 7 -------
 3 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/drivers/iommu/intel/dmar.c b/drivers/iommu/intel/dmar.c
index 36d7427b1202..42b79043241c 100644
--- a/drivers/iommu/intel/dmar.c
+++ b/drivers/iommu/intel/dmar.c
@@ -2480,4 +2480,3 @@ bool dmar_platform_optin(void)
 
 	return ret;
 }
-EXPORT_SYMBOL_GPL(dmar_platform_optin);
diff --git a/drivers/iommu/intel/iommu.h b/drivers/iommu/intel/iommu.h
index 404d2476a877..4a965848ea0f 100644
--- a/drivers/iommu/intel/iommu.h
+++ b/drivers/iommu/intel/iommu.h
@@ -1041,6 +1041,8 @@ static inline void context_set_sm_pre(struct context_entry *context)
 /* Convert value to context PASID directory size field coding. */
 #define context_pdts(pds)	(((pds) & 0x7) << 9)
 
+bool dmar_platform_optin(void);
+
 struct dmar_drhd_unit *dmar_find_matched_drhd_unit(struct pci_dev *dev);
 
 int dmar_enable_qi(struct intel_iommu *iommu);
diff --git a/include/linux/dmar.h b/include/linux/dmar.h
index e34b601b71fd..233ef518dc99 100644
--- a/include/linux/dmar.h
+++ b/include/linux/dmar.h
@@ -173,8 +173,6 @@ static inline int dmar_ir_hotplug(struct dmar_drhd_unit *dmaru, bool insert)
 { return 0; }
 #endif /* CONFIG_IRQ_REMAP */
 
-extern bool dmar_platform_optin(void);
-
 #else /* CONFIG_DMAR_TABLE */
 
 static inline int dmar_device_add(void *handle)
@@ -187,11 +185,6 @@ static inline int dmar_device_remove(void *handle)
 	return 0;
 }
 
-static inline bool dmar_platform_optin(void)
-{
-	return false;
-}
-
 static inline void detect_intel_iommu(void)
 {
 }
-- 
2.43.0


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2024-04-24 13:05 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-24 13:05 [PATCH] iommu/vt-d: No need to export dmar_platform_optin() Mika Westerberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).