Laszlo Ersek 8570de6e76 launch-libvirt: add virtio-net via the standard <interface> element
Starting with version 3.8.0, libvirt allows us to specify the network
address and network mask (as prefix) for SLIRP directly via the
<interface> element in the domain XML:
<https://libvirt.org/formatdomain.html#userspace-slirp-stack>. This means
we don't need the <qemu:commandline> hack for virtio-net on such versions.

Restrict the hack in construct_libvirt_xml_qemu_cmdline() to
libvirt<3.8.0, and generate the proper <interface> element in
construct_libvirt_xml_devices() on libvirt>=3.8.0.

Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2034160
Suggested-by: Richard W.M. Jones <rjones@redhat.com>
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Message-Id: <20211223103701.12702-4-lersek@redhat.com>
Reviewed-by: Richard W.M. Jones <rjones@redhat.com>
Tested-by: Richard W.M. Jones <rjones@redhat.com>
(cherry picked from commit 5858c2cf6c)
2021-12-24 12:11:27 +00:00
2021-01-05 15:53:51 +00:00
2020-03-06 19:32:32 +00:00
2020-03-06 19:32:32 +00:00
2020-11-02 10:13:22 +00:00
2021-01-05 10:32:20 +00:00
2020-03-06 19:32:32 +00:00
2011-11-08 14:43:07 +00:00
2021-10-14 12:01:33 +01:00
2020-03-06 19:32:32 +00:00
2020-03-06 19:32:32 +00:00
2021-01-06 10:18:34 +00:00
2018-02-22 15:06:13 +00:00
2020-03-06 19:32:32 +00:00
2021-01-06 10:18:34 +00:00
2013-01-24 15:00:49 +00:00
2019-11-28 13:09:21 +01:00
2021-01-06 10:18:34 +00:00
2020-01-14 16:21:22 +01:00
2021-01-06 10:18:34 +00:00
2019-11-13 12:49:55 +00:00
2020-03-06 19:32:32 +00:00
2021-01-06 10:18:34 +00:00
2020-10-06 15:26:14 +01:00
2020-03-06 19:32:32 +00:00

Libguestfs is tools and a library for accessing and modifying guest
disk images.  For more information see the home page:

  http://libguestfs.org/

For discussion, development, patches, etc. please use the mailing
list:

  http://www.redhat.com/mailman/listinfo/libguestfs

To find out how to build libguestfs from source, read:

  docs/guestfs-building.pod
  http://libguestfs.org/guestfs-building.1.html
  man docs/guestfs-building.1

Copyright (C) 2009-2020 Red Hat Inc.

The library is distributed under the LGPLv2+.  The programs are
distributed under the GPLv2+.  Please see the files COPYING and
COPYING.LIB for full license information.  The examples are under a
very liberal license.
Languages
C 42.7%
OCaml 35.5%
Shell 7.1%
Makefile 4%
Perl 2.6%
Other 8%