]> xenbits.xensource.com Git - libvirt.git/log
libvirt.git
4 years agoNEWS: qemu: add socket for virtiofs filesystems
Ján Tomko [Thu, 22 Apr 2021 11:38:09 +0000 (13:38 +0200)]
NEWS: qemu: add socket for virtiofs filesystems

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Jonathon Jongsma <jjongsma@redhat.com>
4 years agodocs: virtiofs: add section about externally-launched virtiofsd
Ján Tomko [Thu, 22 Apr 2021 11:37:04 +0000 (13:37 +0200)]
docs: virtiofs: add section about externally-launched virtiofsd

Provide an exmple in a place more visible than formatdomain.html.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Jonathon Jongsma <jjongsma@redhat.com>
4 years agodocs: document new socket attribute for virtiofs
Ján Tomko [Thu, 22 Apr 2021 11:36:35 +0000 (13:36 +0200)]
docs: document new socket attribute for virtiofs

Describe the attribute and add an example.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Jonathon Jongsma <jjongsma@redhat.com>
4 years agoUpdate translation files
Weblate [Tue, 27 Apr 2021 09:34:02 +0000 (11:34 +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 agoTranslated using Weblate (Swedish)
Göran Uddeborg [Tue, 27 Apr 2021 09:33:59 +0000 (11:33 +0200)]
Translated using Weblate (Swedish)

Currently translated at 24.5% (2595 of 10581 strings)

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

Translated using Weblate (Swedish)

Currently translated at 24.3% (2575 of 10581 strings)

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

Co-authored-by: Göran Uddeborg <goeran@uddeborg.se>
Signed-off-by: Göran Uddeborg <goeran@uddeborg.se>
4 years agoTranslated using Weblate (Korean)
simmon [Tue, 27 Apr 2021 09:33:58 +0000 (11:33 +0200)]
Translated using Weblate (Korean)

Currently translated at 41.4% (4389 of 10581 strings)

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

Co-authored-by: simmon <simmon@nplob.com>
Signed-off-by: simmon <simmon@nplob.com>
4 years agopo: Refresh potfile for v7.3.0
Jiri Denemark [Tue, 27 Apr 2021 09:28:54 +0000 (11:28 +0200)]
po: Refresh potfile for v7.3.0

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
4 years agonodedev: remove unnecessary checks for NULL cmd
Jonathon Jongsma [Wed, 21 Apr 2021 15:47:43 +0000 (10:47 -0500)]
nodedev: remove unnecessary checks for NULL cmd

virCommandRun() already handles the case where the cmd argument is NULL,
so there's no need for the caller to check. Make all callers consistent
and remove unnecessary NULL checks.

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agonodedev: handle failure to generate mdevctl cmd
Jonathon Jongsma [Tue, 20 Apr 2021 14:09:00 +0000 (09:09 -0500)]
nodedev: handle failure to generate mdevctl cmd

Coverity complained that the 'default' case of the switch in
nodeDeviceGetMdevctlCommand() was falling through without initializing
'cmd'. Return NULL in this case even though it should never happen.

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agonodedev: fix potential leak of command
Jonathon Jongsma [Tue, 20 Apr 2021 13:57:10 +0000 (08:57 -0500)]
nodedev: fix potential leak of command

When returning early due to errors, cmd will be leaked. Use an autoptr
to handle these early returns without leaking memory.

Signed-off-by: Jonathon Jongsma <jjongsma@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemu: monitor: Remove qemuMonitorJobCancel
Peter Krempa [Tue, 20 Apr 2021 14:07:33 +0000 (16:07 +0200)]
qemu: monitor: Remove qemuMonitorJobCancel

The API is unused since last commit. Remove it.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcNBDCopyCancelled: Use do-while loop instead of jumping back
Peter Krempa [Tue, 20 Apr 2021 16:36:23 +0000 (18:36 +0200)]
qemuMigrationSrcNBDCopyCancelled: Use do-while loop instead of jumping back

Jumping back in the code is an anti-pattern that should be avoided if
possible.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcNBDCopyCancelOne: Force-cancel disk copy jobs when aborting migration
Peter Krempa [Tue, 20 Apr 2021 15:08:07 +0000 (17:08 +0200)]
qemuMigrationSrcNBDCopyCancelOne: Force-cancel disk copy jobs when aborting migration

We don't require that the data is consistent on the destination if
aborting the migration.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcNBDCopyCancel*: Rename 'check' to 'abortMigration'
Peter Krempa [Tue, 20 Apr 2021 15:05:47 +0000 (17:05 +0200)]
qemuMigrationSrcNBDCopyCancel*: Rename 'check' to 'abortMigration'

Rename the parameter so that it's more clear what state we are in and
fix all callees.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuBlockJobRefreshJobs: Replace qemuMonitorJobCancel by qemuMonitorBlockJobCancel
Peter Krempa [Tue, 20 Apr 2021 14:34:02 +0000 (16:34 +0200)]
qemuBlockJobRefreshJobs: Replace qemuMonitorJobCancel by qemuMonitorBlockJobCancel

We want to unify on one block job cancellation API. Use
qemuMonitorBlockJobCancel which has more features.

In case of job refresh, we are killing off any unknown jobs so we don't
care about their fate.

Another difference is that an possible error from the block job
cancellation might be reported, but we don't really care here ince
it's a very unlikely scenario and we also report a warning.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuBackupJobCancelBlockjobs: Replace qemuMonitorJobCancel by qemuMonitorBlockJobCancel
Peter Krempa [Tue, 20 Apr 2021 14:34:02 +0000 (16:34 +0200)]
qemuBackupJobCancelBlockjobs: Replace qemuMonitorJobCancel by qemuMonitorBlockJobCancel

We want to unify on one block job cancellation API. Use
qemuMonitorBlockJobCancel which has more features.

In case of backup jobs we can cancel the jobs forcefully since the code
is on a cleanup path when the job fails.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuDomainBlockJobAbort: Don't use 'job-cancel' instead of 'block-job-cancel'
Peter Krempa [Wed, 21 Apr 2021 13:47:59 +0000 (15:47 +0200)]
qemuDomainBlockJobAbort: Don't use 'job-cancel' instead of 'block-job-cancel'

'block-job-cancel' has one very important semantic difference to
'job-cancel', docummented in qemu as:

  Note that if you issue 'block-job-cancel' after 'drive-mirror' has indicated
  (via the event BLOCK_JOB_READY) that the source and destination are
  synchronized, then the event triggered by this command changes to
  BLOCK_JOB_COMPLETED, to indicate that the mirroring has ended and the
  destination now has a point-in-time copy tied to the time of the cancellation.

Since libvirt advertises the block copy job as having the synchronous
abort feature we must not use 'job-cancel' here.

Fixes: 4817b5ca1d0
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemu: monitor: Add 'force' argument for 'block-job-cancel' QMP command
Peter Krempa [Tue, 20 Apr 2021 12:14:51 +0000 (14:14 +0200)]
qemu: monitor: Add 'force' argument for 'block-job-cancel' QMP command

In certain cases such as when aborting migration we don't really care
for completion of the blockjob. Add 'force' as parameter of
'block-job-cancel'.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMonitorJSONBlockJobCancel: Refactor cleanup
Peter Krempa [Tue, 20 Apr 2021 14:16:56 +0000 (16:16 +0200)]
qemuMonitorJSONBlockJobCancel: Refactor cleanup

Use automatic memory freeing and remove the cleanup section.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemumonitorjsontest: Add test for 'qemuMonitorJSONBlockJobCancel'
Peter Krempa [Tue, 20 Apr 2021 14:14:56 +0000 (16:14 +0200)]
qemumonitorjsontest: Add test for 'qemuMonitorJSONBlockJobCancel'

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcBeginPhase: Don't offer 'nbd' in cookie if there are no disks to...
Peter Krempa [Tue, 13 Apr 2021 15:31:53 +0000 (17:31 +0200)]
qemuMigrationSrcBeginPhase: Don't offer 'nbd' in cookie if there are no disks to migrate

Don't try to setup disk migration and the NBD stuff if we end up
migrating nothing.

The destination side has luckily no setup for the non-NBD cases so
omitting the element fully is okay.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcRun: Don't attempt any storage migration if no disks will be migrated
Peter Krempa [Tue, 13 Apr 2021 15:17:42 +0000 (17:17 +0200)]
qemuMigrationSrcRun: Don't attempt any storage migration if no disks will be migrated

Don't even try to setup storage migration if there are no eligible
disks.

This also fixes migration from older libvirts which didn't format an
empty <nbd/> element in the migration cookie if there weren't any disks
to migrate.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcRun: Sanitize setting of cookieFlags and migrate_flags on storage...
Peter Krempa [Tue, 13 Apr 2021 14:59:38 +0000 (16:59 +0200)]
qemuMigrationSrcRun: Sanitize setting of cookieFlags and migrate_flags on storage migration

Base the decision on the main API flags (VIR_MIGRATE_NON_SHARED_DISK,
QEMU_MONITOR_MIGRATE_NON_SHARED_INC) via a boolean 'storageMigration'
rather than juggling everything trhough 'migration_flags'.

After this patch 'migration_flags' is updated to contain the legacy
storage migration flags only when we'll be about to use it rather than
setting it and then resetting it.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Tested-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcNBDStorageCopy: Don't pass migrate_flags
Peter Krempa [Tue, 13 Apr 2021 14:53:57 +0000 (16:53 +0200)]
qemuMigrationSrcNBDStorageCopy: Don't pass migrate_flags

'migrate_flags' can be updated in the only caller and since
qemuMigrationSrcNBDStorageCopy already takes @flags which contains
VIR_MIGRATE_NON_SHARED_INC (used to set
 QEMU_MONITOR_MIGRATE_NON_SHARED_INC) we can completely remove the
parameter.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
Tested-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationSrcNBDStorageCopy: Return error code on error
Peter Krempa [Tue, 13 Apr 2021 14:17:24 +0000 (16:17 +0200)]
qemuMigrationSrcNBDStorageCopy: Return error code on error

In case the 'nbdURI' schema is not known the code would report an error
but wouldn't return failure.

Fixes: 49186372dbe
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
Tested-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuMigrationCookieNBDXMLFormat: Format empty <nbd/> element
Peter Krempa [Tue, 13 Apr 2021 14:16:44 +0000 (16:16 +0200)]
qemuMigrationCookieNBDXMLFormat: Format empty <nbd/> element

Commit 518be41aaa3 refactored qemuMigrationCookieNBDXMLFormat to use
virXMLFormatElement which in comparison to the previous code doesn't
format the element if it's empty.

Unfortunately some crusty bits of our migration code use questionable
logic to assert use of the old-style storage migration parameters which
breaks if no disks are being migrated and the <nbd/> element is not
present.

While later patches will fix the code, re-instate formatting of empty
<nbd/> for increased compatibility.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
Tested-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoutil: xml: Introduce virXMLFormatElementEmpty
Peter Krempa [Tue, 13 Apr 2021 14:12:17 +0000 (16:12 +0200)]
util: xml: Introduce virXMLFormatElementEmpty

Add a helper which will format an XML element with attributes and
children, but compared to virXMLFormatElement it also formats an empty
element if both buffers are empty.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
Tested-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDef: Change type of xen_passthrough_mode to virDomainXenPassthroughMode
Tim Wiederhake [Fri, 23 Apr 2021 15:39:21 +0000 (17:39 +0200)]
virDomainDef: Change type of xen_passthrough_mode to virDomainXenPassthroughMode

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainDef: Change type of hyperv_stimer_direct to virTristateSwitch
Tim Wiederhake [Fri, 23 Apr 2021 15:39:20 +0000 (17:39 +0200)]
virDomainDef: Change type of hyperv_stimer_direct to virTristateSwitch

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainSoundDef: Change type of model to virDomainSoundModel
Tim Wiederhake [Fri, 23 Apr 2021 15:39:18 +0000 (17:39 +0200)]
virDomainSoundDef: Change type of model to virDomainSoundModel

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainGraphicsDefParseXML: Use virXMLProp*
Tim Wiederhake [Fri, 23 Apr 2021 15:39:17 +0000 (17:39 +0200)]
virDomainGraphicsDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainGraphicsDefParseXMLDesktop: Use virXMLProp*
Tim Wiederhake [Fri, 23 Apr 2021 15:39:15 +0000 (17:39 +0200)]
virDomainGraphicsDefParseXMLDesktop: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainGraphicsDefParseXMLSDL: Use virXMLProp*
Tim Wiederhake [Fri, 23 Apr 2021 15:39:14 +0000 (17:39 +0200)]
virDomainGraphicsDefParseXMLSDL: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agomeson: don't probe for -Werror if --werror is enabled
Daniel P. Berrangé [Thu, 8 Apr 2021 10:50:30 +0000 (11:50 +0100)]
meson: don't probe for -Werror if --werror is enabled

Meson has its own mechanism to turn on -Werror with the --werror option.
If this is set, then there is no reason for libvirt to check for -Werror
itself.

We remove the summary line output because it is potentially misleading
when libvirt hasn't enabled -Werror, but meson has.

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agomeson: honour meson warning_level option
Daniel P. Berrangé [Wed, 7 Apr 2021 17:20:49 +0000 (18:20 +0100)]
meson: honour meson warning_level option

Meson defines a warning_level option which has the following behaviour
with C code

 0:  no warning flags
 1: -Wall
 2: -Wall -Wextra
 3: -Wall -Wextra -Wpedantic

Currently we add our extra warning flags unconditionally if the compiler
supports them, regardless of the meson warning_level setting. This has
effectively nullified the warning_level setting in meson, and also
results in meson printing these messages:

  meson.build:498: WARNING: Consider using the built-in warning_level option instead of using "-Wall".
  meson.build:498: WARNING: Consider using the built-in warning_level option instead of using "-Wextra".

Semantically we can think of our huge list of flags as being an "extra"
set of warnings, and thus we ought to only add them when meson would
itself use -Wextra. aka warning_level == 2 or 3.

In practice libvirt code can't be built with -Wpedantic so we can ignore
meson warning_level 3, and only add our flags when warning_level==2.

In doing this change, we no longer have to check -Wall/-Wextra ourselves
as we can assume meson already set them.

-W is an alias of -Wextra so it is removed too.

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agomeson: avoid checking compiler flags twice
Daniel P. Berrangé [Thu, 8 Apr 2021 10:29:20 +0000 (11:29 +0100)]
meson: avoid checking compiler flags twice

In several cases we check if a compiler flag is supported, and then add
it to the 'cc_flags' array. The entire 'cc_flags' array is then later
tested to see if each flag is supported, which duplicates the check in
some cases.

Move the check of cc_flags earlier, and for the extra flags append
directly to supported_cc_flags to avoid the duplicate check

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agomeson: merge all cc_flags arrays into one
Daniel P. Berrangé [Thu, 8 Apr 2021 10:23:03 +0000 (11:23 +0100)]
meson: merge all cc_flags arrays into one

The split of arrays is fairly arbitrary and a hang over from the way we
had to structure lists of flags when we used GNULIB's compiler flag
checking m4 logic.

The separate lists leads to cases where we enable a flag in one list and
have contradictory setting in another list, which leads to confusion.

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agomeson: remove obsolete comment about stack frame size
Daniel P. Berrangé [Thu, 8 Apr 2021 12:57:55 +0000 (13:57 +0100)]
meson: remove obsolete comment about stack frame size

The virStrerror function no longer exists in libvirt so is not a
constraint. At the current stack limit of 4k, and default Linux
stack size of 8 MB, we have a recursion limit of 2048 in the
absolute worst case, and much higher in common case. Even with
smaller stack sizes, we're going to be fine as we don't deeply
recurse in code.

Thus it is not worth spending effort to optimize below our current
4k worst case limit. Removing the comment will stop encouraging
people to spend time on this in future.

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agomeson: actually check for -Wframe-larger-than
Daniel P. Berrangé [Wed, 7 Apr 2021 17:19:32 +0000 (18:19 +0100)]
meson: actually check for -Wframe-larger-than

All other warning flags are checked for compiler support, so we
shouldn't blindly assume this one always exists.

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agomeson: get rid of list of unused warning flags
Daniel P. Berrangé [Wed, 7 Apr 2021 17:16:50 +0000 (18:16 +0100)]
meson: get rid of list of unused warning flags

We're not using these warning flags with libvirt, and it is not worth
keeping them just to issue a warning if someone tries to enable them.
If someone does try to enable them, either libvirt will build cleanly
or it won't.

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
4 years agovirDomainGraphicsDefParseXMLVNC: Use virXMLProp*
Tim Wiederhake [Fri, 23 Apr 2021 10:37:41 +0000 (12:37 +0200)]
virDomainGraphicsDefParseXMLVNC: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainGraphicsDef: Change type of sharePolicy to virDomainGraphicsVNCSharePolicy
Tim Wiederhake [Fri, 23 Apr 2021 10:37:40 +0000 (12:37 +0200)]
virDomainGraphicsDef: Change type of sharePolicy to virDomainGraphicsVNCSharePolicy

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainGraphicsListenDefParseXML: Use virXMLProp*
Tim Wiederhake [Fri, 23 Apr 2021 10:37:39 +0000 (12:37 +0200)]
virDomainGraphicsListenDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainNetDefParseXML: Use virXMLProp*
Tim Wiederhake [Fri, 23 Apr 2021 10:37:38 +0000 (12:37 +0200)]
virDomainNetDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainActualNetDef: Change type of type to virDomainNetType
Tim Wiederhake [Fri, 23 Apr 2021 10:37:36 +0000 (12:37 +0200)]
virDomainActualNetDef: Change type of type to virDomainNetType

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainPCIControllerOpts: Change type of modelName to virDomainControllerPCIModelName
Tim Wiederhake [Fri, 23 Apr 2021 10:37:34 +0000 (12:37 +0200)]
virDomainPCIControllerOpts: Change type of modelName to virDomainControllerPCIModelName

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainControllerDef: Change type of ioeventfd to virTristateSwitch
Tim Wiederhake [Fri, 23 Apr 2021 10:37:33 +0000 (12:37 +0200)]
virDomainControllerDef: Change type of ioeventfd to virTristateSwitch

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirXMLPropEnum: Fix return value
Tim Wiederhake [Fri, 23 Apr 2021 10:37:32 +0000 (12:37 +0200)]
virXMLPropEnum: Fix return value

Function incorrectly returns 0 when property was successfully read.

Fixes: ab5d2776c925ec45eb54ec5432f5645cebb80c85
Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: Don't double free @node_cpus in qemuProcessSetupPid()
Michal Privoznik [Fri, 23 Apr 2021 08:05:50 +0000 (10:05 +0200)]
qemu: Don't double free @node_cpus in qemuProcessSetupPid()

When placing vCPUs into CGroups the qemuProcessSetupPid() is
called which then enters a for() loop (around its middle) where
it calls virDomainNumaGetNodeCpumask() for each guest NUMA node.
But the latter returns only a pointer not new reference/copy and
thus the caller must not free it. But the variable is decorated
with g_autoptr() which leads to a double free.

Fixes: 2d37d8dbc987d1998b4ad8029ba324b6bfe49799
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agorpc: libssh2: Enable EC host keys
Bastian Germann [Sun, 28 Mar 2021 21:10:21 +0000 (23:10 +0200)]
rpc: libssh2: Enable EC host keys

libssh2 has ECDSA and ED25519 support beginning with v1.9.0. libvirt cannot
make use of those because it will handle them as unknown key types.

Add support for those host key types.

Signed-off-by: Bastian Germann <bastiangermann@fishpost.de>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovahDeinit: Fix memory leak
Tim Wiederhake [Thu, 22 Apr 2021 13:07:33 +0000 (15:07 +0200)]
vahDeinit: Fix memory leak

Calling VIR_FREE on a virDomainDef* does not free its various contained
pointers.

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Signed-off-by: Ján Tomko <jtomko@redhat.com>
4 years agovirDomainChrSourceDefParseTCP: Use virXMLProp*
Tim Wiederhake [Thu, 22 Apr 2021 10:32:57 +0000 (12:32 +0200)]
virDomainChrSourceDefParseTCP: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agodomain_conf: Remove function virDomainChrSourceDefParseMode
Tim Wiederhake [Thu, 22 Apr 2021 10:32:56 +0000 (12:32 +0200)]
domain_conf: Remove function virDomainChrSourceDefParseMode

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agodomain_conf: Introduce function virDomainChrSouceModeTypeFromString
Tim Wiederhake [Thu, 22 Apr 2021 10:32:55 +0000 (12:32 +0200)]
domain_conf: Introduce function virDomainChrSouceModeTypeFromString

Preparatory step to remove virDomainChrSourceDefParseMode.

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskDefDriverParseXML: Use virXMLProp*
Tim Wiederhake [Thu, 22 Apr 2021 10:32:54 +0000 (12:32 +0200)]
virDomainDiskDefDriverParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskDef: Change type of detect_zeroes to virDomainDiskDetectZeroes
Tim Wiederhake [Thu, 22 Apr 2021 10:32:53 +0000 (12:32 +0200)]
virDomainDiskDef: Change type of detect_zeroes to virDomainDiskDetectZeroes

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskDef: Change type of discard to virDomainDiskDiscard
Tim Wiederhake [Thu, 22 Apr 2021 10:32:52 +0000 (12:32 +0200)]
virDomainDiskDef: Change type of discard to virDomainDiskDiscard

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskDef: Change type of iomode to virDomainDiskInfo
Tim Wiederhake [Thu, 22 Apr 2021 10:32:51 +0000 (12:32 +0200)]
virDomainDiskDef: Change type of iomode to virDomainDiskInfo

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskDef: Change type of rerror_policy to virDomainDiskErrorPolicy
Tim Wiederhake [Thu, 22 Apr 2021 10:32:50 +0000 (12:32 +0200)]
virDomainDiskDef: Change type of rerror_policy to virDomainDiskErrorPolicy

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskDef: Change type of error_policy to virDomainDiskErrorPolicy
Tim Wiederhake [Thu, 22 Apr 2021 10:32:49 +0000 (12:32 +0200)]
virDomainDiskDef: Change type of error_policy to virDomainDiskErrorPolicy

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskDef: Change type of cachemode to virDomainDiskCache
Tim Wiederhake [Thu, 22 Apr 2021 10:32:48 +0000 (12:32 +0200)]
virDomainDiskDef: Change type of cachemode to virDomainDiskCache

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agolxc: Let the driver detect CGroups earlier
Michal Privoznik [Tue, 20 Apr 2021 08:33:03 +0000 (10:33 +0200)]
lxc: Let the driver detect CGroups earlier

This is the bug I'm facing. I deliberately configured a container
so that the source of a <filesystem/> to passthrough doesn't
exist. The start fails with:

  lxcContainerPivotRoot:669 : Failed to create /non-existent/path/.oldroot: Permission denied

which is expected. But what is NOT expected is that CGroup
hierarchy is left behind. This is because the controller sets up
the CGroup hierarchy, user namespace, moves interfaces, etc. and
finally checks whether container setup (done in a separate
process) succeeded. Only after all this the error is propagated
to the LXC driver. The driver aborts the startup and tries to
perform the cleanup, but this is missing CGroups because those
weren't detected yet.

Ideally, whenever a function fails, it tries to unroll back so
that is has no artifacts left behind (look at all those frees/FD
closes/etc. at end of functions). But with CGroups it is
different - the controller process can't clean up after itself,
because it is still running inside that CGroup.

Therefore, what we have to do is to let the driver detect CGroups
as soon as they are created, and proceed with controller
execution only after that.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Martin Kletzander <mkletzan@redhat.com>
4 years agolxc: Pass another pipe to lxc_controller
Michal Privoznik [Tue, 20 Apr 2021 11:28:20 +0000 (13:28 +0200)]
lxc: Pass another pipe to lxc_controller

Currently, there is only a single pipe passed to lxc_controller
and it is used by lxc_controller to signal to the LXC driver that
the container is set up and ready to run. However, in the next
commit we will need to signal that the LXC driver has done its
part of startup process and thus the controller can proceed.
Unfortunately, virCommand handshake can't be used for this,
because it's already used to read controller's PID.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Martin Kletzander <mkletzan@redhat.com>
4 years agolxc_controller: Move closing of handshakeFd out of virLXCControllerDaemonHandshake()
Michal Privoznik [Tue, 20 Apr 2021 11:34:55 +0000 (13:34 +0200)]
lxc_controller: Move closing of handshakeFd out of virLXCControllerDaemonHandshake()

Future commits will want to reuse the handshakeFd and thus it
mustn't be closed in virLXCControllerDaemonHandshake(). Do the
closing explicitly afterwards.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Martin Kletzander <mkletzan@redhat.com>
4 years agolxc_controller: Initialize ctrl->handshakeFd properly
Michal Privoznik [Tue, 20 Apr 2021 08:36:09 +0000 (10:36 +0200)]
lxc_controller: Initialize ctrl->handshakeFd properly

The lxc_controller has a structure that's keeping its internal
state, including so called handshakeFd which is the write end of
a pipe that's used to signal to the LXC driver that the container
is set up and ready to run. However, the struct member is not
initialized to -1, so if anything fails before it is set then the
virLXCControllerFree() function tries to close FD 0 (stdin).

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Martin Kletzander <mkletzan@redhat.com>
4 years agovirsh: Fix completion logic to guestvcpus command
Lin Ma [Thu, 22 Apr 2021 10:38:19 +0000 (18:38 +0800)]
virsh: Fix completion logic to guestvcpus command

In case of non-continuous vCPU topology, We can't infer the bitmap size
from the combination of onlineVcpuStr and nvcpus.
We should use virBitmapParseUnlimited here instead of virBitmapParse due
to the bitmap size is unknown.

e.g.:

  <vcpus>
    <vcpu id='0' enabled='yes' hotpluggable='no' order='1'/>
    <vcpu id='1' enabled='yes' hotpluggable='yes' order='2'/>
    <vcpu id='2' enabled='yes' hotpluggable='yes' order='3'/>
    <vcpu id='3' enabled='yes' hotpluggable='yes' order='4'/>
    <vcpu id='4' enabled='yes' hotpluggable='yes' order='5'/>
    <vcpu id='5' enabled='yes' hotpluggable='yes' order='6'/>
    <vcpu id='6' enabled='no' hotpluggable='yes'/>
    <vcpu id='7' enabled='no' hotpluggable='yes'/>
  </vcpus>

 # virsh guestvcpus --domain VM
vcpus          : 0-5
online         : 0-5
offlinable     : 1-5

 # virsh setvcpu --domain VM --disable --vcpulist 2

 # virsh guestvcpus --domain VM --disable --cpulist 4,5

 # virsh guestvcpus --domain VM
vcpus          : 0-1,3-5
online         : 0-1,3
offlinable     : 1,3-5

Before:
 # virsh guestvcpus --domain VM --enable --cpulist <TAB><TAB>
2  4

After:
 # virsh guestvcpus --domain VM --enable --cpulist <TAB><TAB>
4  5

Signed-off-by: Lin Ma <lma@suse.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirsh: Add mountpoint completion to domfsfreeze/domfsthaw command
Lin Ma [Thu, 22 Apr 2021 10:38:18 +0000 (18:38 +0800)]
virsh: Add mountpoint completion to domfsfreeze/domfsthaw command

Signed-off-by: Lin Ma <lma@suse.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainMemorytuneDefParseMemory: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 15:51:33 +0000 (17:51 +0200)]
virDomainMemorytuneDefParseMemory: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDiskSourceNetworkParse: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 15:51:32 +0000 (17:51 +0200)]
virDomainDiskSourceNetworkParse: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDeviceInfoParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 15:51:31 +0000 (17:51 +0200)]
virDomainDeviceInfoParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirStorageEncryptionInfoParseCipher: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 15:51:30 +0000 (17:51 +0200)]
virStorageEncryptionInfoParseCipher: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainHostdevSubsysSCSIHostDefParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 15:51:29 +0000 (17:51 +0200)]
virDomainHostdevSubsysSCSIHostDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainDeviceDimmAddressParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 15:51:28 +0000 (17:51 +0200)]
virDomainDeviceDimmAddressParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirxml: Add virXMLPropULongLong
Tim Wiederhake [Wed, 21 Apr 2021 15:51:27 +0000 (17:51 +0200)]
virxml: Add virXMLPropULongLong

