|
| From: | Yi Liu |
| Subject: | Re: [PATCH v2 16/17] intel_iommu: Introduce a property to control FS1GP cap bit setting |
| Date: | Mon, 19 Aug 2024 17:30:03 +0800 |
| User-agent: | Mozilla Thunderbird |
On 2024/8/15 11:46, Duan, Zhenzhong wrote:
-----Original Message----- From: Liu, Yi L <yi.l.liu@intel.com> Subject: Re: [PATCH v2 16/17] intel_iommu: Introduce a property to control FS1GP cap bit setting On 2024/8/5 14:27, Zhenzhong Duan wrote:When host IOMMU doesn't support FS1GP but vIOMMU does, hostIOMMUcan't translate stage-1 page table from guest correctly.this series is for emulated devices, so the above statement does not belong to this series. Is there any other reason to have this option?Good catch, will remove this comment. In fact, this patch is mainly for passthrough device where host IOMMU doesn't support fs1gp.
I see. To me, as long as the vIOMMU page walk logic supports 1GP large pages, it's ok to report the FS1GP cap to VM. But it is still fine to have this property to opt-out FS1GP if admin/orchestration layer(e.g. libvirt) knows no hw iommu has this capability, so it is better to opt out it before invoking QEMU. Is this your motivation for this property?
Add a property x-cap-fs1gp for user to turn FS1GP off so that nested page table on host side works.I guess you would need to sync the FS1GP cap with host before reporting it in vIOMMU when comes to support passthrough devices.Yes, we already have this check, see https://github.com/yiliu1765/qemu/commit/b7ac7ce3a2e21eb1b3172743ee6f73e80fe67b3a
good to know it. :) Will you fail the VM if the device's iommu does not support FS1GP or just mask out the FS1GP? -- Regards, Yi Liu
| [Prev in Thread] | Current Thread | [Next in Thread] |