Hi Jean, On 12/10/19 5:50 PM, Jean-Philippe Brucker wrote: > On Fri, Nov 22, 2019 at 07:29:41PM +0100, Eric Auger wrote: >> +static const VMStateDescription vmstate_virtio_iommu_device = { >> + .name = "virtio-iommu-device", >> + .minimum_version_id = 1, >> + .version_id = 1, >> + .post_load = iommu_post_load, >> + .fields = (VMStateField[]) { >> + VMSTATE_GTREE_DIRECT_KEY_V(domains, VirtIOIOMMU, 1, >> + &vmstate_domain, viommu_domain), >> + VMSTATE_GTREE_DIRECT_KEY_V(endpoints, VirtIOIOMMU, 1, >> + &vmstate_endpoint, viommu_endpoint), > > So if I understand correctly these fields are state that is modified by > the guest? We don't need to save/load fields that cannot be modified by > the guest, static information that is created from the QEMU command-line.
Yes that's correct. > > I think the above covers everything we need to migrate in VirtIOIOMMU > then, except for acked_features, which (as I pointed out on another patch) > seems redundant anyway since there is vdev->guest_features. you're right, acked features were not properly migrated. > > Reviewed-by: Jean-Philippe Brucker <jean-phili...@linaro.org> Thanks! Eric > >> + VMSTATE_END_OF_LIST() >> + }, >> +}; >> + >> + >> static const VMStateDescription vmstate_virtio_iommu = { >> .name = "virtio-iommu", >> .minimum_version_id = 1, >> -- >> 2.20.1 >> >> >