Convenience function to return the value of an unsigned long long XML
attribute.

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agoqemuAppendKeyWrapMachineParm: Stricten parameter types
Tim Wiederhake [Wed, 21 Apr 2021 15:51:26 +0000 (17:51 +0200)]
qemuAppendKeyWrapMachineParm: Stricten parameter types

Follow up to the last patch.

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainKeyWrapDef: Make members virTristateSwitch
Tim Wiederhake [Wed, 21 Apr 2021 15:51:25 +0000 (17:51 +0200)]
virDomainKeyWrapDef: Make members virTristateSwitch

With the last usage of `aes` and `dea` as int gone, these two can
become virTristateSwitch.

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainKeyWrapCipherDefParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 15:51:24 +0000 (17:51 +0200)]
virDomainKeyWrapCipherDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agospec: Drop -bash-completion package
Andrea Bolognani [Tue, 20 Apr 2021 16:54:58 +0000 (18:54 +0200)]
spec: Drop -bash-completion package

It's now empty, so no point in keeping it around.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agotools: Generate per-command bash completion script
Andrea Bolognani [Mon, 19 Apr 2021 16:40:14 +0000 (18:40 +0200)]
tools: Generate per-command bash completion script

The current setup uses a single script that is symlinked twice
and that tries to configure bash completion for both virsh and
virt-admin, even if only one of them is installed. This also
forces us to have a -bash-completion RPM package that only
contains the tiny shared file.

