All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1] intel_iommu: Expose SMPWC when SVM is enabled
@ 2026-08-02 16:05 Clément MATHIEU--DRIF
  2026-08-02 16:47 ` Michael S. Tsirkin
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Clément MATHIEU--DRIF @ 2026-08-02 16:05 UTC (permalink / raw)
  To: qemu-devel@nongnu.org
  Cc: pbonzini@redhat.com, peterx@redhat.com, mst@redhat.com,
	jasowangio@gmail.com, zhenzhong.duan@intel.com,
	kevin.tian@intel.com, yi.l.liu@intel.com,
	baolu.lu@linux.intel.com, Clément MATHIEU--DRIF

SVM in Linux requires SMPWC as of 780dfed68862. This is free in the
current implementation as it is already in line with the expected
behaviour.

Signed-off-by: Clement Mathieu--Drif <clement.mathieu--drif@bull.com>
---
 hw/i386/intel_iommu.c          | 3 ++-
 hw/i386/intel_iommu_internal.h | 1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c
index 8245452d89..9f21622a4f 100644
--- a/hw/i386/intel_iommu.c
+++ b/hw/i386/intel_iommu.c
@@ -5108,7 +5108,8 @@ static void vtd_init(IntelIOMMUState *s)
     }
 
     if (s->svm) {
-        s->ecap |= VTD_ECAP_PRS | VTD_ECAP_PDS | VTD_ECAP_NWFS;
+        s->ecap |= VTD_ECAP_PRS | VTD_ECAP_PDS | VTD_ECAP_NWFS |
+                   VTD_ECAP_SMPWCS;
     }
 
     vtd_reset_caches(s);
diff --git a/hw/i386/intel_iommu_internal.h b/hw/i386/intel_iommu_internal.h
index 924e91cb8a..df7a0efa6e 100644
--- a/hw/i386/intel_iommu_internal.h
+++ b/hw/i386/intel_iommu_internal.h
@@ -202,6 +202,7 @@
 #define VTD_ECAP_SMTS               (1ULL << 43)
 #define VTD_ECAP_SSTS               (1ULL << 46)
 #define VTD_ECAP_FSTS               (1ULL << 47)
+#define VTD_ECAP_SMPWCS             (1ULL << 48)
 
 /* CAP_REG */
 /* (offset >> 4) << 24 */
-- 
2.54.0


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

end of thread, other threads:[~2026-08-04 11:12 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-02 16:05 [PATCH v1] intel_iommu: Expose SMPWC when SVM is enabled Clément MATHIEU--DRIF
2026-08-02 16:47 ` Michael S. Tsirkin
2026-08-04  8:51   ` Yi Liu
2026-08-04 11:09     ` Clément MATHIEU--DRIF
2026-08-02 18:53 ` Michael S. Tsirkin
2026-08-03  5:40   ` Clément MATHIEU--DRIF
2026-08-03  6:05     ` Michael S. Tsirkin
2026-08-03  7:26 ` Duan, Zhenzhong
2026-08-04  8:39   ` Yi Liu
2026-08-04 11:12     ` Clément MATHIEU--DRIF
2026-08-04  8:48 ` Yi Liu
2026-08-04 11:11   ` Clément MATHIEU--DRIF

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.