All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] iommu: restrict scratch page quarantining to x86
@ 2025-07-24 17:43 Stewart Hildebrand
  2025-07-24 18:39 ` Stefano Stabellini
  2025-07-25  8:01 ` Roger Pau Monné
  0 siblings, 2 replies; 4+ messages in thread
From: Stewart Hildebrand @ 2025-07-24 17:43 UTC (permalink / raw)
  To: xen-devel
  Cc: Stewart Hildebrand, Stefano Stabellini, Julien Grall,
	Bertrand Marquis, Michal Orzel, Jan Beulich, Roger Pau Monné

All IOMMU_QUARANTINE_* options are exposed on Arm since 163c6b589879
("xen/arm: pci: introduce PCI_PASSTHROUGH Kconfig option"). However,
only NONE and BASIC are implemented in any Arm iommu driver since
63919fc4d1ca ("xen/arm: smmuv3: Add PCI devices support for SMMUv3") and
ca8f6ffeb6e3 ("xen/arm: smmuv2: Add PCI devices support for SMMUv2").
SCRATCH_PAGE is not yet implemented in any Arm iommu driver. Restrict
scratch page quarantining to x86 for now.

Reported-by: Jan Beulich <jbeulich@suse.com>
Signed-off-by: Stewart Hildebrand <stewart.hildebrand@amd.com>
---
Cc'ing Arm maintainers to request an Arm ack.
---
 xen/drivers/passthrough/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/xen/drivers/passthrough/Kconfig b/xen/drivers/passthrough/Kconfig
index 78edd805365e..11aece5f7bda 100644
--- a/xen/drivers/passthrough/Kconfig
+++ b/xen/drivers/passthrough/Kconfig
@@ -90,4 +90,5 @@ choice
 		bool "basic"
 	config IOMMU_QUARANTINE_SCRATCH_PAGE
 		bool "scratch page"
+		depends on X86
 endchoice

base-commit: 150b773a484c911e2926f65adb576e1cdf9de7cf
-- 
2.50.1



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] iommu: restrict scratch page quarantining to x86
  2025-07-24 17:43 [PATCH] iommu: restrict scratch page quarantining to x86 Stewart Hildebrand
@ 2025-07-24 18:39 ` Stefano Stabellini
  2025-07-25  8:01 ` Roger Pau Monné
  1 sibling, 0 replies; 4+ messages in thread
From: Stefano Stabellini @ 2025-07-24 18:39 UTC (permalink / raw)
  To: Stewart Hildebrand
  Cc: xen-devel, Stefano Stabellini, Julien Grall, Bertrand Marquis,
	Michal Orzel, Jan Beulich, Roger Pau Monné

On Thu, 24 Jul 2025, Stewart Hildebrand wrote:
> All IOMMU_QUARANTINE_* options are exposed on Arm since 163c6b589879
> ("xen/arm: pci: introduce PCI_PASSTHROUGH Kconfig option"). However,
> only NONE and BASIC are implemented in any Arm iommu driver since
> 63919fc4d1ca ("xen/arm: smmuv3: Add PCI devices support for SMMUv3") and
> ca8f6ffeb6e3 ("xen/arm: smmuv2: Add PCI devices support for SMMUv2").
> SCRATCH_PAGE is not yet implemented in any Arm iommu driver. Restrict
> scratch page quarantining to x86 for now.
> 
> Reported-by: Jan Beulich <jbeulich@suse.com>
> Signed-off-by: Stewart Hildebrand <stewart.hildebrand@amd.com>

Acked-by: Stefano Stabellini <sstabellini@kernel.org>