Rework bash completion support so that two scripts are
generated, each one tailored to a specific command.

Since the shared script no longer exists after this change,
the corresponding RPM package becomes empty.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agospec: Move systemtap probes from -client to -libs
Andrea Bolognani [Mon, 19 Apr 2021 16:31:10 +0000 (18:31 +0200)]
spec: Move systemtap probes from -client to -libs

Any application that uses the libraries can take advantage of
the systemtap probes, so they should be shipped in the -libs
package rather than in -client.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agospec: Move some files from -client to -daemon
Andrea Bolognani [Mon, 19 Apr 2021 16:29:25 +0000 (18:29 +0200)]
spec: Move some files from -client to -daemon

The -client package's purpose is enabling remote machines to
connect to a virtualization host, but the virt-host-validate
and libvirt-guests tools are designed to be run directly on
the virtualization host and as such are a better fit for the
-daemon package.

With this change, installing and removing the -client package
no longer needs to touch the systemd configuration.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agospec: Merge -admin package into -daemon
Andrea Bolognani [Mon, 19 Apr 2021 16:23:12 +0000 (18:23 +0200)]
spec: Merge -admin package into -daemon

It's useful to have virt-admin around when debugging issues
with libvirtd, and since it's a tiny binary we can simply
include it in the -daemon package to ensure it's always going
to be available when needed.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agodocs: Expand upon the contents of the -daemon package
Andrea Bolognani [Tue, 20 Apr 2021 16:00:24 +0000 (18:00 +0200)]
docs: Expand upon the contents of the -daemon package

It doesn't only contain the libvirtd binary.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agodocs: Use consistent vertical spacing
Andrea Bolognani [Tue, 20 Apr 2021 15:54:55 +0000 (17:54 +0200)]
docs: Use consistent vertical spacing

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agobash-completion: Fix argument passing to $1
Michal Privoznik [Tue, 20 Apr 2021 13:03:16 +0000 (15:03 +0200)]
bash-completion: Fix argument passing to $1

Our vsh bash completion string is merely just a wrapper over
virsh/virt-admin complete (cmdComplete) - a hidden command that
uses internal readline completion to generate list of candidates.
But this means that we have to pass some additional arguments to
the helper process: e.g. connection URI and R/O flag.

Candidates are printed on a separate line each (and can contain
space), which means that when bash is reading the helper's output
into an array, it needs to split items on '\n' char - hence the
IFS=$'\n' prefix on the line executing the helper. This was
introduced in b889594a70.

But this introduced a regression - those extra arguments we might
pass are stored in a string and previously were split on a space
character (because $IFS was kept untouched and by default
contains space). But now, after the fix that's no longer the case
and thus virsh/virt-admin sees ' -r -c URI' as one argument.

The solution is to take $IFS out of the picture by storing the
extra arguments in an array instead of string.

Fixes: b889594a7092440dc916e3f43eeeaca2684571ee
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Erik Skultety <eskultet@redhat.com>
4 years agoqemu: virtiofs: support <sandbox mode='chroot'/>
Cole Robinson [Fri, 26 Mar 2021 16:58:28 +0000 (12:58 -0400)]
qemu: virtiofs: support <sandbox mode='chroot'/>

