RE: [PATCH v3 04/10] iommu/vt-d: Add helper to setup pasid nested translation

From: Liu, Yi L
Date: Wed Jun 07 2023 - 23:36:26 EST


> From: Baolu Lu <baolu.lu@xxxxxxxxxxxxxxx>
> Sent: Friday, May 26, 2023 12:16 PM
> On 5/24/23 3:16 PM, Tian, Kevin wrote:
> >> From: Yi Liu <yi.l.liu@xxxxxxxxx>
> >> Sent: Thursday, May 11, 2023 10:51 PM
> >>
> >> + /*
> >> + * Memory type is only applicable to devices inside processor
> >> coherent
> >> + * domain. Will add MTS support once coherent devices are available.
> >> + */
> >> + if (s1_cfg->flags & IOMMU_VTD_PGTBL_MTS_MASK) {
> >> + pr_warn_ratelimited("No memory type support %s\n",
> >> + iommu->name);
> >> + return -EINVAL;
> >> + }
> >
> > If it's unsupported why exposing them in the uAPI at this point?
>
> Agreed. We can remove this flag for now.

So we shall remove the below flags in uapi as well, is it?

+#define IOMMU_VTD_PGTBL_MTS_MASK (IOMMU_VTD_PGTBL_CD | \
+ IOMMU_VTD_PGTBL_EMTE | \
+ IOMMU_VTD_PGTBL_PCD | \
+ IOMMU_VTD_PGTBL_PWT)

Regards,
Yi Liu