Re: [PATCH 1/1] qemuDomainChangeNet: check virtio options for non-virtio models

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 7/4/24 17:44, Miroslav Los via Devel wrote:
> In a domain created with an interface with a <driver> subelement,
> the device contains a non-NULL virDomainVirtioOptions struct, even
> for non-virtio NIC models. The subelement need not be present again
> after libvirt restarts, or when the interface is passed to clients.
> 
> When clients such as virsh domif-setlink put back the modified
> interface XML, the new device's virtio attribute is NULL. This may
> fail the equality checks for virtio options in qemuDomainChangeNet,
> depending on whether libvird was restarted since define or not.
> 
> This patch modifies the check for non-virtio models, to ignore olddev
> value of virtio (assumed valid), and to allow either NULL or a struct
> with all values ABSENT in the new virtio options.
> 
> Signed-off-by: Miroslav Los <mirlos@xxxxxxxxx>
> ---
>  src/qemu/qemu_hotplug.c | 23 ++++++++++++++++-------
>  1 file changed, 16 insertions(+), 7 deletions(-)

Reviewed-by: Michal Privoznik <mprivozn@xxxxxxxxxx>

and merged. Congratulations on your first libvirt contribution!

Michal



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux