]> git.ipfire.org Git - thirdparty/libvirt.git/log
thirdparty/libvirt.git
4 years agodocs: glib-adoption: add string arrays and objects
Ján Tomko [Thu, 24 Sep 2020 12:15:52 +0000 (14:15 +0200)] 
docs: glib-adoption: add string arrays and objects

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agodocs: glib-adoption: add links to GLib documentation
Ján Tomko [Thu, 24 Sep 2020 12:07:20 +0000 (14:07 +0200)] 
docs: glib-adoption: add links to GLib documentation

Make life a bit easier for people unfamiliar with GLib.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agodocs: glib-adoption: split into sections
Ján Tomko [Thu, 24 Sep 2020 11:50:49 +0000 (13:50 +0200)] 
docs: glib-adoption: split into sections

Although all the mentioned functions deal with
allocation, replacing the pure allocation
functions is easier than converting code to
use GArrays.

Split them out to encourage usage of GLib
allocation APIs even at the cost of them
being combined with VIR_*ELEMENT APIs.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agodocs: glib-adoption: remove stuff we alredy removed
Ján Tomko [Thu, 24 Sep 2020 11:22:46 +0000 (13:22 +0200)] 
docs: glib-adoption: remove stuff we alredy removed

https://www.redhat.com/archives/libvir-list/2020-May/msg00299.html

Suggested-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agodocs: build glib-adoption.html
Ján Tomko [Thu, 24 Sep 2020 12:22:17 +0000 (14:22 +0200)] 
docs: build glib-adoption.html

We switched to meson in the meantime so the conversion
to HTML has to be explicitly requested.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agoRevert "docs: Drop glib-adoption.rst"
Ján Tomko [Thu, 24 Sep 2020 07:11:17 +0000 (09:11 +0200)] 
Revert "docs: Drop glib-adoption.rst"

Cleaning up after Andrea as he requested:
https://www.redhat.com/archives/libvir-list/2020-May/msg00405.html

This reverts commit 842d3712ed612f213b454e610cc7ff9db2321803

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agoRevert "Also look for dmi information in /sys/class"
Ján Tomko [Wed, 30 Sep 2020 16:44:53 +0000 (18:44 +0200)] 
Revert "Also look for dmi information in /sys/class"

Assume nobody runs current libvirt on kernels such as 2.6.26.

Kernel commit 9f9c9cbb60576a1518d0bf93fb8e499cffccf377 (released
in 3.8) mentions the new path and I believe it was added by:
commit 948af1f0bbc8526448e8cbe3f8d3bf211bdf5181
    firmware: Basic dmi-sysfs support
(released in 2.6.39), but I cannot figure out how all that
kernel automagic works.

This reverts commit 4c81b0fdc57b23d80b1b4752cd6143d15c02e9c8

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovmx; Free @checkMACAddress in virVMXParseEthernet()
Michal Privoznik [Fri, 2 Oct 2020 08:39:58 +0000 (10:39 +0200)] 
vmx; Free @checkMACAddress in virVMXParseEthernet()

The @checkMACAddress string is allocated in
virVMXGetConfigString() but never freed.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
4 years agovirfirewalltest: Don't duplicate string when adding it onto stringlist
Michal Privoznik [Fri, 2 Oct 2020 08:37:26 +0000 (10:37 +0200)] 
virfirewalltest: Don't duplicate string when adding it onto stringlist

In our wrapper of g_dbus_connection_call_sync() in
virfirewalltest a string is duplicated and added onto a
virStringList. This leads to a memory leak because
virStringListAdd() duplicates the string itself.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
4 years agotests: Set G_DEBUG environment variable
Michal Privoznik [Fri, 2 Oct 2020 08:34:11 +0000 (10:34 +0200)] 
tests: Set G_DEBUG environment variable

With us switching to glib more and more it is easy to get things
wrong (as can be seen in the previous commit). Set G_DEBUG
variable to "fatal-warnings" which causes GLib to abort the
program at the first call to g_warning() or g_critical().

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
4 years agotests: fix incorrect free of GVariant in our GLib mock functions
Pavel Hrdina [Fri, 2 Oct 2020 10:11:45 +0000 (12:11 +0200)] 
tests: fix incorrect free of GVariant in our GLib mock functions

GLib implementation of g_dbus_connection_call_sync() calls
g_variant_ref_sink() on the passed @parameters to make sure they have
proper reference. If the original reference is floating the
g_dbus_connection_call_sync() consumes it, but if it's normal reference
it will just add another one.

Our mock functions were only freeing the @parameters which is incorrect
and doesn't reflect how the real implementation works.

Reported-by: Cole Robinson <crobinso@redhat.com>
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agobuild: remove old macvtap and virtualport leftovers
Pino Toscano [Fri, 2 Oct 2020 05:15:18 +0000 (07:15 +0200)] 
build: remove old macvtap and virtualport leftovers

