mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-12-24 00:18:36 -07:00
vfio/iommufd: Add comment emphasizing no movement of hiod->realize() call
The nested IOMMU support needs device and hwpt id which are generated only after attachment. Hiod encapsulates these information in realize() and passes to vIOMMU. Suggested-by: Cédric Le Goater <clg@redhat.com> Signed-off-by: Zhenzhong Duan <zhenzhong.duan@intel.com> Reviewed-by: Cédric Le Goater <clg@redhat.com> Link: https://lore.kernel.org/qemu-devel/20250521110301.3313877-1-zhenzhong.duan@intel.com Signed-off-by: Cédric Le Goater <clg@redhat.com>
This commit is contained in:
parent
a483ad5347
commit
1c729ca886
1 changed files with 4 additions and 0 deletions
|
|
@ -592,6 +592,10 @@ found_container:
|
|||
goto err_listener_register;
|
||||
}
|
||||
|
||||
/*
|
||||
* Do not move this code before attachment! The nested IOMMU support
|
||||
* needs device and hwpt id which are generated only after attachment.
|
||||
*/
|
||||
if (!vfio_device_hiod_create_and_realize(vbasedev,
|
||||
TYPE_HOST_IOMMU_DEVICE_IOMMUFD_VFIO, errp)) {
|
||||
goto err_listener_register;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue