[libvirt] [PATCH 0/7] Fix SASL authentication regression
by Ján Tomko
Introduced by commit 9b45c9f, released in v1.3.5.
https://bugzilla.redhat.com/show_bug.cgi?id=1345743
Ján Tomko (7):
Revert "virnetsocket: Provide socket address format in a more standard
form"
Introduce virNetSocketRemoteAddrStringURI
Introduce virNetServerClientRemoteAddrStringURI
virnetsockettest: fix error messages
virNetSocket: rename AddrStr to AddrStrSASL
Add SASL to virNetSocket{Local,Remote}AddrString
Rename virNetServerClient*AddrString
daemon/remote.c | 13 ++-----------
src/libvirt_remote.syms | 10 ++++++----
src/remote/remote_driver.c | 7 -------
src/rpc/virnetclient.c | 14 ++------------
src/rpc/virnetclient.h | 2 --
src/rpc/virnetserver.c | 2 +-
src/rpc/virnetserverclient.c | 21 +++++++--------------
src/rpc/virnetserverclient.h | 7 +++----
src/rpc/virnetsocket.c | 41 +++++++++++++++++++----------------------
src/rpc/virnetsocket.h | 7 +++----
tests/virnetsockettest.c | 26 ++++++++++++++++++--------
11 files changed, 61 insertions(+), 89 deletions(-)
--
2.7.3
8 years, 5 months
[libvirt] [PATCH v3 0/5] bhyve: virConnectDomainXMLFromNative
by Fabian Freyer
Differences to v2:
- style fixes (C-style comments, function naming)
- removed unnecessary break
- added commentary on why __GNU_C_PREREQ is defined
- Set Domain virtType = VIR_DOMAIN_VIRT_BHYVE
- Free domain definition on error in bhyveParseCommandLineString. This
should prevent an empty XML document to be returned.
Link to v2:
https://www.redhat.com/archives/libvir-list/2016-June/msg00728.html
Link to v1:
https://www.redhat.com/archives/libvir-list/2016-June/msg00001.html
Fabian Freyer (5):
config-post.h: define __GNUC_PREREQ if not defined
gnulib: add getopt module
bhyve: implement virConnectDomainXMLFromNative
bhyve: implement bhyve argument parser
bhyve: implement argument parser for loader
bootstrap.conf | 1 +
config-post.h | 18 +
m4/virt-driver-bhyve.m4 | 3 +
po/POTFILES.in | 1 +
src/Makefile.am | 2 +
src/bhyve/bhyve_driver.c | 42 ++
src/bhyve/bhyve_parse_command.c | 877 ++++++++++++++++++++++++++++++++++++++++
src/bhyve/bhyve_parse_command.h | 30 ++
8 files changed, 974 insertions(+)
create mode 100644 src/bhyve/bhyve_parse_command.c
create mode 100644 src/bhyve/bhyve_parse_command.h
--
2.7.0
8 years, 5 months
[libvirt] [PATCH] storage: Remove redundant refreshPool check
by Cole Robinson
Every driver provides a refreshPool impl, and many other critical
places in the code unconditionally call it without checking if
it exists, so this check is pointless
---
src/storage/storage_driver.c | 16 +++++++---------
1 file changed, 7 insertions(+), 9 deletions(-)
diff --git a/src/storage/storage_driver.c b/src/storage/storage_driver.c
index e2d729f..4b5419d 100644
--- a/src/storage/storage_driver.c
+++ b/src/storage/storage_driver.c
@@ -2422,20 +2422,18 @@ storageVolUpload(virStorageVolPtr obj,
goto cleanup;
}
- /* If we have a refreshPool, use the callback routine in order to
+ /* Use the callback routine in order to
* refresh the pool after the volume upload stream closes. This way
* we make sure the volume and pool data are refreshed without user
* interaction and we can just lookup the backend in the callback
* routine in order to call the refresh API.
*/
- if (backend->refreshPool) {
- if (VIR_ALLOC(cbdata) < 0 ||
- VIR_STRDUP(cbdata->pool_name, pool->def->name) < 0)
- goto cleanup;
- if (vol->target.type == VIR_STORAGE_VOL_PLOOP &&
- VIR_STRDUP(cbdata->vol_path, vol->target.path) < 0)
- goto cleanup;
- }
+ if (VIR_ALLOC(cbdata) < 0 ||
+ VIR_STRDUP(cbdata->pool_name, pool->def->name) < 0)
+ goto cleanup;
+ if (vol->target.type == VIR_STORAGE_VOL_PLOOP &&
+ VIR_STRDUP(cbdata->vol_path, vol->target.path) < 0)
+ goto cleanup;
if ((ret = backend->uploadVol(obj->conn, pool, vol, stream,
offset, length, flags)) < 0)
--
2.7.4
8 years, 5 months
[libvirt] [PATCH 00/19] Add support for LUKS encrypted devices
by John Ferlan
See RFC:
http://www.redhat.com/archives/libvir-list/2016-June/msg00312.html
For: https://bugzilla.redhat.com/show_bug.cgi?id=1301021
Changes since RFC:
1. Address Dan's comment regarding providing secinfo objects for both
secret for RBD as well as secret for LUKS
2. Remove code from secret/secret_util.{h,c} and need for including
"secret/secret_util.h" (as well as cfg.mk change)
3. Change secret usage name from "luks" to "key". The "key" secret type
will be reused for work I have in other local trees (eg. TLS)
4. Reorder the patches a bit. Patches 1-9 are more or less setup
for patches 10-19.
John Ferlan (19):
storage: Adjust qemu-img switches check
storage: Create helper to set backing for CreateQemuImg code
storage: Create helper to set options for CreateQemuImg code
storage: Use virSecretGetSecretString
secret: Move virStorageSecretType and rename
util: Move and rename virStorageAuthDefParseSecret
util: Introduce virSecretFormatSecret
qemu: Change protocol parameter for secret setup
qemu: Remove authdef from secret setup
tests: Adjust tests for encrypted storage
util: Add 'usage' for encryption
util: Modify the FileTypeInfo for meta data checks
util: Add 'luks' to the FileTypeInfo
conf: Add new secret type "key"
encryption: Add luks parsing for storageencryption
encryption: Add <cipher> and <ivgen> to encryption
storage: Add support to create a luks volume
qemu: Add new secret info type
qemu: Add luks support for domain disk
docs/aclpolkit.html.in | 4 +
docs/formatsecret.html.in | 62 ++-
docs/formatstorageencryption.html.in | 115 ++++-
docs/schemas/secret.rng | 10 +
docs/schemas/storagecommon.rng | 58 ++-
include/libvirt/libvirt-secret.h | 3 +-
po/POTFILES.in | 1 +
src/Makefile.am | 2 +
src/access/viraccessdriverpolkit.c | 13 +
src/conf/domain_conf.c | 11 +
src/conf/secret_conf.c | 26 +-
src/conf/secret_conf.h | 3 +-
src/conf/virsecretobj.c | 5 +
src/libvirt_private.syms | 8 +
src/libxl/libxl_conf.c | 2 +-
src/qemu/qemu_command.c | 12 +-
src/qemu/qemu_domain.c | 148 ++++---
src/qemu/qemu_domain.h | 5 +
src/qemu/qemu_process.c | 19 +-
src/secret/secret_util.c | 18 +-
src/secret/secret_util.h | 10 +-
src/storage/storage_backend.c | 480 +++++++++++++++------
src/storage/storage_backend.h | 3 +-
src/storage/storage_backend_fs.c | 10 +-
src/storage/storage_backend_gluster.c | 2 +
src/storage/storage_backend_iscsi.c | 54 +--
src/storage/storage_backend_rbd.c | 49 +--
src/util/virendian.h | 24 ++
src/util/virqemu.c | 23 +
src/util/virqemu.h | 6 +
src/util/virsecret.c | 127 ++++++
src/util/virsecret.h | 56 +++
src/util/virstorageencryption.c | 156 ++++++-
src/util/virstorageencryption.h | 18 +-
src/util/virstoragefile.c | 196 ++++-----
src/util/virstoragefile.h | 18 +-
tests/qemuargv2xmltest.c | 4 +-
.../qemuxml2argv-encrypted-disk-usage.args | 24 ++
.../qemuxml2argv-encrypted-disk-usage.xml | 32 ++
.../qemuxml2argv-encrypted-disk.args | 26 +-
.../qemuxml2argv-encrypted-disk.xml | 4 +-
.../qemuxml2argv-luks-disk-cipher.args | 36 ++
.../qemuxml2argv-luks-disk-cipher.xml | 41 ++
.../qemuxml2argvdata/qemuxml2argv-luks-disks.args | 36 ++
tests/qemuxml2argvdata/qemuxml2argv-luks-disks.xml | 41 ++
tests/qemuxml2argvtest.c | 14 +-
.../qemuxml2xmlout-encrypted-disk-usage.xml | 36 ++
.../qemuxml2xmlout-encrypted-disk.xml | 4 +-
.../qemuxml2xmlout-luks-disk-cipher.xml | 45 ++
.../qemuxml2xmlout-luks-disks.xml | 45 ++
tests/qemuxml2xmltest.c | 3 +
tests/secretxml2xmlin/usage-key.xml | 7 +
tests/secretxml2xmltest.c | 1 +
tests/storagevolxml2argvdata/qcow2-flag.argv | 2 -
.../qcow2-nobacking-convert-flag.argv | 2 -
.../qcow2-nobacking-convert-none.argv | 2 -
.../qcow2-nobacking-flag.argv | 1 -
.../qcow2-nobacking-none.argv | 1 -
tests/storagevolxml2argvdata/qcow2-none.argv | 1 -
tests/storagevolxml2argvtest.c | 25 +-
tests/storagevolxml2xmlin/vol-luks-cipher.xml | 23 +
tests/storagevolxml2xmlin/vol-luks.xml | 21 +
tests/storagevolxml2xmlout/vol-luks-cipher.xml | 23 +
tests/storagevolxml2xmlout/vol-luks.xml | 21 +
tests/storagevolxml2xmltest.c | 2 +
tests/virendiantest.c | 18 +
66 files changed, 1792 insertions(+), 506 deletions(-)
create mode 100644 src/util/virsecret.c
create mode 100644 src/util/virsecret.h
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-encrypted-disk-usage.args
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-encrypted-disk-usage.xml
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-luks-disk-cipher.args
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-luks-disk-cipher.xml
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-luks-disks.args
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-luks-disks.xml
create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-encrypted-disk-usage.xml
create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-luks-disk-cipher.xml
create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-luks-disks.xml
create mode 100644 tests/secretxml2xmlin/usage-key.xml
delete mode 100644 tests/storagevolxml2argvdata/qcow2-flag.argv
delete mode 100644 tests/storagevolxml2argvdata/qcow2-nobacking-convert-flag.argv
delete mode 100644 tests/storagevolxml2argvdata/qcow2-nobacking-convert-none.argv
delete mode 100644 tests/storagevolxml2argvdata/qcow2-nobacking-flag.argv
delete mode 100644 tests/storagevolxml2argvdata/qcow2-nobacking-none.argv
delete mode 100644 tests/storagevolxml2argvdata/qcow2-none.argv
create mode 100644 tests/storagevolxml2xmlin/vol-luks-cipher.xml
create mode 100644 tests/storagevolxml2xmlin/vol-luks.xml
create mode 100644 tests/storagevolxml2xmlout/vol-luks-cipher.xml
create mode 100644 tests/storagevolxml2xmlout/vol-luks.xml
--
2.5.5
8 years, 5 months
[libvirt] [PATCH 0/3] qmp: query-host-cpu command
by Eduardo Habkost
Add QMP command to allow management software to query for
CPU information for the running host.
The data returned by the command is in the form of a dictionary
of QOM properties.
This series depends on the "Add runnability info to
query-cpu-definitions" series I sent 2 weeks ago.
Git tree:
https://github.com/ehabkost/qemu-hacks.git work/query-host-cpu
Example output for x86:
{
"qom-properties": {
"pfthreshold": false,
"pku": false,
"rtm": false,
"tsc-deadline": true,
"xstore-en": false,
"cpuid-0xb": true,
"abm": true,
"ia64": false,
"kvm-mmu": false,
"xsaveopt": true,
"hv-spinlocks": -1,
"hotpluggable": true,
"tce": false,
"smep": true,
"nx": true,
"xcrypt": false,
"sse4_2": true,
"clflush": true,
"sse4_1": true,
"flushbyasid": false,
"kvm-steal-time": true,
"host-cache-info": false,
"tsc": true,
"adx": false,
"ds": false,
"fxsr": true,
"tm": false,
"hv-relaxed": false,
"pclmuldq": true,
"xgetbv1": false,
"xstore": false,
"migratable": true,
"vme": true,
"vendor": "GenuineIntel",
"arat": true,
"ffxsr": false,
"de": true,
"aes": true,
"pse": true,
"ds-cpl": false,
"tbm": false,
"sse": true,
"phe-en": false,
"f16c": true,
"hotplugged": true,
"mpx": false,
"tsc-adjust": true,
"avx512f": false,
"avx2": true,
"misalignsse": false,
"level": 13,
"pbe": false,
"cx16": true,
"avx512pf": false,
"movbe": true,
"perfctr-nb": false,
"enforce": false,
"ospke": false,
"pmu": true,
"fma4": false,
"stepping": 1,
"feature-words": [
{
"cpuid-register": "EAX",
"cpuid-input-eax": 6,
"features": 4
},
{
"cpuid-register": "EAX",
"cpuid-input-eax": 13,
"features": 1,
"cpuid-input-ecx": 1
},
{
"cpuid-register": "EDX",
"cpuid-input-eax": 2147483658,
"features": 0
},
{
"cpuid-register": "EAX",
"cpuid-input-eax": 1073741825,
"features": 16777467
},
{
"cpuid-register": "EDX",
"cpuid-input-eax": 3221225473,
"features": 0
},
{
"cpuid-register": "EDX",
"cpuid-input-eax": 2147483655,
"features": 0
},
{
"cpuid-register": "ECX",
"cpuid-input-eax": 2147483649,
"features": 33
},
{
"cpuid-register": "EDX",
"cpuid-input-eax": 2147483649,
"features": 739248128
},
{
"cpuid-register": "ECX",
"cpuid-input-eax": 7,
"features": 0,
"cpuid-input-ecx": 0
},
{
"cpuid-register": "EBX",
"cpuid-input-eax": 7,
"features": 1963,
"cpuid-input-ecx": 0
},
{
"cpuid-register": "ECX",
"cpuid-input-eax": 1,
"features": 4160369155
},
{
"cpuid-register": "EDX",
"cpuid-input-eax": 1,
"features": 260832255
}
],
"sse4a": false,
"i64": true,
"xsave": true,
"hv-runtime": false,
"pmm": false,
"hle": false,
"hv-crash": false,
"est": false,
"xop": false,
"smx": false,
"tsc-scale": false,
"monitor": false,
"avx512er": false,
"apic": true,
"sse4.1": true,
"sse4.2": true,
"hv-vapic": false,
"pause-filter": false,
"lahf-lm": true,
"kvm-nopiodelay": true,
"acpi": false,
"mmx": true,
"osxsave": false,
"pcommit": false,
"clwb": false,
"dca": false,
"pdcm": false,
"xcrypt-en": false,
"3dnow": false,
"invtsc": false,
"tm2": false,
"hv-time": false,
"hypervisor": true,
"kvmclock-stable-bit": true,
"xlevel": 2147483656,
"fxsr-opt": false,
"pcid": true,
"lbrv": false,
"wdt": false,
"svm-lock": false,
"popcnt": true,
"nrip-save": false,
"x2apic": true,
"kvmclock": true,
"smap": false,
"pdpe1gb": true,
"family": 6,
"xlevel2": 0,
"dtes64": false,
"xd": true,
"ace2": false,
"xtpr": false,
"lwp": false,
"sep": true,
"msr": true,
"syscall": true,
"decodeassists": false,
"perfctr-core": false,
"pge": true,
"pn": false,
"fma": true,
"nodeid-msr": false,
"hv-vpindex": false,
"cx8": true,
"mce": true,
"avx512cd": false,
"cr8legacy": false,
"mca": true,
"pni": true,
"hv-vendor-id": "",
"rdseed": false,
"osvw": false,
"fsgsbase": true,
"model-id": "Intel(R) Core(TM) i7-4600U CPU @ 2.10GHz",
"cmp-legacy": false,
"kvm-pv-unhalt": true,
"rdtscp": true,
"mmxext": false,
"cid": false,
"type": "host-x86_64-cpu",
"vmx": false,
"ssse3": true,
"extapic": false,
"pse36": true,
"mtrr": true,
"ibs": false,
"avx": true,
"ace2-en": false,
"invpcid": true,
"bmi2": true,
"vmcb-clean": false,
"erms": true,
"cmov": true,
"check": true,
"parent_bus": "",
"clflushopt": false,
"pat": true,
"hv-synic": false,
"hv-stimer": false,
"3dnowprefetch": false,
"fpu": true,
"pae": true,
"hv-reset": false,
"skinit": false,
"kvm": true,
"pmm-en": false,
"phe": false,
"3dnowext": false,
"ht": false,
"tsc-frequency": 0,
"kvm-pv-eoi": true,
"npt": false,
"apic-id": -1,
"xsavec": false,
"lm": true,
"pclmulqdq": true,
"svm": false,
"sse3": true,
"sse2": true,
"ss": true,
"topoext": false,
"rdrand": true,
"bmi1": true,
"kvm-asyncpf": true,
"xsaves": false,
"model": 69
}
}
Eduardo Habkost (3):
qmp: Add query-host-cpu command
target-i386: Introduce x86_cpu_load_host_data() function
target-i386: Implement arch_query_host_cpu_info()
include/sysemu/arch_init.h | 1 +
qapi-schema.json | 36 +++++++++++++++++
qmp-commands.hx | 6 +++
qmp.c | 13 ++++++
stubs/Makefile.objs | 1 +
stubs/arch-query-host-cpu-info.c | 8 ++++
target-i386/cpu.c | 87 ++++++++++++++++++++++++++++++++++++----
7 files changed, 145 insertions(+), 7 deletions(-)
create mode 100644 stubs/arch-query-host-cpu-info.c
--
2.5.5
8 years, 5 months
[libvirt] [PATCH v4 00/14] Add native TLS encrypted chardev TCP support
by John Ferlan
v3: http://www.redhat.com/archives/libvir-list/2016-June/msg01094.html
Yes, I know another long series, but there are some duplicates with the
LUKS series:
http://www.redhat.com/archives/libvir-list/2016-June/msg01691.html
In particular:
Patches 1-3 match the LUKS patches 1-3
Patches 4-6 match the LUKS patches 12-14
They are needed for "parts" for this series.
Changes since v3:
Patches 7-10 are patches 1-4 of the v3 series with perhaps a few adjustments
these were reviewed and had partial ACK's see the v3 series cover for details
Patches 11->14 are NEW.
Patch 11 needs the "passphrase" secret from LUKS in order to allow the
addition of a <secret> for a <serial type='tcp'...> to provide the passphrase
for the TLS environment.
Patch 12 provides the means (like Disk and Hostdev) to store the secinfo
required to generate an AES secret
Patch 13 adds the secret for the command line startup
Patch 14 could be combined w/ 13, but I just kept it a separate way to
add the secret for the hotplug (and unplug)
John Ferlan (14):
qemu: Change protocol parameter for secret setup
qemu: Remove authdef from secret setup
conf: Add new secret type "passphrase"
qemu: Remove type from qemuBuildSecretInfoProps
qemu: Make qemuBuildSecretInfoProps global
qemu: Add secinfo for hotplug virtio disk
conf: Add new default TLS X.509 certificate default directory
conf: Introduce chartcp_tls_x509_cert_dir
qemu: Add support for TLS X.509 path to TCP chardev backend
qemu: Add the ability to hotplug the TLS X.509 environment
conf: Add new secret element for tcp chardev
qemu: Introduce qemuDomainChardevPrivatePtr
qemu: Add a secret object to/for a chardev tcp with secret
qemu: Add the ability to hotplug a secret object for TCP chardev TLS
docs/aclpolkit.html.in | 4 +
docs/formatdomain.html.in | 29 +++
docs/formatsecret.html.in | 57 +++++-
docs/schemas/domaincommon.rng | 21 +++
docs/schemas/secret.rng | 10 +
include/libvirt/libvirt-secret.h | 3 +-
src/access/viraccessdriverpolkit.c | 13 ++
src/conf/domain_conf.c | 62 ++++++-
src/conf/domain_conf.h | 8 +-
src/conf/secret_conf.c | 26 ++-
src/conf/secret_conf.h | 1 +
src/conf/virsecretobj.c | 5 +
src/libxl/libxl_domain.c | 2 +-
src/lxc/lxc_native.c | 2 +-
src/qemu/libvirtd_qemu.aug | 11 +-
src/qemu/qemu.conf | 83 +++++++--
src/qemu/qemu_command.c | 148 ++++++++++++++-
src/qemu/qemu_command.h | 13 ++
src/qemu/qemu_conf.c | 59 +++++-
src/qemu/qemu_conf.h | 7 +
src/qemu/qemu_domain.c | 202 +++++++++++++++------
src/qemu/qemu_domain.h | 22 +++
src/qemu/qemu_driver.c | 2 +-
src/qemu/qemu_hotplug.c | 141 ++++++++++++--
src/qemu/qemu_hotplug.h | 3 +-
src/qemu/qemu_monitor_json.c | 9 +
src/qemu/qemu_parse_command.c | 4 +-
src/qemu/qemu_process.c | 2 +-
src/qemu/test_libvirtd_qemu.aug.in | 5 +
src/vz/vz_sdk.c | 2 +-
src/xenconfig/xen_sxpr.c | 2 +-
tests/qemuhotplugtest.c | 2 +-
.../qemuxml2argv-serial-tcp-tlsx509-chardev.args | 33 ++++
.../qemuxml2argv-serial-tcp-tlsx509-chardev.xml | 41 +++++
...xml2argv-serial-tcp-tlsx509-secret-chardev.args | 38 ++++
...uxml2argv-serial-tcp-tlsx509-secret-chardev.xml | 42 +++++
tests/qemuxml2argvtest.c | 14 ++
.../qemuxml2xmlout-serial-tcp-tlsx509-chardev.xml | 50 +++++
...ml2xmlout-serial-tcp-tlsx509-secret-chardev.xml | 51 ++++++
tests/qemuxml2xmltest.c | 2 +
tests/secretxml2xmlin/usage-passphrase.xml | 7 +
tests/secretxml2xmltest.c | 1 +
42 files changed, 1116 insertions(+), 123 deletions(-)
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-serial-tcp-tlsx509-chardev.args
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-serial-tcp-tlsx509-chardev.xml
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-serial-tcp-tlsx509-secret-chardev.args
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-serial-tcp-tlsx509-secret-chardev.xml
create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-serial-tcp-tlsx509-chardev.xml
create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-serial-tcp-tlsx509-secret-chardev.xml
create mode 100644 tests/secretxml2xmlin/usage-passphrase.xml
--
2.5.5
8 years, 5 months
[libvirt] [PATCH 0/7] Create a util/virsecret and add key usage secret
by John Ferlan
Extracted from the LUKS series (patches 4-9 and patch 14):
http://www.redhat.com/archives/libvir-list/2016-June/msg00804.html
with a couple of modifications as I working through the TLS code...
1. Instead of looking the LookupDef 'secdef', call it 'seclookupdef'
(it's just clearer that way I think)
2. Likewise, change the ParseSecret and FormatSecret to add "Lookup"
John Ferlan (7):
storage: Use virSecretGetSecretString
secret: Move virStorageSecretType and rename
util: Move and rename virStorageAuthDefParseSecret
util: Introduce virSecretFormatSecret
qemu: Change protocol parameter for secret setup
qemu: Remove authdef from secret setup
conf: Add new secret type "key"
docs/aclpolkit.html.in | 4 ++
docs/formatsecret.html.in | 57 +++++++++++++++-
docs/schemas/secret.rng | 10 +++
include/libvirt/libvirt-secret.h | 3 +-
po/POTFILES.in | 1 +
src/Makefile.am | 2 +
src/access/viraccessdriverpolkit.c | 13 ++++
src/conf/secret_conf.c | 26 ++++++-
src/conf/secret_conf.h | 3 +-
src/conf/virsecretobj.c | 5 ++
src/libvirt_private.syms | 7 ++
src/libxl/libxl_conf.c | 2 +-
src/qemu/qemu_domain.c | 131 ++++++++++++++++++++++--------------
src/secret/secret_util.c | 18 ++---
src/secret/secret_util.h | 10 +--
src/storage/storage_backend_iscsi.c | 54 +++------------
src/storage/storage_backend_rbd.c | 49 ++------------
src/util/virsecret.c | 124 ++++++++++++++++++++++++++++++++++
src/util/virsecret.h | 56 +++++++++++++++
src/util/virstoragefile.c | 103 +++++++---------------------
src/util/virstoragefile.h | 17 +----
tests/qemuargv2xmltest.c | 4 +-
tests/secretxml2xmlin/usage-key.xml | 7 ++
tests/secretxml2xmltest.c | 1 +
24 files changed, 451 insertions(+), 256 deletions(-)
create mode 100644 src/util/virsecret.c
create mode 100644 src/util/virsecret.h
create mode 100644 tests/secretxml2xmlin/usage-key.xml
--
2.5.5
8 years, 5 months
[libvirt] [PATCH 0/2] Two more 'make check' speedups
by Ján Tomko
Do not generate random bignums and stop doing expensive
virsh tests by default.
Ján Tomko (2):
tests: mock gnutls_dh_params_generate2
tests: mark virsh-optparse and virsh-synopsis as expensive
tests/virnettlscontexttest.c | 2 +-
tests/virnettlssessiontest.c | 2 +-
tests/virrandommock.c | 12 ++++++++++++
tests/virsh-optparse | 2 ++
tests/virsh-synopsis | 2 ++
5 files changed, 18 insertions(+), 2 deletions(-)
--
2.7.3
8 years, 5 months
[libvirt] [libvirt-python][PATCH] Add support for virDomainGetGuestVcpus
by Michal Privoznik
This function has virTypedParameterPtr as one of the args and our
generator is unable to deal with that. Therefore we must provide
implementation.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
generator.py | 1 +
libvirt-override.c | 33 +++++++++++++++++++++++++++++++++
2 files changed, 34 insertions(+)
diff --git a/generator.py b/generator.py
index 92ac7a7..82f13e9 100755
--- a/generator.py
+++ b/generator.py
@@ -491,6 +491,7 @@ skip_impl = (
'virDomainInterfaceAddresses',
'virDomainGetPerfEvents',
'virDomainSetPerfEvents',
+ 'virDomainGetGuestVcpus',
)
lxc_skip_impl = (
diff --git a/libvirt-override.c b/libvirt-override.c
index 3075681..9c5dd84 100644
--- a/libvirt-override.c
+++ b/libvirt-override.c
@@ -8915,6 +8915,38 @@ libvirt_virConnectStoragePoolEventDeregisterAny(PyObject *self ATTRIBUTE_UNUSED,
return libvirt_intWrap(ret);
}
+
+static PyObject *
+libvirt_virDomainGetGuestVcpus(PyObject *self ATTRIBUTE_UNUSED,
+ PyObject *args)
+{
+ PyObject *pyobj_domain;
+ virDomainPtr domain;
+ virTypedParameterPtr params = NULL;
+ int nparams = 0;
+ unsigned int flags;
+ int i_retval;
+ PyObject *ret = NULL;
+
+ if (!PyArg_ParseTuple(args, (char *)"OI:virDomainGetScedulerParametersFlags",
+ &pyobj_domain, &flags))
+ return NULL;
+ domain = (virDomainPtr) PyvirDomain_Get(pyobj_domain);
+
+ LIBVIRT_BEGIN_ALLOW_THREADS;
+ i_retval = virDomainGetGuestVcpus(domain, ¶ms, &nparams, flags);
+ LIBVIRT_END_ALLOW_THREADS;
+
+ if (i_retval < 0) {
+ ret = VIR_PY_NONE;
+ goto cleanup;
+ }
+
+ ret = getPyVirTypedParameter(params, nparams);
+ cleanup:
+ virTypedParamsFree(params, nparams);
+ return ret;
+}
#endif /* LIBVIR_CHECK_VERSION(2, 0, 0)*/
@@ -9128,6 +9160,7 @@ static PyMethodDef libvirtMethods[] = {
#if LIBVIR_CHECK_VERSION(2, 0, 0)
{(char *) "virConnectStoragePoolEventRegisterAny", libvirt_virConnectStoragePoolEventRegisterAny, METH_VARARGS, NULL},
{(char *) "virConnectStoragePoolEventDeregisterAny", libvirt_virConnectStoragePoolEventDeregisterAny, METH_VARARGS, NULL},
+ {(char *) "virDomainGetGuestVcpus", libvirt_virDomainGetGuestVcpus, METH_VARARGS, NULL},
#endif /* LIBVIR_CHECK_VERSION(2, 0, 0) */
{NULL, NULL, 0, NULL}
};
--
2.8.4
8 years, 5 months