> ---
> Cc'ing Arm maintainers to request an Arm ack.
> ---
>  xen/drivers/passthrough/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/xen/drivers/passthrough/Kconfig b/xen/drivers/passthrough/Kconfig
> index 78edd805365e..11aece5f7bda 100644
> --- a/xen/drivers/passthrough/Kconfig
> +++ b/xen/drivers/passthrough/Kconfig
> @@ -90,4 +90,5 @@ choice
>  		bool "basic"
>  	config IOMMU_QUARANTINE_SCRATCH_PAGE
>  		bool "scratch page"
> +		depends on X86
>  endchoice
> 
> base-commit: 150b773a484c911e2926f65adb576e1cdf9de7cf
> -- 
> 2.50.1
> 


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] iommu: restrict scratch page quarantining to x86
  2025-07-24 17:43 [PATCH] iommu: restrict scratch page quarantining to x86 Stewart Hildebrand
  2025-07-24 18:39 ` Stefano Stabellini
@ 2025-07-25  8:01 ` Roger Pau Monné
  2025-07-25 15:58   ` Stewart Hildebrand
  1 sibling, 1 reply; 4+ messages in thread
From: Roger Pau Monné @ 2025-07-25  8:01 UTC (permalink / raw)
  To: Stewart Hildebrand
  Cc: xen-devel, Stefano Stabellini, Julien Grall, Bertrand Marquis,
	Michal Orzel, Jan Beulich

On Thu, Jul 24, 2025 at 01:43:48PM -0400, Stewart Hildebrand wrote:
> All IOMMU_QUARANTINE_* options are exposed on Arm since 163c6b589879
> ("xen/arm: pci: introduce PCI_PASSTHROUGH Kconfig option"). However,
> only NONE and BASIC are implemented in any Arm iommu driver since
> 63919fc4d1ca ("xen/arm: smmuv3: Add PCI devices support for SMMUv3") and
> ca8f6ffeb6e3 ("xen/arm: smmuv2: Add PCI devices support for SMMUv2").
> SCRATCH_PAGE is not yet implemented in any Arm iommu driver. Restrict
> scratch page quarantining to x86 for now.
> 
> Reported-by: Jan Beulich <jbeulich@suse.com>
> Signed-off-by: Stewart Hildebrand <stewart.hildebrand@amd.com>
> ---
> Cc'ing Arm maintainers to request an Arm ack.
> ---
>  xen/drivers/passthrough/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/xen/drivers/passthrough/Kconfig b/xen/drivers/passthrough/Kconfig
> index 78edd805365e..11aece5f7bda 100644
> --- a/xen/drivers/passthrough/Kconfig
> +++ b/xen/drivers/passthrough/Kconfig
> @@ -90,4 +90,5 @@ choice
>  		bool "basic"
>  	config IOMMU_QUARANTINE_SCRATCH_PAGE
>  		bool "scratch page"
> +		depends on X86

Since this is tied to specific IOMMU implementations, could you please
tie it to AMD_IOMMU and INTEL_IOMMU instead of X86?

depends on AMD_IOMMU || INTEL_IOMMU

Should do it I think?

Thanks, Roger.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] iommu: restrict scratch page quarantining to x86
  2025-07-25  8:01 ` Roger Pau Monné
@ 2025-07-25 15:58   ` Stewart Hildebrand
  0 siblings, 0 replies; 4+ messages in thread
From: Stewart Hildebrand @ 2025-07-25 15:58 UTC (permalink / raw)
  To: Roger Pau Monné
  Cc: xen-devel, Stefano Stabellini, Julien Grall, Bertrand Marquis,
	Michal Orzel, Jan Beulich

On 7/25/25 04:01, Roger Pau Monné wrote:
> On Thu, Jul 24, 2025 at 01:43:48PM -0400, Stewart Hildebrand wrote:
>> All IOMMU_QUARANTINE_* options are exposed on Arm since 163c6b589879
>> ("xen/arm: pci: introduce PCI_PASSTHROUGH Kconfig option"). However,
>> only NONE and BASIC are implemented in any Arm iommu driver since
>> 63919fc4d1ca ("xen/arm: smmuv3: Add PCI devices support for SMMUv3") and
>> ca8f6ffeb6e3 ("xen/arm: smmuv2: Add PCI devices support for SMMUv2").
>> SCRATCH_PAGE is not yet implemented in any Arm iommu driver. Restrict
>> scratch page quarantining to x86 for now.
>>
>> Reported-by: Jan Beulich <jbeulich@suse.com>
>> Signed-off-by: Stewart Hildebrand <stewart.hildebrand@amd.com>
>> ---
>> Cc'ing Arm maintainers to request an Arm ack.
>> ---
>>  xen/drivers/passthrough/Kconfig | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/xen/drivers/passthrough/Kconfig b/xen/drivers/passthrough/Kconfig
>> index 78edd805365e..11aece5f7bda 100644
>> --- a/xen/drivers/passthrough/Kconfig
>> +++ b/xen/drivers/passthrough/Kconfig
>> @@ -90,4 +90,5 @@ choice
>>  		bool "basic"
>>  	config IOMMU_QUARANTINE_SCRATCH_PAGE
>>  		bool "scratch page"
>> +		depends on X86
> 
> Since this is tied to specific IOMMU implementations, could you please
> tie it to AMD_IOMMU and INTEL_IOMMU instead of X86?
> 
> depends on AMD_IOMMU || INTEL_IOMMU
> 
> Should do it I think?

Yes, that makes sense. Since the version with X86 was already committed,
I'll send the modification with a Fixes: tag.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2025-07-25 15:58 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-24 17:43 [PATCH] iommu: restrict scratch page quarantining to x86 Stewart Hildebrand
2025-07-24 18:39 ` Stefano Stabellini
2025-07-25  8:01 ` Roger Pau Monné
2025-07-25 15:58   ` Stewart Hildebrand

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.