Followup of commit a79e7639daffac04b088378e6c79854fcac292f3 and
commit 7556ab139fd2e503ac26ee232ab273f1ec027c21

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agoNEWS: Mention <transient/> disk support for qemu
Peter Krempa [Thu, 24 Sep 2020 11:32:37 +0000 (13:32 +0200)] 
NEWS: Mention <transient/> disk support for qemu

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agologging: fix endless loop on EOF
Nikolay Shirokovskiy [Thu, 24 Sep 2020 12:54:24 +0000 (15:54 +0300)] 
logging: fix endless loop on EOF

On EOF condition we always have POLLHUP event and read returns
0 thus we never break loop in virLogHandlerDomainLogFileDrain.

Signed-off-by: Nikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agologging: read all bytes on EOF in event handler
Nikolay Shirokovskiy [Thu, 24 Sep 2020 12:47:09 +0000 (15:47 +0300)] 
logging: read all bytes on EOF in event handler

If writing side writes enough bytes to the pipe and closes writing
end then we got both VIR_EVENT_HANDLE_HANGUP and VIR_EVENT_HANDLE_READ
in handler. Currently in this situation handler reads 1024 bytes
and finish reading leaving unread data in pipe.

Signed-off-by: Nikolay Shirokovskiy <nshirokovskiy@virtuozzo.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agobuild: remove duplicate check for GET_VLAN_VID_CMD
Laine Stump [Wed, 30 Sep 2020 22:51:45 +0000 (18:51 -0400)] 
build: remove duplicate check for GET_VLAN_VID_CMD

Somehow this check was duplicated just below the original.

(I was at first skeptical that it's needed at all, since
GET_VLAN_VID_CMD was already present in kernel 2.6.32, but then I
realized that there is no higher level check for __linux__ around the
code that is conditional on WITH_DECL_GET_VLAN_VID_CMD; it only checks
for SIOCGIFVLAN and WITH_STRUCT_IFREQ - the latter is also present on
*BSD platforms, the former doesn't seem to be anywhere but Linux, but
I didn't want to change the effect of the conditional, so I left it in
(we could have also replaced WITH_DECL_GET_VLAN_VID_CMD, but possibly
there is a non-Linux platform that *does* have it...)

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoutil: provide non-netlink/libnl alternative for virNetDevGetMaster()
Laine Stump [Wed, 30 Sep 2020 21:56:00 +0000 (17:56 -0400)] 
util: provide non-netlink/libnl alternative for virNetDevGetMaster()

Lack of this one function (which is called for each active tap device
every time libvirtd is started) is the one thing preventing a
"WITHOUT_LIBNL" build of libvirt from being useful. With this
alternate implementation, guests using standard tap devices will work
properly even when libvirt is built without libnl support.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoutil: fix Linux build when libnl-devel isn't available
Laine Stump [Wed, 30 Sep 2020 20:36:52 +0000 (16:36 -0400)] 
util: fix Linux build when libnl-devel isn't available

There was one stray bit of code in virnetdev.c that required libnl to
build, but wasn't qualified by defined(WITH_LIBNL). Adding that, plus
putting a similar check around a static function only used by that
aforementioned code, makes libvirt build properly without libnl3-devel
installed.

How useful it is in that state is a separate issue :-)

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agobuild: eliminate WITH_MACVTAP flag entirely
Laine Stump [Tue, 29 Sep 2020 14:54:38 +0000 (10:54 -0400)] 
build: eliminate WITH_MACVTAP flag entirely

This flag was originally created to indicate that either 1) the build
platform wasn't linux, 2) the build platform was linux, but the kernel
was too old to have macvtap support. Since there was already a switch
there, the ability to also disable it when 3) the kernel supports
macvtap but the user doesn't want it, was added in. I don't think that
(3) was ever an intentional goal, just something that grew naturally
out of having the flag there in the first place (unless possibly the
original author wanted a way to quickly disable their new code in case
it caused regressions elsewhere).

Now that the check for (2) has been removed, WITH_MACVTAP is just
checking (1) and (3), but (3) is pointless (because the extra code in
libvirt itself is miniscule, and the only external library needed for
it is libnl, which is also required for other unrelated features (and
itself has no subordinate dependencies and takes up < 1MB on
disk)). We can therfore eliminate the WITH_MACVTAP flag, as it is
functionally equivalent to WITH_LIBNL (which implies __linux__).

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agobuild: simplify check for WITH_MACVTAP
Laine Stump [Tue, 29 Sep 2020 13:56:18 +0000 (09:56 -0400)] 
build: simplify check for WITH_MACVTAP

macvtap support was added to the Linux kernel in 2.6.33. libvirt
checked for this by looking for MACVLAN_MODE_BRIDGE and IFLA_VF_MAX in
linux/if_link.h. This hasn't been necessary for a very long time, so
just gate on platform == 'linux' (and be sure to complain if someone
tries to enable it on a non-Linux platform).

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agobuild: remove check for MACVLAN_MODE_PASSTHRU
Laine Stump [Tue, 29 Sep 2020 13:43:54 +0000 (09:43 -0400)] 
build: remove check for MACVLAN_MODE_PASSTHRU

macvlan support was added to the Linux kernel in 2.6.33, but
MACVLAN_MODE_PASSTHRU wasn't added until 2.6.38, so a workaround had
been put in place to define that constant on those few systems where
it was missing. It's useful like was probably 6 months at most, but
it's been there for over 10 years.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agobuild: eliminate useless WITH_VIRTUALPORT check
Laine Stump [Mon, 28 Sep 2020 21:39:46 +0000 (17:39 -0400)] 
build: eliminate useless WITH_VIRTUALPORT check

WITH_VIRTUALPORT just checks that we are building on Linux and that
IFLA_PORT_MAX is defined in linux/if_link.h. Back when 802.11Qb[gh]
support was added, the IFLA_* stuff was new (introduced in kernel
2.6.35, backported to RHEL6 2.6.32 kernel at some point), and so this
extra check was necessary, because libvirt was being built on Linux
distros that didn't yet have IFLA_* (e.g. older RHEL6, all
RHEL5). It's been in the kernel for a *very* long time now, so all
supported versions of all Linux platforms libvirt builds on have it.

Note that the above paragraph implies that the conditional compilation
should be changed to #if defined(__linux__). However, the astute
reader will notice that the code in question is sending and receiving
netlink messages, so it really should be conditional on WITH_LIBNL
(which implies __linux__) instead, so that's what this patch does.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoutil: remove extraneous defined(__linux__) when checking for WITH_LIBNL
Laine Stump [Mon, 28 Sep 2020 21:29:41 +0000 (17:29 -0400)] 
util: remove extraneous defined(__linux__) when checking for WITH_LIBNL

WITH_LIBNL will only be defined on Linux platforms (because libnl is a
library written to encapsulate parts of netlink, which is a Linux-only
API), so it's redundant to write:

  #if defined(__linux__) && defined(WITH_LIBNL)

We can just check for WITH_LIBNL.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoutil: remove useless checks for IFLA_VF_MAX
Laine Stump [Mon, 28 Sep 2020 19:53:48 +0000 (15:53 -0400)] 
util: remove useless checks for IFLA_VF_MAX

IFLA_VF_MAX was introduced to the Linux kernel in 2.6.35, and was even
backported to the RHEL*6* 2.6.32 kernel downstream, so it is present
in all supported versions of all Linux distros that libvirt builds
on. Additionally, it can't be conditionally compiled out of a
kernel. There is no reason to conditionalize any piece of code on
presence of IFLA_VF_MAX - if the platform is Linux, it is supported.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: use g_free() instead of VIR_FREE in virDomainNetDefFree()
Laine Stump [Sat, 26 Sep 2020 16:59:11 +0000 (12:59 -0400)] 
conf: use g_free() instead of VIR_FREE in virDomainNetDefFree()

All these lines were moved over from the now-defunct
virDomainNetDefClear(), which required all pointers to be cleared
after free, but virDomainNetDefFree() doesn't have that restriction -
after free'ing the pointers are never again referenced, so g_free() is
safe.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: eliminate virDomainNetDefClear()
Laine Stump [Wed, 23 Sep 2020 01:33:42 +0000 (21:33 -0400)] 
conf: eliminate virDomainNetDefClear()

This function is no longer used anywhere except virDomainNetDefFree(),
so just inline its contents there.

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemu: eliminate use of virDomainNetDefClear() in qemuConnectDomainXMLToNative()
Laine Stump [Wed, 23 Sep 2020 01:19:38 +0000 (21:19 -0400)] 
qemu: eliminate use of virDomainNetDefClear() in qemuConnectDomainXMLToNative()

Instead of saving the interesting pieces of each existing NetDef,
clearing it, and then copying back the saved pieces after setting the
type to ethernet, just create a new NetDef, copy in the interesting
bits, and replace the old one. (The end game is to eliminate
virDomainNetDefClear() completely, since this is the only real use)

Signed-off-by: Laine Stump <laine@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: introduce virDomainDefControllersParse
Ján Tomko [Tue, 28 Jul 2020 22:57:46 +0000 (00:57 +0200)] 
conf: introduce virDomainDefControllersParse

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: introduce virDomainDefClockParse
Ján Tomko [Tue, 28 Jul 2020 22:53:52 +0000 (00:53 +0200)] 
conf: introduce virDomainDefClockParse

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: introduce virDomainDefLifecycleParse
Ján Tomko [Tue, 28 Jul 2020 22:50:24 +0000 (00:50 +0200)] 
conf: introduce virDomainDefLifecycleParse

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: introduce virDomainDefTunablesParse
Ján Tomko [Tue, 28 Jul 2020 22:33:56 +0000 (00:33 +0200)] 
conf: introduce virDomainDefTunablesParse

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: split out virDomainDefParseMemory
Ján Tomko [Tue, 28 Jul 2020 22:25:17 +0000 (00:25 +0200)] 
conf: split out virDomainDefParseMemory

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoconf: split out virDomainDefParseIDs
Ján Tomko [Tue, 28 Jul 2020 22:18:27 +0000 (00:18 +0200)] 
conf: split out virDomainDefParseIDs

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agorpc: use g_new0 instead of VIR_ALLOC
Ján Tomko [Thu, 24 Sep 2020 18:58:46 +0000 (20:58 +0200)] 
rpc: use g_new0 instead of VIR_ALLOC

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agogendispatch: use g_new0 instead of VIR_ALLOC
Ján Tomko [Wed, 30 Sep 2020 13:40:06 +0000 (15:40 +0200)] 
gendispatch: use g_new0 instead of VIR_ALLOC

Take the easy way out and use typeof, because my life
is too short to spend it reading gendispatch.pl.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agologging: use g_new0 instead of VIR_ALLOC
Ján Tomko [Wed, 30 Sep 2020 12:58:44 +0000 (14:58 +0200)] 
logging: use g_new0 instead of VIR_ALLOC

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agolocking: prefer g_new0 to VIR_ALLOC
Ján Tomko [Tue, 29 Sep 2020 16:45:18 +0000 (18:45 +0200)] 
locking: prefer g_new0 to VIR_ALLOC

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agolibxl: prefer g_new0 to VIR_ALLOC
Ján Tomko [Wed, 23 Sep 2020 18:43:09 +0000 (20:43 +0200)] 
libxl: prefer g_new0 to VIR_ALLOC

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoutil: remove compile time tests for IFF_VNET_HDR/IFF_MULTI_QUEUE
Daniel P. Berrangé [Thu, 24 Sep 2020 11:12:37 +0000 (12:12 +0100)] 
util: remove compile time tests for IFF_VNET_HDR/IFF_MULTI_QUEUE

The former has been present since

  commit f43798c27684ab925adde7d8acc34c78c6e50df8
  Author: Rusty Russell <rusty@rustcorp.com.au>
  Date:   Thu Jul 3 03:48:02 2008 -0700

    tun: Allow GSO using virtio_net_hdr

and the latter since

  commit bbb009941efaece3898910a862f6d23aa55d6ba8
  Author: Jason Wang <jasowang@redhat.com>
  Date:   Wed Oct 31 19:45:59 2012 +0000

    tuntap: introduce multiqueue flags

these are old enough that they can be assumed present in all Linux
platforms we support. The tap device creation code changed is specific
to Linux, with a separate impl for non-Linux platforms.

Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agoqemuxml2xmloutdata: Make more symlinks
Michal Privoznik [Mon, 24 Aug 2020 17:14:52 +0000 (19:14 +0200)] 
qemuxml2xmloutdata: Make more symlinks

I've found two files under qemuxml2xmloutdata/ that are the same
as in qemuxml2argvdata/. Replace them with symlinks.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agostorage: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 18:41:28 +0000 (20:41 +0200)] 
storage: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agostorage: scsi: invert logic in createVport
Ján Tomko [Thu, 24 Sep 2020 18:55:24 +0000 (20:55 +0200)] 
storage: scsi: invert logic in createVport

Check whether the alloc result is negative (which is
cannot happen with current code) to reduce churn in
the following commit.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agosrc: libvirt-stream: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 18:43:49 +0000 (20:43 +0200)] 
src: libvirt-stream: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agointerface: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 18:44:23 +0000 (20:44 +0200)] 
interface: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agohyperv: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 18:44:11 +0000 (20:44 +0200)] 
hyperv: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agoesx: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 18:44:04 +0000 (20:44 +0200)] 
esx: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agobhyve: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 18:43:58 +0000 (20:43 +0200)] 
bhyve: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
4 years agotools: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 20:06:18 +0000 (22:06 +0200)] 
tools: use g_new0 instead of VIR_ALLOC*

With the exception of vsh*alloc.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agosecurity: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 20:05:21 +0000 (22:05 +0200)] 
security: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agosecret: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 20:05:04 +0000 (22:05 +0200)] 
secret: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agoopenvz: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 20:04:55 +0000 (22:04 +0200)] 
openvz: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agonode_device: use g_new0 instead of VIR_ALLOC*
Ján Tomko [Wed, 23 Sep 2020 20:04:41 +0000 (22:04 +0200)] 
node_device: use g_new0 instead of VIR_ALLOC*

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agovbox: StartMachine: overwrite ret less often
Ján Tomko [Wed, 23 Sep 2020 16:35:41 +0000 (18:35 +0200)] 
vbox: StartMachine: overwrite ret less often

Use goto to jump over the ret = 0 assignment
as is usual in rest of the code.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Martin Kletzander <mkletzan@redhat.com>
4 years agoqemu: Use memory-backend-* for regular guest memory
Michal Privoznik [Mon, 25 May 2020 11:56:45 +0000 (13:56 +0200)] 
qemu: Use memory-backend-* for regular guest memory

So far, Libvirt configures memory-backend-* for memory hotplug,
possibly NUMA nodes and in a few other cases. This patch
switches to constructing the memory-backend-* command line for
all cases. To keep ability to migrate guests a little hack is
used: the ID of the object is set to the one that QEMU uses
internally anyways. These IDs are stable (first started to appear
somewhere around v0.13.0-rc0~96) and can't change.

In fact, this patch does exactly what QEMU does internally. The
reason for moving the logic into Libvirt is that QEMU wants to
deprecate the old style of specifying memory.

So far, only x84_64 test cases are changed, because tests for
other architectures use older capabilities, which still lack the
QEMU_CAPS_MACHINE_MEMORY_BACKEND capability and they don't report
the RAM ID.

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1836043

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agoqemu: Track default-ram-id machine attribute
Michal Privoznik [Mon, 25 May 2020 17:13:43 +0000 (19:13 +0200)] 
qemu: Track default-ram-id machine attribute