This maps to `virtiofsd -o sandbox=chroot|namespace`, which was added
in qemu 5.2.0:

https://git.qemu.org/?p=qemu.git;a=commit;h=06844584b62a43384642f7243b0fc01c9fff0fc7

Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
4 years agoconf: Introduce <sandbox mode='chroot'/> for <filesystem><binary>
Cole Robinson [Fri, 26 Mar 2021 15:24:37 +0000 (11:24 -0400)]
conf: Introduce <sandbox mode='chroot'/> for <filesystem><binary>

This adds a new XML element

<filesystem>
  <binary>
    <sandbox mode='chroot|namespace'/>
  </binary>
</filesystem>

This will be used by qemu virtiofs

Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
Signed-off-by: Cole Robinson <crobinso@redhat.com>
4 years agostorage_backend_fs: use MKFS ony if WITH_STORAGE_FS is defined
Pavel Hrdina [Wed, 21 Apr 2021 13:31:12 +0000 (15:31 +0200)]
storage_backend_fs: use MKFS ony if WITH_STORAGE_FS is defined

The code in storage_backend_fs is used for storage_dir and storage_fs
drivers so some parts need to be guarded by checking for
WITH_STORAGE_FS.

Fixes: 16c69e7aaed4cabfd8e8c19cc326854d4c480437
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
4 years agovirDomainLoaderDefParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:32 +0000 (15:33 +0200)]
virDomainLoaderDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainVsockDefParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:31 +0000 (15:33 +0200)]
virDomainVsockDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainVideoResolutionDefParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:30 +0000 (15:33 +0200)]
virDomainVideoResolutionDefParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainAudioJackParse: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:29 +0000 (15:33 +0200)]
virDomainAudioJackParse: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainChrSourceDefParseLog: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:28 +0000 (15:33 +0200)]
virDomainChrSourceDefParseLog: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainChrSourceDefParseFile: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:27 +0000 (15:33 +0200)]
virDomainChrSourceDefParseFile: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainDiskSourceNVMeParse: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:26 +0000 (15:33 +0200)]
virDomainDiskSourceNVMeParse: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainDeviceISAAddressParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:25 +0000 (15:33 +0200)]
virDomainDeviceISAAddressParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainDeviceBootParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:24 +0000 (15:33 +0200)]
virDomainDeviceBootParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agovirDomainVirtioOptionsParseXML: Use virXMLProp*
Tim Wiederhake [Wed, 21 Apr 2021 13:33:23 +0000 (15:33 +0200)]
virDomainVirtioOptionsParseXML: Use virXMLProp*

Signed-off-by: Tim Wiederhake <twiederh@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
4 years agospec: Do not build qemu driver for Power on RHEL-9
Jiri Denemark [Wed, 21 Apr 2021 12:55:03 +0000 (14:55 +0200)]
spec: Do not build qemu driver for Power on RHEL-9

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

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
4 years agoqemu: add socket for virtiofs filesystems
Ján Tomko [Sat, 13 Feb 2021 12:22:56 +0000 (13:22 +0100)]
qemu: add socket for virtiofs filesystems

Copy the socket path in qemuExtDevicesStart, because
for libvirt-managed virtiofsd daemons the path is filled there
in qemuVirtioFSStart.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>