Allow ATS to be always on for certain ATS-capable devices
Subsystems (3)
v2 cover Allow ATS to be always on for certain ATS-capable devices
PCI ATS function is controlled by IOMMU driver calling pci_enable_ats() and pci_disable_ats() helpers. In general, IOMMU driver only enables ATS, when a translation channel is enabled on a PASID, typically for an SVA use case. When a device's RID is IOMMU bypassed and there is no active PASID running SVA use case, ATS is always disabled.
However, certain PCIe devices require non-PASID ATS on its RID, even if the RID is IOMMU bypassed. E.g. CXL.cache capability requires ATS to access the physical memory; some pre-CXL NVIDIA GPUs also require the ATS to be always on even when their RIDs are IOMMU bypassed.
Provide a helper function to detect CXL.cache capability and scan through a pre-CXL device ID list.
As the initial use case, call the helper in ARM SMMUv3 driver and adapt the driver accordingly with a per-device ats_always_on flag.
This is on Github:
https://github.com/nicolinc/iommufd/commits/pci_ats_always_on-v2/
Changelog
v2
* s/non-CXL/pre-CXL
* Rebase on v7.0-rc1
* Update inline comments and commit message
* Add WARN_ON back at !ptr in arm_smmu_clear_cd()
* Add NVIDIA CX10 Family NVlink-C2C to the pre-CXL list
* Do not add boolean parameter to arm_smmu_attach_dev_ste()
v1
https://lore.kernel.org/all/[email protected]/
Nicolin Chen (3):
PCI: Allow ATS to be always on for CXL.cache capable devices
PCI: Allow ATS to be always on for pre-CXL devices iommu/arm-smmu-v3: Allow ATS to be always on
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.h | 1 + drivers/pci/pci.h | 9 +++ include/linux/pci-ats.h | 3 + include/uapi/linux/pci_regs.h | 1 + drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 73 ++++++++++++++++++--- drivers/pci/ats.c | 45 +++++++++++++ drivers/pci/quirks.c | 26 ++++++++ 7 files changed, 150 insertions(+), 8 deletions(-)
Signature · 1 line
2.43.0
PATCH v2 1/3 PCI: Allow ATS to be always on for CXL.cache capable devices
Controlled by the IOMMU driver, ATS is usually enabled "on demand" when a device requests a translation service from its associated IOMMU HW running on the channel of a given PASID. This is working even when a device has no translation on its RID (i.e., the RID is IOMMU bypassed).
However, certain PCIe devices require non-PASID ATS on their RID even when the RID is IOMMU bypassed. Call this "always on".
For instance, the CXL spec notes in "3.2.5.13 Memory Type on CXL.cache":
"To source requests on CXL.cache, devices need to get the Host Physical Address (HPA) from the Host by means of an ATS request on CXL.io."
In other words, the CXL.cache capability requires ATS; otherwise, it can't access host physical memory.
Introduce a new pci_ats_always_on() helper for the IOMMU driver to scan a PCI device and shift ATS policies between "on demand" and "always on".
Add the support for CXL.cache devices first. Pre-CXL devices will be added in quirks.c file.
Note that pci_ats_always_on() validates against pci_ats_supported(), so we ensure that untrusted devices (e.g. external ports) will not be always on. This maintains the existing ATS security policy regarding potential side- channel attacks via ATS.
--- include/linux/pci-ats.h | 3 +++ include/uapi/linux/pci_regs.h | 1 + drivers/pci/ats.c | 44 +++++++++++++++++++++++++++++++++++ 3 files changed, 48 insertions(+)
include/linux/pci-ats.h +3 -0
@@ -12,6 +12,7 @@ int pci_prepare_ats(struct pci_dev *dev, int ps);void pci_disable_ats (struct pci_dev *dev);int pci_ats_queue_depth (struct pci_dev *dev);int pci_ats_page_aligned (struct pci_dev *dev); +bool pci_ats_always_on (struct pci_dev *dev);#else /* CONFIG_PCI_ATS */ static inline bool pci_ats_supported (struct pci_dev *d) {return false; }
@@ -24,6 +25,8 @@ static inline int pci_ats_queue_depth(struct pci_dev *d) {return -ENODEV ; }static inline int pci_ats_page_aligned (struct pci_dev *dev) {return 0 ; } +static inline bool pci_ats_always_on (struct pci_dev *dev) +{return false; }#endif /* CONFIG_PCI_ATS */ #ifdef CONFIG_PCI_PRI
include/uapi/linux/pci_regs.h +1 -0
@@ -1349,6 +1349,7 @@/* CXL r4.0, 8.1.3: PCIe DVSEC for CXL Device */ #define PCI_DVSEC_CXL_DEVICE 0#define PCI_DVSEC_CXL_CAP 0xA +#define PCI_DVSEC_CXL_CACHE_CAPABLE _BITUL(0)#define PCI_DVSEC_CXL_MEM_CAPABLE _BITUL(2)#define PCI_DVSEC_CXL_HDM_COUNT __GENMASK(5, 4)#define PCI_DVSEC_CXL_CTRL 0xC
drivers/pci/ats.c +44 -0
50 lines not on this page · raw message
Signature · 1 line
2.43.0
Re: [PATCH v2 1/3] PCI: Allow ATS to be always on for CXL.cache capable devices
Quoted 21 lines · On Mon, 23 Feb 2026 14:52:20 -0800 Nicolin Chen <[email protected]> wrote:
Controlled by the IOMMU driver, ATS is usually enabled "on demand" when a device requests a translation service from its associated IOMMU HW running on the channel of a given PASID. This is working even when a device has no translation on its RID (i.e., the RID is IOMMU bypassed).
However, certain PCIe devices require non-PASID ATS on their RID even when the RID is IOMMU bypassed. Call this "always on".
For instance, the CXL spec notes in "3.2.5.13 Memory Type on CXL.cache":
"To source requests on CXL.cache, devices need to get the Host Physical Address (HPA) from the Host by means of an ATS request on CXL.io."In other words, the CXL.cache capability requires ATS; otherwise, it can't access host physical memory.
Introduce a new
pci_ats_always_on()helper for the IOMMU driver to scan a PCI device and shift ATS policies between "on demand" and "always on".Add the support for CXL.cache devices first. Pre-CXL devices will be added in
quirks.cfile.
Quoted 8 lines
Note that
pci_ats_always_on()validates againstpci_ats_supported(), so we ensure that untrusted devices (e.g. external ports) will not be always on. This maintains the existing ATS security policy regarding potential side- channel attacks via ATS.Suggested-by Vikram Sethi <[email protected]>Suggested-by Jason Gunthorpe <[email protected]>Signed-off-by Nicolin Chen <[email protected]>
+CC Linux-cxl
Quoted 44 lines
--- include/linux/pci-ats.h | 3 +++ include/uapi/linux/pci_regs.h | 1 + drivers/pci/ats.c | 44 +++++++++++++++++++++++++++++++++++ 3 files changed, 48 insertions(+)include/linux/pci-ats.h +3
-0@@ -12,6 +12,7 @@ int pci_prepare_ats(struct pci_dev *dev, int ps);void pci_disable_ats (struct pci_dev *dev);int pci_ats_queue_depth (struct pci_dev *dev);int pci_ats_page_aligned (struct pci_dev *dev); +bool pci_ats_always_on (struct pci_dev *dev);#else /* CONFIG_PCI_ATS */ static inline bool pci_ats_supported (struct pci_dev *d) {return false; }@@ -24,6 +25,8 @@ static inline int pci_ats_queue_depth(struct pci_dev *d) {return -ENODEV ; }static inline int pci_ats_page_aligned (struct pci_dev *dev) {return 0 ; } +static inline bool pci_ats_always_on (struct pci_dev *dev) +{return false; }#endif /* CONFIG_PCI_ATS */ #ifdef CONFIG_PCI_PRI include/uapi/linux/pci_regs.h +1
-0@@ -1349,6 +1349,7 @@/* CXL r4.0, 8.1.3: PCIe DVSEC for CXL Device */ #define PCI_DVSEC_CXL_DEVICE 0#define PCI_DVSEC_CXL_CAP 0xA +#define PCI_DVSEC_CXL_CACHE_CAPABLE _BITUL(0)#define PCI_DVSEC_CXL_MEM_CAPABLE _BITUL(2)#define PCI_DVSEC_CXL_HDM_COUNT __GENMASK(5, 4)#define PCI_DVSEC_CXL_CTRL 0xCdrivers/pci/ats.c +0
-0
drivers/pci/ats.c int pci_ats_page_aligned(struct pci_dev *pdev) · line 213
Quoted 9 lines
drivers/pci/ats.c +6
-0@@ -205,6 +205,50 @@ int pci_ats_page_aligned(struct pci_dev *pdev)return 0 ; } +/* +* CXL r4.0, sec 3.2.5.13 Memory Type on CXL.cache notes: to source requests on +* CXL.cache, devices need to get the Host Physical Address (HPA) from the Host +* by means of an ATS request on CXL.io. +* +* In other world, CXL.cache devices cannot access physical memory without ATS.
Maybe tweak that to "host physical memory"
There are too many physical memories in CXL land...
Quoted 4 lines
drivers/pci/ats.c +4
-0+*/ +static bool pci_cxl_ats_always_on (struct pci_dev *pdev) +{ +int offset;
drivers/pci/ats.c int pci_ats_page_aligned(struct pci_dev *pdev) · line 227
Quoted 10 lines
drivers/pci/ats.c +10
-0+u16 cap; + + offset =pci_find_dvsec_capability (pdev,PCI_VENDOR_ID_CXL , +PCI_DVSEC_CXL_DEVICE ); +if (!offset) +return false; + +pci_read_config_word (pdev, offset +PCI_DVSEC_CXL_CAP , &cap); +if (cap &PCI_DVSEC_CXL_CACHE_CAPABLE ) +return true;
Could just do
return cap & PCI_DVSEC_CXL_CACHE_CAPABLE;
Unless the thinking is there may be other stuff that comes here.
Quoted 27 lines
drivers/pci/ats.c +24
-0+ +return false; +} + +/** +* pci_ats_always_on - Whether the PCI device requires ATS to be always enabled +* @pdev: the PCI device +* +* Returns true, if the PCI device requires non-PASID ATS function on an IOMMU +* bypassed configuration. +*/ +bool pci_ats_always_on (struct pci_dev *pdev) +{ +if (pci_ats_disabled () || !pci_ats_supported (pdev)) +return false; + +/* A VF inherits its PF's requirement for ATS function */ +if (pdev->is_virtfn) + pdev =pci_physfn (pdev); + +return pci_cxl_ats_always_on (pdev); +} +EXPORT_SYMBOL_GPL (pci_ats_always_on); +#ifdef CONFIG_PCI_PRI void pci_pri_init (struct pci_dev *pdev) {
Re: [PATCH v2 1/3] PCI: Allow ATS to be always on for CXL.cache capable devices
Quoted 30 lines · Jonathan Cameron
Quoted 6 lines · On Mon, 23 Feb 2026 14:52:20 -0800 Nicolin Chen <[email protected]> wrote:
+/*
+ * CXL r4.0, sec 3.2.5.13 Memory Type on CXL.cache notes: to source requests on
+ * CXL.cache, devices need to get the Host Physical Address (HPA) from the Host
+ * by means of an ATS request on CXL.io.
+ *
+ * In other world, CXL.cache devices cannot access physical memory without ATS.Maybe tweak that to "host physical memory"
There are too many physical memories in CXL land...
Quoted 4 lines
+ */
drivers/pci/ats.c +3
-0+static bool pci_cxl_ats_always_on (struct pci_dev *pdev) +{ +int offset;drivers/pci/ats.c int pci_ats_page_aligned(struct pci_dev *pdev) · line 227
Quoted 10 lines
drivers/pci/ats.c +10
-0+u16 cap; + + offset =pci_find_dvsec_capability (pdev,PCI_VENDOR_ID_CXL , +PCI_DVSEC_CXL_DEVICE ); +if (!offset) +return false; + +pci_read_config_word (pdev, offset +PCI_DVSEC_CXL_CAP , &cap); +if (cap &PCI_DVSEC_CXL_CACHE_CAPABLE ) +return true;Could just do
Quoted 3 lines
return cap & PCI_DVSEC_CXL_CACHE_CAPABLE;Unless the thinking is there may be other stuff that comes here.
I will fix both. Thanks for the review!
Nicolin
Re: [PATCH v2 1/3] PCI: Allow ATS to be always on for CXL.cache capable devices
In reply to Nicolin ChenQuoted 6 lines · Nicolin Chen
+/**
+ *pci_ats_always_on- Whether the PCI device requires ATS to be always enabled
+ * @pdev: the PCI device
+ *
+ * Returns true, if the PCI device requires non-PASID ATS function on an IOMMU
+ * bypassed configuration.
Including iommu-specific policies and configurations here might cause confusion. How about making it simply as: "Returns true if the PCI device requires ATS to be enabled for functional operation"?
drivers/pci/ats.c int pci_ats_page_aligned(struct pci_dev *pdev) · line 250
Quoted 13 lines
+ */
drivers/pci/ats.c +12
-0+bool pci_ats_always_on (struct pci_dev *pdev) +{ +if (pci_ats_disabled () || !pci_ats_supported (pdev)) +return false; + +/* A VF inherits its PF's requirement for ATS function */ +if (pdev->is_virtfn) + pdev =pci_physfn (pdev); + +return pci_cxl_ats_always_on (pdev); +} +EXPORT_SYMBOL_GPL (pci_ats_always_on);
Thanks,
baolu
Re: [PATCH v2 1/3] PCI: Allow ATS to be always on for CXL.cache capable devices
Quoted 11 lines · Baolu Lu
Quoted 6 lines · Nicolin Chen
+/**
+ *pci_ats_always_on- Whether the PCI device requires ATS to be always enabled
+ * @pdev: the PCI device
+ *
+ * Returns true, if the PCI device requires non-PASID ATS function on an IOMMU
+ * bypassed configuration.Including iommu-specific policies and configurations here might cause confusion. How about making it simply as: "Returns true if the PCI device requires ATS to be enabled for functional operation"?
Yea, that sounds good to me. Thanks!
Nicolin
PATCH v2 2/3 PCI: Allow ATS to be always on for pre-CXL devices
In reply to Nicolin ChenSome NVIDIA GPU/NIC devices, although don't implement the CXL config space, they have many CXL-like properties. Call this kind "pre-CXL".
Similar to CXL.cache capaiblity, these pre-CXL devices also require the ATS function even when their RIDs are IOMMU bypassed, i.e. keep ATS "always on" v.s. "on demand" when a non-zero PASID line gets enabled in SVA use cases.
Introduce pci_dev_specific_ats_always_on() quirk function to scan a list of IDs for these device. Then, include it pci_ats_always_on().
--- drivers/pci/pci.h | 9 +++++++++ drivers/pci/ats.c | 3 ++- drivers/pci/quirks.c | 26 ++++++++++++++++++++++++++ 3 files changed, 37 insertions(+), 1 deletion(-)
drivers/pci/pci.h +9 -0
@@ -1150,6 +1150,15 @@ static inline int pci_dev_specific_reset(struct pci_dev *dev, bool probe) }#endif +#if defined(CONFIG_PCI_QUIRKS ) && defined(CONFIG_PCI_ATS ) +bool pci_dev_specific_ats_always_on (struct pci_dev *dev); +#else +static inline bool pci_dev_specific_ats_always_on (struct pci_dev *dev) +{ +return false; +} +#endif +#if defined(CONFIG_PCI_QUIRKS ) && defined(CONFIG_ARM64 )int acpi_get_rc_resources (struct device *dev,const char *hid,u16 segment,struct resource *res);
drivers/pci/ats.c +2 -1
@@ -245,7 +245,8 @@ bool pci_ats_always_on(struct pci_dev *pdev)if (pdev->is_virtfn) pdev =pci_physfn (pdev); -return pci_cxl_ats_always_on (pdev); +return pci_cxl_ats_always_on (pdev) || +pci_dev_specific_ats_always_on (pdev); }EXPORT_SYMBOL_GPL (pci_ats_always_on);
drivers/pci/quirks.c +26 -0
@@ -5714,6 +5714,32 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, 0x1457, quirk_intel_e2000_no_ats);DECLARE_PCI_FIXUP_FINAL (PCI_VENDOR_ID_INTEL ,0x1459 , quirk_intel_e2000_no_ats);DECLARE_PCI_FIXUP_FINAL (PCI_VENDOR_ID_INTEL ,0x145a , quirk_intel_e2000_no_ats);DECLARE_PCI_FIXUP_FINAL (PCI_VENDOR_ID_INTEL ,0x145c , quirk_intel_e2000_no_ats); + +static const struct pci_dev_ats_always_on { +u16 vendor; +u16 device; +} pci_dev_ats_always_on[] = { +/* NVIDIA GPUs */ + {PCI_VENDOR_ID_NVIDIA ,0x2e12 , }, + {PCI_VENDOR_ID_NVIDIA ,0x2e2a , }, + {PCI_VENDOR_ID_NVIDIA ,0x2e2b , }, +/* NVIDIA CX10 Family NVlink-C2C */ + {PCI_VENDOR_ID_MELLANOX ,0x2101 , }, + {0 } +}; + +/* Some pre-CXL devices require ATS on the RID when it is IOMMU-bypassed */ +bool pci_dev_specific_ats_always_on (struct pci_dev *pdev) +{ +const struct pci_dev_ats_always_on *i; + +for (i = pci_dev_ats_always_on; i->vendor; i++) { +if (i->vendor == pdev->vendor && i->device == pdev->device) +return true; + } + +return false; +}#endif /* CONFIG_PCI_ATS */ /* Freescale PCIe doesn't support MSI in RC mode */
Signature · 1 line
2.43.0
PATCH v2 3/3 iommu/arm-smmu-v3: Allow ATS to be always on
In reply to Nicolin ChenWhen a device's default substream attaches to an identity domain, the SMMU driver currently sets the device's STE between two modes:
Mode 1: Cfg=Translate, S1DSS=Bypass, EATS=1
Mode 2: Cfg=bypass (EATS is ignored by HW)
When there is an active PASID (non-default substream), mode 1 is used. And when there is no PASID support or no active PASID, mode 2 is used.
The driver will also downgrade an STE from mode 1 to mode 2, when the last active substream becomes inactive.
However, there are PCIe devices that demand ATS to be always on. For these devices, their STEs have to use the mode 1 as HW ignores EATS with mode 2.
Change the driver accordingly:
- always use the mode 1
- never downgrade to mode 2
- allocate and retain a CD table (see note below)
Note that these devices might not support PASID, i.e. doing non-PASID ATS. In such a case, the ssid_bits is set to 0. However, s1cdmax must be set to a !0 value in order to keep the S1DSS field effective. Thus, when a master requires ats_always_on, set its s1cdmax to minimal 1, meaning the CD table will have a dummy entry (SSID=1) that will be never used.
Now, for these device, arm_smmu_cdtab_allocated() will always return true, v.s. false prior to this change. When its default substream is attached to an IDENTITY domain, its first CD is NULL in the table, which is a totally valid case. Thus, add "!master->ats_always_on" to the condition.
--- drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.h | 1 + drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c | 73 ++++++++++++++++++--- 2 files changed, 66 insertions(+), 8 deletions(-)
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.h +1 -0
@@ -848,6 +848,7 @@ struct arm_smmu_master { bool ats_enabled : 1; bool ste_ats_enabled : 1;bool stall_enabled; +bool ats_always_on;unsigned int ssid_bits;unsigned int iopf_refcount; };
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c +65 -8
120 lines not on this page · raw message
Signature · 1 line
2.43.0
Re: [PATCH v2 3/3] iommu/arm-smmu-v3: Allow ATS to be always on
Quoted 26 lines · On Mon, 23 Feb 2026 14:52:22 -0800 Nicolin Chen <[email protected]> wrote:
When a device's default substream attaches to an identity domain, the SMMU driver currently sets the device's STE between two modes:
Mode 1: Cfg=Translate, S1DSS=Bypass, EATS=1
Mode 2: Cfg=bypass (EATS is ignored by HW)When there is an active PASID (non-default substream), mode 1 is used. And when there is no PASID support or no active PASID, mode 2 is used.
The driver will also downgrade an STE from mode 1 to mode 2, when the last active substream becomes inactive.
However, there are PCIe devices that demand ATS to be always on. For these devices, their STEs have to use the mode 1 as HW ignores EATS with mode 2.
Change the driver accordingly:
- always use the mode 1
- never downgrade to mode 2
- allocate and retain a CD table (see note below)Note that these devices might not support PASID, i.e. doing non-PASID ATS. In such a case, the
ssid_bitsis set to 0. However, s1cdmax must be set to a !0 value in order to keep the S1DSS field effective. Thus, when a master requiresats_always_on, set its s1cdmax to minimal 1, meaning the CD table will have a dummy entry (SSID=1) that will be never used.
Quoted 6 lines
Now, for these device,
arm_smmu_cdtab_allocated()will always return true, v.s. false prior to this change. When its default substream is attached to an IDENTITY domain, its first CD is NULL in the table, which is a totally valid case. Thus, add "!master->ats_always_on" to the condition.Signed-off-by Nicolin Chen <[email protected]>
In my head at least, it would be nice if a driver had to explicitly opt in to this behavior. The presence of CXL.cache support for instance doesn't actually mean the driver is going to enable it. However it is probably harmless so lets go with this as path of least resistance.
One trivial thing inline (ignore if you like!) Otherwise LGTM
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c static void arm_smmu_attach_dev_ste(struct iommu_domain *domain, · line 3300
Quoted 13 lines
drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c +3
-0@@ -3274,7 +3294,10 @@ static void arm_smmu_attach_dev_ste(struct iommu_domain *domain, .old_domain = old_domain, .ssid = IOMMU_NO_PASID, }; +bool ats_always_on = false; +if (master->ats_always_on && s1dss !=STRTAB_STE_1_S1DSS_TERMINATE ) + ats_always_on = true;
Maybe flatten this to not do the off then on dance.
bool ats_always_on = master->ats_always_on && s1dss != STRTAB_STE_1_S1DSS_TERMINATE;
Re: [PATCH v2 3/3] iommu/arm-smmu-v3: Allow ATS to be always on
Quoted 4 lines · Jonathan Cameron
In my head at least, it would be nice if a driver had to explicitly opt in to this behavior. The presence of CXL.cache support for instance doesn't actually mean the driver is going to enable it. However it is probably harmless so lets go with this as path of least resistance.
That same remark applies to ATS in general, we have no idea if the device is going to use it when turned on or not..
Generally Linux has taken the approach of almost always enabling ATS if the device offers the PCIe capability.
The purpose of this series is to close of the few "almost" cases so it is always on.
Jason
Re: [PATCH v2 3/3] iommu/arm-smmu-v3: Allow ATS to be always on
Quoted 9 lines · On Tue, 24 Feb 2026 10:51:02 -0400 Jason Gunthorpe <[email protected]> wrote:
Quoted 4 lines · Jonathan Cameron
In my head at least, it would be nice if a driver had to explicitly opt in to this behavior. The presence of CXL.cache support for instance doesn't actually mean the driver is going to enable it. However it is probably harmless so lets go with this as path of least resistance.
That same remark applies to ATS in general, we have no idea if the device is going to use it when turned on or not..
Yup. Understood. That's the bit that smells bad to me.
Quoted 6 lines
Generally Linux has taken the approach of almost always enabling ATS if the device offers the PCIe capability.
The purpose of this series is to close of the few "almost" cases so it is always on.
Absolutely understood. I just took the opportunity to moan!
J
Quoted 3 lines
Jason
Re: [PATCH v2 3/3] iommu/arm-smmu-v3: Allow ATS to be always on
Quoted 10 lines · Jonathan Cameron
Quoted 7 lines · On Tue, 24 Feb 2026 10:51:02 -0400 Jason Gunthorpe <[email protected]> wrote:
Quoted 4 lines · Jonathan Cameron
In my head at least, it would be nice if a driver had to explicitly opt in to this behavior. The presence of CXL.cache support for instance doesn't actually mean the driver is going to enable it. However it is probably harmless so lets go with this as path of least resistance.
Quoted 4 lines
Quoted 2 lines
That same remark applies to ATS in general, we have no idea if the device is going to use it when turned on or not..
Yup. Understood. That's the bit that smells bad to me.
Do you have thoughts on when this is a problem (aside from device pre-acceptance security already discussed)? So far I haven't heard complaining on this point..
Jason
Re: [PATCH v2 3/3] iommu/arm-smmu-v3: Allow ATS to be always on
Quoted 11 lines · On Tue, 24 Feb 2026 12:09:47 -0400 Jason Gunthorpe <[email protected]> wrote:
Quoted 10 lines · Jonathan Cameron
Quoted 7 lines · On Tue, 24 Feb 2026 10:51:02 -0400 Jason Gunthorpe <[email protected]> wrote:
Quoted 4 lines · Jonathan Cameron
In my head at least, it would be nice if a driver had to explicitly opt in to this behavior. The presence of CXL.cache support for instance doesn't actually mean the driver is going to enable it. However it is probably harmless so lets go with this as path of least resistance.
Quoted 8 lines
Quoted 4 lines
Quoted 2 lines
That same remark applies to ATS in general, we have no idea if the device is going to use it when turned on or not..
Yup. Understood. That's the bit that smells bad to me.
Do you have thoughts on when this is a problem (aside from device pre-acceptance security already discussed)? So far I haven't heard complaining on this point..
Nothing explicit. It was a very minor smells wrong moan on basis of assumptions of what an IOMMU is doing in the way of ATS checking if we have a malicious device. So principle of not turning anything on we don't know we need.
Jonathan
Quoted 3 lines
Jason