The machine structure has another (optional) attribute:
default-ram-id, which specifies the alias of the default RAM
object. While the alias is private, it can never change in order
to not break migration. QEMU uses the alias when allocating
regular, not NUMA memory. In order to switch to new command line
and maintain migration, save this ID.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agoqemuBuildMemoryBackendProps: Fix const correctness
Michal Privoznik [Mon, 25 May 2020 13:00:17 +0000 (15:00 +0200)] 
qemuBuildMemoryBackendProps: Fix const correctness

The objects at @def and @mem pointers are only read and not
written. Make the arguments const to make that explicit.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agoqemuBuildMemoryBackendProps: Prealloc mem for memfd backend
Michal Privoznik [Mon, 25 May 2020 12:35:51 +0000 (14:35 +0200)] 
qemuBuildMemoryBackendProps: Prealloc mem for memfd backend

If a domain was using hugepages through memory-backend-file or
via -mem-path, we would turn prealloc on. But we are not doing
that for memory-backend-memfd. Fix this, because we need QEMU to
fully allocate hugepages.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agoqemuBuildMemoryBackendProps: Respect //memoryBacking/allocation/@mode=immediate
Michal Privoznik [Mon, 25 May 2020 12:35:40 +0000 (14:35 +0200)] 
qemuBuildMemoryBackendProps: Respect //memoryBacking/allocation/@mode=immediate

If user specifies immediate memory allocation in the domain XML,
they want QEMU to fully allocate its memory. And if the memory
was allocated using plain '-m' then we would honour it. But, if a
memory backend is used, then we don't set the prealloc attribute
of the backend.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agoqemuBuildMemoryBackendProps: Move @prealloc setting to backend agnostic part
Michal Privoznik [Mon, 25 May 2020 12:35:25 +0000 (14:35 +0200)] 
qemuBuildMemoryBackendProps: Move @prealloc setting to backend agnostic part

All three memory backends (-file, -ram and -memfd) have .prealloc
attribute. Since we are setting it only for -file, the
corresponding code lives only under if() that handles that
specific backend. But in near future we will want to set the
attribute for other backends too. Therefore, move the
corresponding code outside of the if().

This causes some .argv files to be changed, but the only change
happening there is move of the attribute (best viewed with:
'git show --color-words=.').

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agoqemu: Use .hostdevice attribute for usb-host
Michal Privoznik [Wed, 9 Sep 2020 11:15:15 +0000 (13:15 +0200)] 
qemu: Use .hostdevice attribute for usb-host

This originally started as bug 1595525 in which namespaces and
libusb used in QEMU were not playing nicely with each other. The
problem was that libusb built a cache of USB devices it saw
(which was a very limited set because of the namespace) and then
expected to receive udev events to keep the cache in sync. But
those udev events didn't come because on hotplug when we mknod()
devices in the namespace no udev event is generated. And what is
worse - libusb failed to open a device that wasn't in the cache.

Without going further into what the problem was, libusb added a
new API for opening USB devices that avoids using cache which
QEMU incorporated and exposes under "hostdevice" attribute.

What is even nicer is that QEMU uses qemu_open() for path
provided in the attribute and thus FD passing could be used.
Except qemu_open() expects so called FD sets instead of `getfd'
and these are not implemented in libvirt, yet.

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1877218
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu_capabilities: Add QEMU_CAPS_USB_HOST_HOSTDEVICE
Michal Privoznik [Wed, 9 Sep 2020 09:13:52 +0000 (11:13 +0200)] 
qemu_capabilities: Add QEMU_CAPS_USB_HOST_HOSTDEVICE

This capability tracks whether "usb-host" device has "hostdevice"
attribute. This attribute allows us to specify full path to the
USB device ("/dev/bus/usb/$bus/$dev") but more importantly, since
QEMU uses qemu_open() for this attribute it allows us to pass
pre-opened FD and have QEMU not bother with opening the file at
all.

The attribute was added in v5.1.0-rc0~71^2~1 QEMU commit.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainNumaFillCPUsInNode: Skip over NUMA nodes without vCPUs
Michal Privoznik [Wed, 30 Sep 2020 08:37:29 +0000 (10:37 +0200)] 
virDomainNumaFillCPUsInNode: Skip over NUMA nodes without vCPUs

After v6.5.0-rc1~148 we started to rectify vCPU to guest NUMA
assignment - if there is a vCPU not assigned to any guest NUMA
node it is automatically assigned to node #0.

A month later I've made it possible to define guest NUMA nodes
without vCPUs (v6.6.0-rc1~250) - this is needed because of HMAT.
As a part of that I fixed all callers of
virDomainNumaGetNodeCpumask() (which returns a bitmap of vCPUs for
given node) to handle case when NULL is returned (i.e. no vCPUs
assigned to given node). But of course my patch was written
before aforementioned vCPU rectify patch but merged afterwards
and hence I missed the virDomainNumaFillCPUsInNode() caller.

And because we are dealing with a NULL pointer, of course this
leads to a crash. Just try to define a domain with at least two
NUMA nodes and no vCPU assignment to any of the nodes.

Fixes: a26f61ee0cffa421b87ef568002b684dd8025432
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1880289
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
4 years agotests: qemucapabilities: Update capabilities for qemu-5.2 dev cycle
Peter Krempa [Mon, 14 Sep 2020 10:26:05 +0000 (12:26 +0200)] 
tests: qemucapabilities: Update capabilities for qemu-5.2 dev cycle

Mid-cycle caps resync. Notable change is that virtio-blk enables
multiqueue by default and the addition of
'calc-dirty-rate'/'query-dirty-rate' QMP commands.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: migration: Rename qemuMigrationEatCookie to qemuMigrationCookieParse
Peter Krempa [Mon, 28 Sep 2020 15:43:46 +0000 (17:43 +0200)] 
qemu: migration: Rename qemuMigrationEatCookie to qemuMigrationCookieParse

Use a more descriptive name and move the verb to the end so that the
functions conform with the naming policy.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemuMigrationCookieXMLFormatStr: Remove
Peter Krempa [Mon, 28 Sep 2020 15:12:40 +0000 (17:12 +0200)] 
qemuMigrationCookieXMLFormatStr: Remove

There is just one caller, inline the code. This also optimizes the code
as we no longer have to calculate length of the output XML as it's
actually stored in the buffer struct.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemuMigrationSrcBeginPhase: Use qemuMigrationCookieNew
Peter Krempa [Mon, 28 Sep 2020 15:07:02 +0000 (17:07 +0200)] 
qemuMigrationSrcBeginPhase: Use qemuMigrationCookieNew

We need an empty cookie, so use qemuMigrationCookieNew instead of
qemuMigrationEatCookie with NULL/0 arguments.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemuMigrationCookieNew: Export
Peter Krempa [Mon, 28 Sep 2020 15:05:22 +0000 (17:05 +0200)] 
qemuMigrationCookieNew: Export

Allow direct use rather than going through qemuMigrationEatCookie with
NULL/0 arguments.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemuMigrationCookieNew: Refactor allocation and cleanup
Peter Krempa [Mon, 28 Sep 2020 15:03:33 +0000 (17:03 +0200)] 
qemuMigrationCookieNew: Refactor allocation and cleanup

Move around some code so that we can get rid of the 'cleanup:' label.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: migration: Rename qemuMigrationBakeCookie to qemuMigrationCookieFormat
Peter Krempa [Mon, 28 Sep 2020 14:49:28 +0000 (16:49 +0200)] 
qemu: migration: Rename qemuMigrationBakeCookie to qemuMigrationCookieFormat

Use a more descriptive name and move the verb to the end so that the
functions conform with the naming policy.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agotests: qemuxml2argv: Fix and enable 'disk-transient' case
Peter Krempa [Thu, 24 Sep 2020 10:23:24 +0000 (12:23 +0200)] 
tests: qemuxml2argv: Fix and enable 'disk-transient' case

We didn't actually use this file. Change the disk type to 'file' so that
it works in qemu and add pre and post-blockdev invocations.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: validate: Allow <transient/> disks
Masayoshi Mizuma [Thu, 17 Sep 2020 13:30:43 +0000 (09:30 -0400)] 
qemu: validate: Allow <transient/> disks

Extract the validation of transient disk option. We support transient
disks in qemu under the following conditions:

 - -blockdev is used
 - the disk source is a local file
 - the disk type is 'disk'
 - the disk is not readonly

Signed-off-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: process: Handle transient disks on VM startup
Masayoshi Mizuma [Thu, 17 Sep 2020 13:30:45 +0000 (09:30 -0400)] 
qemu: process: Handle transient disks on VM startup

Add overlays after the VM starts before we start executing guest code.

Signed-off-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: hotplug: Remove overlay of <transient> disk on disk unplug
Peter Krempa [Tue, 22 Sep 2020 12:53:57 +0000 (14:53 +0200)] 
qemu: hotplug: Remove overlay of <transient> disk on disk unplug

Remove the overlay if the disk was <transient/>. Note that even if we'd
forbid unplug of such a disk through the API, the disk can still be
ejected from the guest.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: Block migration when transient disk option is enabled
Masayoshi Mizuma [Thu, 17 Sep 2020 13:30:42 +0000 (09:30 -0400)] 
qemu: Block migration when transient disk option is enabled

Block migration when transient disk option is enabled to simplify the
handling of the overlay files.

Signed-off-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: Block disk hotplug when transient disk option is enabled
Masayoshi Mizuma [Thu, 17 Sep 2020 13:30:41 +0000 (09:30 -0400)] 
qemu: Block disk hotplug when transient disk option is enabled

For now we disable disk hotplug of transient disk as it requires
creating an overlay prior to adding the frontend.

Signed-off-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: Block blockjobs when transient disk option is enabled
Masayoshi Mizuma [Thu, 17 Sep 2020 13:30:40 +0000 (09:30 -0400)] 
qemu: Block blockjobs when transient disk option is enabled

For now we disallow blockjobs with transient disks to avoid dealing with
obsoleted overlays.

Signed-off-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: snapshot: Introduce helpers for creating overlays on <transient/> disks
Peter Krempa [Mon, 21 Sep 2020 17:39:02 +0000 (19:39 +0200)] 
qemu: snapshot: Introduce helpers for creating overlays on <transient/> disks

To implement <transient/> disks we'll need to install an overlay on top
of the original disk image which will be discarded after the VM is
turned off. This was initially implemented by qemu but libvirt never
picked up this option as the overlays were created by qemu without
libvirt involvment which didn't work with SELinux.

With blockdev the qemu feature became unsupported so we need to do this
via the snapshot code anyways.

The helpers introduced in this patch prepare a fake snapshot disk
definition for a disk which is configured as <transient/> and use it to
create a snapshot (without actually modifying metadata or persistent
def).

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: prepare cleanup for <transient/> disk overlays
Peter Krempa [Tue, 22 Sep 2020 12:39:27 +0000 (14:39 +0200)] 
qemu: prepare cleanup for <transient/> disk overlays

Later patches will implement support for <transient/> disks in libvirt
by installing an overlay on top of the configured image. This will
require cleanup after the VM will be stopped so that the state is
correctly discarded.

Since the overlay will be installed only during the startup phase of the
VM we need to ensure that qemuProcessStop doesn't delete the original
file on some previous failure. This is solved by adding
'inhibitDiskTransientDelete' VM private data member which is set prior
to any startup step and will be cleared once transient disk overlays are
established.

Based on that we can then delete the overlays for any <transient/> disk.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainSnapshotDiskDefFree: Export and register as autoptr func
Peter Krempa [Mon, 21 Sep 2020 14:49:26 +0000 (16:49 +0200)] 
virDomainSnapshotDiskDefFree: Export and register as autoptr func

Allow using the function for creating temporary snapshot disk
definitions for creating <transient/> disk overlays.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Tested-by: Ján Tomko <jtomko@redhat.com>
4 years agoPost-release version bump to 6.9.0
Jiri Denemark [Thu, 1 Oct 2020 07:52:49 +0000 (09:52 +0200)] 
Post-release version bump to 6.9.0

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
4 years agoRelease of libvirt-6.8.0 v6.8.0
Jiri Denemark [Thu, 1 Oct 2020 07:50:10 +0000 (09:50 +0200)] 
Release of libvirt-6.8.0

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
4 years agoqemu: agent: set ifname to NULL after freeing
Ján Tomko [Fri, 18 Sep 2020 15:56:37 +0000 (17:56 +0200)] 
qemu: agent: set ifname to NULL after freeing

CVE-2020-25637

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reported-by: Ilja Van Sprundel <ivansprundel@ioactive.com>
Fixes: 0977b8aa071de550e1a013d35e2c72615e65d520
Reviewed-by: Mauro Matteo Cascella <mcascell@redhat.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
4 years agorpc: require write acl for guest agent in virDomainInterfaceAddresses
Ján Tomko [Fri, 18 Sep 2020 15:54:14 +0000 (17:54 +0200)] 
rpc: require write acl for guest agent in virDomainInterfaceAddresses

CVE-2020-25637

Add a requirement for domain:write if source is set to
VIR_DOMAIN_INTERFACE_ADDRESSES_SRC_AGENT.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reported-by: Ilja Van Sprundel <ivansprundel@ioactive.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
4 years agorpc: add support for filtering @acls by uint params
Ján Tomko [Fri, 18 Sep 2020 14:09:25 +0000 (16:09 +0200)] 
rpc: add support for filtering @acls by uint params

CVE-2020-25637

Add a new field to @acl annotations for filtering by
unsigned int parameters.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
4 years agorpc: gendispatch: handle empty flags
Ján Tomko [Fri, 18 Sep 2020 15:44:56 +0000 (17:44 +0200)] 
rpc: gendispatch: handle empty flags

CVE-2020-25637

Prepare for omission of the <flagname> in remote_protocol.x
@acl annotations:
 @acl: <object>:<permission>:<flagname>
so that we can add more fields after, e.g.:
 @acl: <object>:<permission>::<field>

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
4 years agodocs: bhyve: document sound device and VNC bits
Roman Bogorodskiy [Thu, 24 Sep 2020 16:15:34 +0000 (20:15 +0400)] 
docs: bhyve: document sound device and VNC bits

 * Document sound device support,
 * Document VNC password configuration and framebuffer resolution.

Signed-off-by: Roman Bogorodskiy <bogorodskiy@gmail.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agoTranslated using Weblate (Russian)
Olesya Gerasimenko [Tue, 29 Sep 2020 12:11:26 +0000 (14:11 +0200)] 
Translated using Weblate (Russian)

Currently translated at 100.0% (10354 of 10354 strings)

Translation: libvirt/libvirt
Translate-URL: https://translate.fedoraproject.org/projects/libvirt/libvirt/ru/

Co-authored-by: Olesya Gerasimenko <gammaray@basealt.ru>
Signed-off-by: Olesya Gerasimenko <gammaray@basealt.ru>
4 years agoNEWS: Mention qcow2 cluster size being preserved across snapshots and iSCSI hostdev... v6.8.0-rc2
Peter Krempa [Thu, 24 Sep 2020 13:02:51 +0000 (15:02 +0200)] 
NEWS: Mention qcow2 cluster size being preserved across snapshots and iSCSI hostdev fixes

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agoTranslated using Weblate (Polish)
Piotr Drąg [Sun, 27 Sep 2020 10:28:40 +0000 (12:28 +0200)] 
Translated using Weblate (Polish)

Currently translated at 23.6% (2450 of 10354 strings)

Translation: libvirt/libvirt
Translate-URL: https://translate.fedoraproject.org/projects/libvirt/libvirt/pl/

Co-authored-by: Piotr Drąg <piotrdrag@gmail.com>
Signed-off-by: Piotr Drąg <piotrdrag@gmail.com>
4 years agoTranslated using Weblate (Polish)
Michał Smyk [Sun, 27 Sep 2020 10:28:37 +0000 (12:28 +0200)] 
Translated using Weblate (Polish)

Currently translated at 23.6% (2450 of 10354 strings)

Translation: libvirt/libvirt
Translate-URL: https://translate.fedoraproject.org/projects/libvirt/libvirt/pl/

Co-authored-by: Michał Smyk <fedora@smyk.it>
Signed-off-by: Michał Smyk <fedora@smyk.it>
4 years agoTranslated using Weblate (Ukrainian)
Yuri Chornoivan [Sun, 27 Sep 2020 10:28:34 +0000 (12:28 +0200)] 
Translated using Weblate (Ukrainian)

Currently translated at 100.0% (10354 of 10354 strings)

Translation: libvirt/libvirt
Translate-URL: https://translate.fedoraproject.org/projects/libvirt/libvirt/uk/

Co-authored-by: Yuri Chornoivan <yurchor@ukr.net>
Signed-off-by: Yuri Chornoivan <yurchor@ukr.net>
4 years agoUpdate translation files
Weblate [Sun, 27 Sep 2020 10:28:29 +0000 (12:28 +0200)] 
Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: libvirt/libvirt
Translate-URL: https://translate.fedoraproject.org/projects/libvirt/libvirt/

Co-authored-by: Weblate <noreply@weblate.org>
Signed-off-by: Fedora Weblate Translation <i18n@lists.fedoraproject.org>
4 years agomeson: drop HTML4 variants of rst2html
Daniel P. Berrangé [Fri, 25 Sep 2020 09:37:30 +0000 (10:37 +0100)] 
meson: drop HTML4 variants of rst2html

We stopped supporting Ubuntu 16.04 earlier in the year in:

  commit 57e9f3a7e02988432c8c6790cb058b2b5372821b
  Author: Daniel P. Berrangé <berrange@redhat.com>
  Date:   Mon May 4 13:06:56 2020 +0100

    gitlab: update list of distros to use latest versions

So there is no reason to keep the HTML4 variants of rst2html around.

Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agogitdm: add more individual contributors
Pino Toscano [Fri, 25 Sep 2020 10:39:41 +0000 (12:39 +0200)] 
gitdm: add more individual contributors

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agomeson: don't check for libutil.h except on FreeBSD
Daniel P. Berrangé [Fri, 25 Sep 2020 09:19:03 +0000 (10:19 +0100)] 
meson: don't check for libutil.h except on FreeBSD

The libutil.h we are after is explicitly only something we want on
FreeBSD, we don't want to accidentally pick up this header on other
platforms as it can lead to build failures.

Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agolibxl: Don't free def member of virDomainObj
Jim Fehlig [Thu, 24 Sep 2020 16:39:13 +0000 (10:39 -0600)] 
libxl: Don't free def member of virDomainObj

The refactoring in commit de49d5bad3 accidentally dropped the statement
setting def to NULL after successfully adding it to the virDomainObjList,
causing it to be freed while still in use. The resulting memory
corruption caused unpredictable behavior, often resulting in a libvirtd
crash.

Signed-off-by: Jim Fehlig <jfehlig@suse.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
4 years agonews: document recent esx API implementations
Pino Toscano [Thu, 24 Sep 2020 15:22:58 +0000 (17:22 +0200)] 
news: document recent esx API implementations

Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
4 years agonews: add note about new virt-ssh-helper binary
Daniel P. Berrangé [Thu, 24 Sep 2020 15:00:23 +0000 (16:00 +0100)] 
news: add note about new virt-ssh-helper binary

Reviewed-by: Andrea Bolognani <abologna@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agoapparmor: Allow /usr/libexec for libxl-save-helper and pygrub
Jim Fehlig [Tue, 22 Sep 2020 22:34:22 +0000 (16:34 -0600)] 
apparmor: Allow /usr/libexec for libxl-save-helper and pygrub

Like other distros, openSUSE Tumbleweed recently changed libexecdir from
/usr/lib to /usr/libexec. Add it as an allowed path for libxl-save-helper
and pygrub.

Signed-off-by: Jim Fehlig <jfehlig@suse.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
4 years agopo: Refresh potfile for v6.8.0 v6.8.0-rc1
Jiri Denemark [Thu, 24 Sep 2020 13:06:42 +0000 (15:06 +0200)] 
po: Refresh potfile for v6.8.0

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>