[libvirt] [PATCH 0/4] Misc travis improvements

2018-02-23 Thread Daniel P . Berrangé
Various improvements to travis coverage. The first patch was posted separately yesterday too. Daniel P. Berrangé (4): travis: add a scenario for running make distcheck travis: make all builds use VPATH travis: test upstart script handling on precise distro scenario travis: run 'make

[libvirt] [PATCH 4/4] travis: run 'make install' during build tests

2018-02-23 Thread Daniel P . Berrangé
Running 'make install' is important to catch some VPATH problems Signed-off-by: Daniel P. Berrangé <berra...@redhat.com> --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 0328fcb8f1..61f0e38d40 100644 --- a/.travis.yml

[libvirt] [PATCH 1/4] travis: add a scenario for running make distcheck

2018-02-23 Thread Daniel P . Berrangé
Running "make distcheck" ensures that we have CLEANFILES and uninstall rules setup correctly, as well as validating VPATH builds succeeed. Signed-off-by: Daniel P. Berrangé <berra...@redhat.com> --- .travis.yml | 5 + 1 file changed, 5 insertions(+) diff --git a/.travis.y

[libvirt] [PATCH 3/4] travis: test upstart script handling on precise distro scenario

2018-02-23 Thread Daniel P . Berrangé
Signed-off-by: Daniel P. Berrangé <berra...@redhat.com> --- .travis.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 41a293451c..0328fcb8f1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,6 +6,8 @@ matrix: include: - compile

[libvirt] [PATCH] make: fix another VPATH bug impacting install of sysconf files

2018-02-22 Thread Daniel P . Berrangé
Signed-off-by: Daniel P. Berrangé <berra...@redhat.com> --- Pushed as build fix src/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Makefile.am b/src/Makefile.am index 2166e17dbe..8ceeda5756 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -

[libvirt] [PATCH jenkins-ci] Fix workspace for python check/rpm jobs

2018-02-23 Thread Daniel P . Berrangé
The check/rpm jobs were using a different workspace to the build job, so never saw the correct content. Signed-off-by: Daniel P. Berrangé <berra...@redhat.com> --- Pushed as a build fix for virt-manager CI jobs/python-distutils.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 del

Re: [libvirt] [jenkins-ci PATCH 2/2] jobs: Switch to github webhook instead of polling

2018-06-21 Thread Daniel P . Berrangé
On Thu, Jun 21, 2018 at 03:37:49PM +0200, Andrea Bolognani wrote: > On Thu, 2018-06-21 at 14:21 +0200, Pavel Hrdina wrote: > [...] > > @@ -31,8 +31,7 @@ > > triggers: > >- reverse: > >jobs: '{obj:parent_jobs}' > > - - pollscm: > > - cron: "H/20 * * * *" > > +

[libvirt] [PATCH] qemu: ensure FDs passed to QEMU for chardevs have correct SELinux labels

2018-06-22 Thread Daniel P . Berrangé
The UNIX socket FDs were we passing to QEMU inherited a label based on libvirtd's context. QEMU is thus denied ability to access the UNIX socket. We need to use the security manager to change our current context temporarily when creating the UNIX socket FD. Signed-off-by: Daniel P. Berrangé

Re: [libvirt] [PATCH v3 16/20] nwfilter: keep track of active filter bindings

2018-06-22 Thread Daniel P . Berrangé
On Mon, Jun 18, 2018 at 04:59:12PM -0400, John Ferlan wrote: > > > On 06/14/2018 08:33 AM, Daniel P. Berrangé wrote: > > Currently the nwfilter driver does not keep any record of what filter > > bindings it has active. This means that when it needs to recreate > &

Re: [libvirt] [PATCH v3 14/20] conf: introduce a virNWFilterBindingObjPtr struct

2018-06-22 Thread Daniel P . Berrangé
On Mon, Jun 18, 2018 at 10:08:00AM -0400, John Ferlan wrote: > > > On 06/14/2018 08:33 AM, Daniel P. Berrangé wrote: > > Introduce a new struct to act as the stateful owner of the > > virNWFilterBindingDefPtr objects. > > > > Signed-off-by: Daniel P

Re: [libvirt] [PATCH v3 17/20] nwfilter: remove virt driver callback layer for rebuilding filters

2018-06-22 Thread Daniel P . Berrangé
On Mon, Jun 18, 2018 at 04:59:37PM -0400, John Ferlan wrote: > > > On 06/14/2018 08:33 AM, Daniel P. Berrangé wrote: > > Now that the nwfilter driver keeps a list of bindings that it has > > created, there is no need for the complex virt driver callbacks. It is > >

Re: [libvirt] [PATCH v3 09/20] virsh: add nwfilter binding commands

2018-06-22 Thread Daniel P . Berrangé
On Sun, Jun 17, 2018 at 08:27:27AM -0400, John Ferlan wrote: > > > On 06/14/2018 08:32 AM, Daniel P. Berrangé wrote: > > $ virsh nwfilter-binding-list > > Port Dev Filter > > --

Re: [libvirt] [PATCH v3 11/20] nwfilter: convert IP address learning code to virNWFilterBindingDefPtr

2018-06-22 Thread Daniel P . Berrangé
On Sun, Jun 17, 2018 at 08:28:11AM -0400, John Ferlan wrote: > > > On 06/14/2018 08:33 AM, Daniel P. Berrangé wrote: > > Use the virNWFilterBindingDefPTr struct in the IP address learning code > > directly. > > > > Reviewed-by: John Ferlan >

Re: [libvirt] [PATCH v3 19/20] nwfilter: wire up new APIs for creating and deleting nwfilter bindings

2018-06-22 Thread Daniel P . Berrangé
On Mon, Jun 18, 2018 at 04:59:50PM -0400, John Ferlan wrote: > > > On 06/14/2018 08:33 AM, Daniel P. Berrangé wrote: > > This allows the virsh commands nwfilter-binding-create and > > nwfilter-binding-delete to be used. > > > > Note using these commands

[libvirt] [PATCH] rpm: simplify applying of patches

2018-08-03 Thread Daniel P . Berrangé
The distros we support for RPM builds all have %autosetup support so we can ditch the convoluted code for running git manually and use the RPM defaults. Signed-off-by: Daniel P. Berrangé --- libvirt.spec.in | 38 +- 1 file changed, 1 insertion(+), 37

[libvirt] [jenkins-ci PATCH] projects: restrict virt-viewer RPMs to Fedora >= 28

2018-07-30 Thread Daniel P . Berrangé
Signed-off-by: Daniel P. Berrangé --- projects/virt-viewer.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/projects/virt-viewer.yaml b/projects/virt-viewer.yaml index 12335f3..25474f2 100644 --- a/projects/virt-viewer.yaml +++ b/projects/virt-viewer.yaml @@ -13,7

Re: [libvirt] [PATCH for v4.6.0] cgroups: Don't leave stale pointers around after virCgroupFree

2018-07-30 Thread Daniel P . Berrangé
On Mon, Jul 30, 2018 at 12:47:37PM +0200, Erik Skultety wrote: > On Mon, Jul 30, 2018 at 11:35:02AM +0100, Daniel P. Berrangé wrote: > > On Mon, Jul 30, 2018 at 12:30:09PM +0200, Pavel Hrdina wrote: > > > On Mon, Jul 30, 2018 at 09:58:41AM +0100, Daniel P. Berrangé wrote: >

Re: [libvirt] [jenkins-ci PATCH] hosts_vars: drop virt-viewer from platforms with old spice-gtk

2018-07-30 Thread Daniel P . Berrangé
On Mon, Jul 30, 2018 at 12:17:56PM +0200, Andrea Bolognani wrote: > On Mon, 2018-07-30 at 10:04 +0100, Daniel P. Berrangé wrote: > > git master requires spice-gtk >= 0.35 > > > > Signed-off-by: Daniel P. Berrangé > > --- > > guests/host_vars/libvirt-centos

Re: [libvirt] [PATCH for v4.6.0] cgroups: Don't leave stale pointers around after virCgroupFree

2018-07-30 Thread Daniel P . Berrangé
On Mon, Jul 30, 2018 at 12:30:09PM +0200, Pavel Hrdina wrote: > On Mon, Jul 30, 2018 at 09:58:41AM +0100, Daniel P. Berrangé wrote: > > On Mon, Jul 30, 2018 at 09:48:51AM +0100, Daniel P. Berrangé wrote: > > > On Mon, Jul 30, 2018 at 10:25:05AM +0200, Michal Privoznik

Re: [libvirt] [RFC] secdrivers remembering original labels

2018-07-27 Thread Daniel P . Berrangé
On Fri, Jul 27, 2018 at 09:56:23AM +0200, Michal Privoznik wrote: > Dear list, > > we have this very old bug [1] that I just keep pushing in front of me. I > made several attempts to fix it. However, none of them made into the > tree. I guess it's time to have discussion what to do about it.

Re: [libvirt] [RFC] secdrivers remembering original labels

2018-07-27 Thread Daniel P . Berrangé
On Fri, Jul 27, 2018 at 01:27:40PM +0200, Michal Privoznik wrote: > On 07/27/2018 11:01 AM, Daniel P. Berrangé wrote: > > On Fri, Jul 27, 2018 at 09:56:23AM +0200, Michal Privoznik wrote: > >> Dear list, > >> > >> we have this very old bug [1] that I just keep

Re: [libvirt] [PATCH RFC 0/2] util: Add VIR_ENUM_IMPL_LABEL

2018-07-27 Thread Daniel P . Berrangé
On Fri, Jul 27, 2018 at 11:17:13AM +0200, Michal Privoznik wrote: > On 07/26/2018 07:49 PM, Cole Robinson wrote: > > This series adds VIR_ENUM_IMPL_LABEL and a demo conversion. > > > > VIR_ENUM_IMPL_LABEL allows passing in a string that briefly > > describes the value the enum represents, which

Re: [libvirt] [PATCH v3 1/3] qemuxml2argvtest: Set more fake drivers

2018-07-27 Thread Daniel P . Berrangé
On Fri, Jul 27, 2018 at 05:24:45PM +0200, Michal Privoznik wrote: > So far we are setting only fake secret and storage drivers. > Therefore if the code wants to call a public NWFilter API (like > qemuBuildInterfaceCommandLine() and qemuBuildNetCommandLine() are > doing) the virGetConnectNWFilter()

Re: [libvirt] [PATCH v2 RESEND 00/12] PCI passthrough support on s390

2018-07-26 Thread Daniel P . Berrangé
On Thu, Jul 26, 2018 at 01:47:52PM +0200, Andrea Bolognani wrote: > On Thu, 2018-07-26 at 12:22 +0100, Daniel P. Berrangé wrote: > > On Thu, Jul 26, 2018 at 07:17:03PM +0800, Yi Min Zhao wrote: > > > 在 2018/7/26 下午7:00, Andrea Bolognani 写道: > > > > From the t

Re: [libvirt] [PATCH v2 RESEND 00/12] PCI passthrough support on s390

2018-07-26 Thread Daniel P . Berrangé
On Thu, Jul 26, 2018 at 07:17:03PM +0800, Yi Min Zhao wrote: > > > 在 2018/7/26 下午7:00, Andrea Bolognani 写道: > > > > > > > > How does the pci-bridge controller show up in the guest, if at > > > > > > > > all? > > > > > Qemu hides pci-bridge devices and just exposes pci devices to the > > > > >

Re: [libvirt] Entering freeze for libvirt-4.6.0

2018-07-31 Thread Daniel P . Berrangé
On Tue, Jul 31, 2018 at 02:04:40PM +0200, Martin Kletzander wrote: > On Tue, Jul 31, 2018 at 10:26:41AM +0200, Michal Privoznik wrote: > > On 07/30/2018 05:20 PM, Andrea Bolognani wrote: > > > On Sat, 2018-07-28 at 21:56 +0800, Daniel Veillard wrote: > > > > > > > > > > > > Unfortunately I've

[libvirt] [PATCH] util: avoid symbol clash between json libraries

2018-07-31 Thread Daniel P . Berrangé
-off-by: Daniel P. Berrangé --- libvirt.spec.in | 2 + src/Makefile.am | 3 + src/util/Makefile.inc.am | 3 +- src/util/virjson.c | 9 +- src/util/virjsoncompat.c | 253 +++ src/util/virjsoncompat.h | 86 + 6 files

Re: [libvirt] Entering freeze for libvirt-4.6.0

2018-07-31 Thread Daniel P . Berrangé
On Tue, Jul 31, 2018 at 12:18:16PM +0200, Ján Tomko wrote: > On Tue, Jul 31, 2018 at 10:26:41AM +0200, Michal Privoznik wrote: > > On 07/30/2018 05:20 PM, Andrea Bolognani wrote: > > > On Sat, 2018-07-28 at 21:56 +0800, Daniel Veillard wrote: > > > > > > > > > > > > Unfortunately I've spotted

Re: [libvirt] [PATCH] util: avoid symbol clash between json libraries

2018-07-31 Thread Daniel P . Berrangé
On Tue, Jul 31, 2018 at 06:07:20PM +0200, Ján Tomko wrote: > On Tue, Jul 31, 2018 at 03:55:28PM +0100, Daniel P. Berrangé wrote: > > The jansson and json-glib libraries both export symbols with a json_ > > name prefix and json_object_iter_next() clashes between them. > &g

Re: [libvirt] [PATCH] util: avoid symbol clash between json libraries

2018-07-31 Thread Daniel P . Berrangé
On Tue, Jul 31, 2018 at 05:57:21PM +0200, Andrea Bolognani wrote: > On Tue, 2018-07-31 at 15:55 +0100, Daniel P. Berrangé wrote: > [...] > > +# We dlopen() it so need an explicit dep > > +Requires: libjansson.so.4()(64bit) > > Wouldn't requiring jansson be better here? I d

Re: [libvirt] [PATCH] util: avoid symbol clash between json libraries

2018-07-31 Thread Daniel P . Berrangé
On Tue, Jul 31, 2018 at 11:28:02AM -0500, Eric Blake wrote: > On 07/31/2018 09:55 AM, Daniel P. Berrangé wrote: > > The jansson and json-glib libraries both export symbols with a json_ > > name prefix and json_object_iter_next() clashes between them. > > > > Unfort

Re: [libvirt] [PATCH] util: avoid symbol clash between json libraries

2018-08-01 Thread Daniel P . Berrangé
which allows us to hide the symbols from the application that loads > > libvirt or the NSS module. > > > > Some preprocessor black magic and wrapper functions are used to redirect > > calls into the dlopen resolved symbols. > > > > Signed-off-by: Daniel P

Re: [libvirt] Availability of libvirt-4.6.0 Release Candidate 2

2018-08-01 Thread Daniel P . Berrangé
On Tue, Jul 31, 2018 at 03:54:43PM +0200, Bjoern Walk wrote: > Bjoern Walk [2018-07-31, 03:16PM +0200]: > > I have not yet had the time to figure out what goes wrong, any ideas are > > welcome. > > Ah, classic. The mocked virRandomBytes function is not endian-agnostic, > generating a different

Re: [libvirt] [PATCH 2/2] viriscsi: Request more random bits for interface name

2018-08-01 Thread Daniel P . Berrangé
(unsigned long long)virRandomBits(32)) < 0) > return -1; > > VIR_DEBUG("Attempting to create interface '%s' with IQN '%s'", Reviewed-by: Daniel P. Berrangé Regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |:

Re: [libvirt] [PATCH 1/2] util: Don't overflow in virRandomBits

2018-08-01 Thread Daniel P . Berrangé
- 1; > + ret &= (1ULL << nbits) - 1; > return ret; > } Reviewed-by: Daniel P. Berrangé Regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o-https://fstop138.berrange.com :| |: https:/

Re: [libvirt] Entering freeze for libvirt-4.6.0

2018-08-05 Thread Daniel P . Berrangé
On Mon, Jul 30, 2018 at 05:20:01PM +0200, Andrea Bolognani wrote: > It seems like a similar issue could affect any application linking > both to libvirt and json-glib, regardless of whether or not the NSS > plugin has been enabled, which is of course pretty bad. > > Unfortunately, I don't have

Re: [libvirt] Entering freeze for libvirt-4.6.0

2018-08-05 Thread Daniel P . Berrangé
On Mon, Jul 30, 2018 at 05:20:01PM +0200, Andrea Bolognani wrote: > On Sat, 2018-07-28 at 21:56 +0800, Daniel Veillard wrote: > > so things looks pretty good for > > me but please try it out on different systems and OSes. > > > > If everything goes well I will push rc2 on Tuesday targetting

Re: [libvirt] [PATCH for v4.6.0 0/2] Fix some random problems

2018-08-05 Thread Daniel P . Berrangé
ndom: make virRandomBits endian-safe > > Make the generation of random bits in virRandomBits independent of the > endianness of the running architecture. > > This also solves problems with the mocked random byte generation on > big-endian machines. > > Suggested-by: Da

Re: [libvirt] Availability of libvirt-4.6.0 Release Candidate 2

2018-08-05 Thread Daniel P . Berrangé
On Wed, Aug 01, 2018 at 01:10:08PM +0100, Daniel P. Berrangé wrote: > On Wed, Aug 01, 2018 at 01:41:48PM +0200, Bjoern Walk wrote: > > Daniel P. Berrangé [2018-08-01, 11:51AM +0100]: > > > On Tue, Jul 31, 2018 at 03:54:43PM +0200, Bjoern Walk wrote: > > > > Bjoern Wa

[libvirt] [PATCH 2/4] cpu: push more parsing logic into common code

2018-08-05 Thread Daniel P . Berrangé
The x86 and ppc impls both duplicate some logic when parsing CPU features. Change the callback signature so that this duplication can be pushed up a level to common code. Signed-off-by: Daniel P. Berrangé --- src/cpu/cpu_map.c | 106 +++- src/cpu/cpu_map.h | 22

[libvirt] [PATCH v2] util: avoid symbol clash between json libraries

2018-08-05 Thread Daniel P . Berrangé
-off-by: Daniel P. Berrangé --- libvirt.spec.in | 2 + src/Makefile.am | 5 +- src/util/Makefile.inc.am | 3 +- src/util/virjson.c | 9 +- src/util/virjsoncompat.c | 274 +++ src/util/virjsoncompat.h | 88 + 6 files

[libvirt] [PATCH] conf: rewrite filtering for capabilities lookup

2018-08-05 Thread Daniel P . Berrangé
-by: Daniel P. Berrangé --- src/conf/capabilities.c | 100 ++-- 1 file changed, 45 insertions(+), 55 deletions(-) diff --git a/src/conf/capabilities.c b/src/conf/capabilities.c index 0f96500294..cfd5132329 100644 --- a/src/conf/capabilities.c +++ b/src/conf

Re: [libvirt] [PATCH] util: virrandom: make virRandomBits endian-safe

2018-08-05 Thread Daniel P . Berrangé
On Thu, Aug 02, 2018 at 01:12:02PM +0200, Pino Toscano wrote: > On Thursday, 2 August 2018 12:28:45 CEST Daniel P. Berrangé wrote: > > On Thu, Aug 02, 2018 at 10:17:32AM +0200, Bjoern Walk wrote: > > > Pino Toscano [2018-08-02, 10:02AM +0200]: > > > > I do not t

Re: [libvirt] [PATCH] tests: mock virRandomBits to make it endian stable

2018-08-05 Thread Daniel P . Berrangé
On Thu, Aug 02, 2018 at 08:17:25AM -0500, Eric Blake wrote: > On 08/02/2018 06:37 AM, Daniel P. Berrangé wrote: > > virRandomBits is implemented in terms of virRandomBytes. Although we > > mock virRandomBytes to give a stable value, this is not sufficient to > > make virRan

[libvirt] [PATCH] qemu: ensure "pc" machine is always used as default if available

2018-08-05 Thread Daniel P . Berrangé
it is too hard to decide which to default so. Versioned machine types are supposed to be considered opaque strings, so we can't apply any sensible ordering ourselves and QEMU isn't reporting the list of machines in any sensible ordering itself. Signed-off-by: Daniel P. Berrangé --- src/qemu/qemu_c

Re: [libvirt] Availability of libvirt-4.6.0 Release Candidate 2

2018-08-05 Thread Daniel P . Berrangé
On Wed, Aug 01, 2018 at 01:41:48PM +0200, Bjoern Walk wrote: > Daniel P. Berrangé [2018-08-01, 11:51AM +0100]: > > On Tue, Jul 31, 2018 at 03:54:43PM +0200, Bjoern Walk wrote: > > > Bjoern Walk [2018-07-31, 03:16PM +0200]: > > > > I have not yet had the time to f

Re: [libvirt] [PATCH] util: virrandom: make virRandomBits endian-safe

2018-08-05 Thread Daniel P . Berrangé
On Thu, Aug 02, 2018 at 10:17:32AM +0200, Bjoern Walk wrote: > Pino Toscano [2018-08-02, 10:02AM +0200]: > > I do not think this patch is correct: we are dealing with random bytes, > > so there is no "endianness" for them. > > Well, it's not incorrect either, isn't it? I agree that endianness >

[libvirt] [PATCH 3/4] cpu: split PPC64 map data into separate files

2018-08-01 Thread Daniel P . Berrangé
Signed-off-by: Daniel P. Berrangé --- src/cpu/cpu_map.xml | 41 + src/cpu/cpu_map_ppc64_POWER6.xml| 6 src/cpu/cpu_map_ppc64_POWER7.xml| 7 + src/cpu/cpu_map_ppc64_POWER8.xml| 8 + src/cpu/cpu_map_ppc64_POWER9

[libvirt] [PATCH 0/4] cpu: modularize the CPU map data file

2018-08-01 Thread Daniel P . Berrangé
> 42a47 > 56a62 > 57a64 > 58a66,67 > > Daniel P. Berrangé (4): cpu: allow include files for CPU definition cpu: push more parsing logic into common code cpu: split PPC64 map data into separate files cpu:

[libvirt] [PATCH 1/4] cpu: allow include files for CPU definition

2018-08-01 Thread Daniel P . Berrangé
Allow for syntax to reference other files in the CPU database directory Signed-off-by: Daniel P. Berrangé --- libvirt.spec.in | 2 +- mingw-libvirt.spec.in | 4 +-- src/Makefile.am | 2 +- src/cpu/cpu_map.c | 84 +-- 4 files

Re: [libvirt] [PATCH] tests: viriscsitest: make it work on big endian archs

2018-08-01 Thread Daniel P . Berrangé
On Wed, Aug 01, 2018 at 03:08:07PM +0200, Pino Toscano wrote: > viriscsitest tries to ensure the interface IQN used is a specific one, > checking later on that it is the same all during the whole test. Since > the IQN generation involves random bytes, viriscsitest got a fake > virRandomBytes from

[libvirt] [PATCH] tests: mock virRandomBits to make it endian stable

2018-08-02 Thread Daniel P . Berrangé
directly. Signed-off-by: Daniel P. Berrangé --- tests/virrandommock.c | 8 1 file changed, 8 insertions(+) diff --git a/tests/virrandommock.c b/tests/virrandommock.c index 99a55a576a..3079b8bacb 100644 --- a/tests/virrandommock.c +++ b/tests/virrandommock.c @@ -44,6 +44,14 @@ virRandomBytes

Re: [libvirt] [PATCH for v4.6.0] cgroups: Don't leave stale pointers around after virCgroupFree

2018-07-30 Thread Daniel P . Berrangé
On Mon, Jul 30, 2018 at 10:25:05AM +0200, Michal Privoznik wrote: > One of the attributes that original virCgroupFree() had was it > set passed pointer to NULL. For instance in the following code > the latter call would be practically a no-op: > > virCgroupFree(); > virCgroupFree(); > >

Re: [libvirt] [PATCH for v4.6.0] cgroups: Don't leave stale pointers around after virCgroupFree

2018-07-30 Thread Daniel P . Berrangé
On Mon, Jul 30, 2018 at 09:48:51AM +0100, Daniel P. Berrangé wrote: > On Mon, Jul 30, 2018 at 10:25:05AM +0200, Michal Privoznik wrote: > > One of the attributes that original virCgroupFree() had was it > > set passed pointer to NULL. For instance in the following code > >

[libvirt] [jenkins-ci PATCH] hosts_vars: drop virt-viewer from platforms with old spice-gtk

2018-07-30 Thread Daniel P . Berrangé
git master requires spice-gtk >= 0.35 Signed-off-by: Daniel P. Berrangé --- guests/host_vars/libvirt-centos-7/main.yml| 1 - guests/host_vars/libvirt-debian-8/main.yml| 1 - guests/host_vars/libvirt-debian-9/main.yml| 1 - guests/host_vars/libvirt-debian-sid/main.

[libvirt] [PATCH] conf: don't use virDomainVirtType in struct field

2018-07-26 Thread Daniel P . Berrangé
optimize away the "< 0" check due to the assumption that the enum type is unsigned and always in range. Signed-off-by: Daniel P. Berrangé --- src/conf/domain_conf.c | 2 +- src/conf/domain_conf.h | 2 +- src/qemu/qemu_command.c | 2 +- src/qemu/qemu_process.c | 4 +++- 4 files

Re: [libvirt] [PATCH] conf: fix virtType FromString check

2018-07-26 Thread Daniel P . Berrangé
On Thu, Jul 26, 2018 at 11:30:07AM -0400, Cole Robinson wrote: > In the domain definition, virtType is virDomainVirtType which is > unsigned, so comparing against -1 doesn't work. Cast to int first > > Fixes 8e2982b5767 > > Signed-off-by: Cole Robinson > --- > This regressed in the past as

Re: [libvirt] [RFC] secdrivers remembering original labels

2018-08-06 Thread Daniel P . Berrangé
On Mon, Aug 06, 2018 at 10:02:44AM +0200, Michal Prívozník wrote: > On 07/27/2018 11:01 AM, Daniel P. Berrangé wrote: > > On Fri, Jul 27, 2018 at 09:56:23AM +0200, Michal Privoznik wrote: > >> Dear list, > >> > >> we have this very old bug [1] that I just keep

Re: [libvirt] [PATCH] virrandom: Avoid undefined behaviour in virRandomBits

2018-08-06 Thread Daniel P . Berrangé
1; > +if (nbits < 64) > +ret &= (1ULL << nbits) - 1; > + > return ret; > } Reviewed-by: Daniel P. Berrangé Regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o-

Re: [libvirt] [PATCH] remote: daemon: Make sure that JSON symbols are properly loaded at startup

2018-08-06 Thread Daniel P . Berrangé
n the daemon would want to use the JSON parser. > > Signed-off-by: Peter Krempa > --- > src/libvirt_private.syms | 4 > src/remote/remote_daemon.c | 4 > 2 files changed, 8 insertions(+) For sake of historical record Reviewed-by: Daniel P. Berrangé but due to mailing

Re: [libvirt] [PATCH 0/1] bhyve: Make LPC slot number configurable

2018-08-10 Thread Daniel P . Berrangé
0/2018 05:57 PM, Daniel P. Berrangé wrote: > > On Fri, Aug 10, 2018 at 05:47:40PM +0300, Ivan Mishonov wrote: > > > Yes, this is totally doable. I just don't know if it's a good idea to add > > > a > > > new device type specifically for bhyve LPC and nothing else. Even if

Re: [libvirt] [PATCH 0/1] bhyve: Make LPC slot number configurable

2018-08-10 Thread Daniel P . Berrangé
On Fri, Aug 10, 2018 at 05:47:40PM +0300, Ivan Mishonov wrote: > Yes, this is totally doable. I just don't know if it's a good idea to add a > new device type specifically for bhyve LPC and nothing else. Even if we do > it like this I'll still have to send another patch including the bhyve XML >

Re: [libvirt] [PATCH 0/1] bhyve: Make LPC slot number configurable

2018-08-10 Thread Daniel P . Berrangé
On Fri, Aug 10, 2018 at 06:36:46PM +0300, Ivan Mishonov wrote: > Yes, that makes sense. I'll try to find some time next week to redo my code > and send another patch. Since my time for working on libvirt is very limited > can you confirm that the LPC configuration should look like this: > >    >

Re: [libvirt] [PATCH] network: restrict usage of port management APIs

2018-08-09 Thread Daniel P . Berrangé
On Wed, Aug 08, 2018 at 11:41:23PM -0400, Laine Stump wrote: > On 08/08/2018 11:46 AM, Daniel P. Berrangé wrote: > > The port allocation APIs are currently called unconditionally for all > > types of NIC, but (mostly) only do anything for NICs with type=network. > > > >

Re: [libvirt] [PATCH] conf: rewrite filtering for capabilities lookup

2018-08-09 Thread Daniel P . Berrangé
ping On Fri, Aug 03, 2018 at 03:28:16PM +0100, Daniel P. Berrangé wrote: > The virCapabilitiesDomainDataLookupInternal() is given a list of > parameters representing the desired domain characteristics. It then has > to look throught the capabilities to identify an accepta

Re: [libvirt] [PATCH libvirt-tck] Cleanup secret in disk encryption test

2018-08-09 Thread Daniel P . Berrangé
Jim Fehlig > --- > scripts/qemu/100-disk-encryption.t | 2 ++ > 1 file changed, 2 insertions(+) Reviewed-by: Daniel P. Berrangé Regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o-https://fs

[libvirt] [jenkins-ci PATCH] jobs: ensure rpmbuild purges $RPM-ROOT/BUILD/$PACKAGE

2018-08-09 Thread Daniel P . Berrangé
directory, but since we use %autosetup now the directory will contain a git repo which causes "git clean" to skip deletion: $ su - jenkins $ cd libvirt-master $ git clean -fdx Skipping repository build/rpmbuild/BUILD/libvirt-4.7.0 Signed-off-by: Daniel P. Berrangé ---

Re: [libvirt] [jenkins-ci PATCH] projects: Don't use ~/rpmbuild for osinfo-db

2018-08-09 Thread Daniel P . Berrangé
KE osinfo-db.spec > perl -i -p -e 's/BuildRequires: osinfo-db-tools.*//' > osinfo-db.spec > -$MAKE rpm > +rpmbuild --clean --define "_topdir `pwd`/rpmbuild" --define > "_sourcedir `pwd`" -ba osinfo-db.spec Reviewed-by: D

Re: [libvirt] [PATCH] network: restrict usage of port management APIs

2018-08-09 Thread Daniel P . Berrangé
On Thu, Aug 09, 2018 at 11:54:42AM -0400, Laine Stump wrote: > On 08/09/2018 03:58 AM, Daniel P. Berrangé wrote: > > On Wed, Aug 08, 2018 at 11:41:23PM -0400, Laine Stump wrote: > >> On 08/08/2018 11:46 AM, Daniel P. Berrangé wrote: > >>> The port alloca

Re: [libvirt] [Qemu-devel] [PATCH 3/3] ui: remove support for SDL1.2 in favour of SDL2

2018-08-08 Thread Daniel P . Berrangé
On Wed, Aug 08, 2018 at 02:51:01PM +0100, Peter Maydell wrote: > On 8 August 2018 at 11:49, Daniel P. Berrangé wrote: > > SDL1.2 was deprecated in the 2.12.0 release with: > > > > commit e52c6ba34149b4f39c3fd60e59ee32b809db2bfa > > Author: Daniel P. Berrange > &

Re: [libvirt] [PATCH] qemu: ensure default machine types don't change if QEMU changes

2018-08-08 Thread Daniel P . Berrangé
On Wed, Aug 08, 2018 at 10:12:59AM +0200, Andrea Bolognani wrote: > On Tue, 2018-08-07 at 16:01 +0100, Daniel P. Berrangé wrote: > > On Tue, Aug 07, 2018 at 04:57:28PM +0200, Andrea Bolognani wrote: > > > > > I wonder if we shouldn't just drop the default machine type handl

Re: [libvirt] [PATCH] qemu: ensure "pc" machine is always used as default if available

2018-08-08 Thread Daniel P . Berrangé
On Tue, Aug 07, 2018 at 03:53:53PM -0300, Eduardo Habkost wrote: > On Tue, Aug 07, 2018 at 12:17:33PM +0100, Daniel P. Berrangé wrote: > > On Fri, Aug 03, 2018 at 01:05:49PM -0300, Eduardo Habkost wrote: > > > On Fri, Aug 03, 2018 at 01:59:47PM +0100, Daniel

[libvirt] [PATCH] network: restrict usage of port management APIs

2018-08-08 Thread Daniel P . Berrangé
the network driver may not even be installed, so virt drivers must not delegation validation to it for NICs with type!=network. This change allows us to report errors when the virtual network driver is not registered. Signed-off-by: Daniel P. Berrangé --- src/conf/domain_conf.c | 12

[libvirt] [PATCH] storage: tweak error message when skipping file

2018-08-08 Thread Daniel P . Berrangé
Signed-off-by: Daniel P. Berrangé --- src/storage/storage_util.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/storage/storage_util.c b/src/storage/storage_util.c index 715d5c2f88..42a9b6abf0 100644 --- a/src/storage/storage_util.c +++ b/src/storage/storage_util.c

Re: [libvirt] [PATCH] Fix link errors in tools/nss and tests

2018-08-08 Thread Daniel P . Berrangé
mit b018ada3 and inspires this fix. > > Signed-off-by: Jim Fehlig Reviewed-by: Daniel P. Berrangé Regards, Daniel -- |: https://berrange.com -o-https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o-https://fstop138.berrange.com :| |:

Re: [libvirt] [libvirt-glib][PATCH] Use new GObject define macros with private

2018-08-15 Thread Daniel P . Berrangé
On Wed, Aug 15, 2018 at 06:08:18PM +0200, Andrea Bolognani wrote: > On Fri, 2018-08-10 at 10:38 +0100, Daniel P. Berrangé wrote: > > On Fri, Aug 10, 2018 at 11:29:30AM +0200, Michal Privoznik wrote: > > > G_ADD_PRIVATE was added in 2.38 and older functions are getting

Re: [libvirt] [PATCH v2 0/6] fdaskljrew

2018-08-16 Thread Daniel P . Berrangé
On Thu, Aug 16, 2018 at 11:11:26AM +0200, Simon Kobyda wrote: > rpdwrewrewr Please use a sensible subject line, and provide useful information about the patch series in this cover letter. > > Simon Kobyda (6): > vsh: Add API for printing tables. > virsh: Implement new table API for virsh

Re: [libvirt] [PATCH 1/4] cpu: allow include files for CPU definition

2018-08-16 Thread Daniel P . Berrangé
On Tue, Aug 14, 2018 at 12:55:19PM +0200, Jiri Denemark wrote: > On Wed, Aug 01, 2018 at 18:02:29 +0100, Daniel P. Berrangé wrote: > > Allow for syntax > > > > > > It seems the code should just work with > > > > but Makefile.am and

Re: [libvirt] [RFC PATCH 01/17] qemu: setup shared memory without explicit numa configuration

2018-08-16 Thread Daniel P . Berrangé
On Fri, Jul 13, 2018 at 03:28:08PM +0200, marcandre.lur...@redhat.com wrote: > From: Marc-André Lureau > > When a domain is configured with 'shared' memory backing: > > > > > > But no explicit NUMA configuration, let's configure a shared memory > backend associated with default

Re: [libvirt] [PATCH 0/7] Remove arbitrary limit on socket_id/core_id

2018-08-14 Thread Daniel P . Berrangé
On Tue, Aug 14, 2018 at 11:07:49AM +0200, Andrea Bolognani wrote: > See patch 6 for the explanation; the previous 5 patches > are cleanups. > > I had to snip out some patches to comply with the message > size limit for the list - ironic, I know. The full commits > can be fetched from Although

Re: [libvirt] [PATCH v3 1/3] vsh: Add API for printing tables.

2018-08-16 Thread Daniel P . Berrangé
On Thu, Aug 16, 2018 at 12:56:24PM +0200, Simon Kobyda wrote: > It solves problems with alignment of columns. Width of each column > is calculated by its biggest cell. Should solve unicode bug. > In future, it may be implemented in virsh, virt-admin... > > This API has 5 public functions: > -

Re: [libvirt] [RFC PATCH 01/17] qemu: setup shared memory without explicit numa configuration

2018-08-16 Thread Daniel P . Berrangé
On Thu, Aug 16, 2018 at 07:32:57AM -0400, John Ferlan wrote: > > > On 08/16/2018 06:31 AM, Marc-André Lureau wrote: > > Hi > > > > On Thu, Aug 16, 2018 at 4:35 AM, John Ferlan wrote: > >> > >> > >> On 07/13/2018 09:28 AM, marcandre.lur...@redhat.com wrote: > >>> From: Marc-André Lureau > >>>

[libvirt] [PATCH 0/3] Fix default machine when converting argv to xml

2018-08-16 Thread Daniel P . Berrangé
We must honour the QEMU built-in default machine when converting from argv Daniel P. Berrangé (3): qemu: record the QEMU default machine in capabilities qemu: rename method for getting preferred machine type qemu: fix default machine for argv -> xml convertor src/qemu/qemu_capabilitie

[libvirt] [PATCH 1/3] qemu: record the QEMU default machine in capabilities

2018-08-16 Thread Daniel P . Berrangé
We don't honour the QEMU default machine type anymore, always using the libvirt chosen default instead. The QEMU argv parser, however, will need to know the exacty QEMU default, so we must record that info. Signed-off-by: Daniel P. Berrangé --- src/qemu/qemu_capabilities.c | 14

[libvirt] [PATCH v2 1/8] cpu: allow include files for CPU definition

2018-08-16 Thread Daniel P . Berrangé
Allow for syntax to reference other files in the CPU database directory Signed-off-by: Daniel P. Berrangé --- src/cpu/cpu_map.c | 87 +-- 1 file changed, 84 insertions(+), 3 deletions(-) diff --git a/src/cpu/cpu_map.c b/src/cpu/cpu_map.c index

[libvirt] [PATCH v2 6/8] cpu: split PPC64 map data into separate files

2018-08-16 Thread Daniel P . Berrangé
Signed-off-by: Daniel P. Berrangé --- src/cpu_map/Makefile.inc.am | 7 + src/cpu_map/index.xml | 41 + src/cpu_map/ppc64_POWER6.xml| 6 + src/cpu_map/ppc64_POWER7.xml| 7 + src/cpu_map/ppc64_POWER8.xml| 8

[libvirt] [PATCH v2 3/8] cpu: push more parsing logic into common code

2018-08-16 Thread Daniel P . Berrangé
The x86 and ppc impls both duplicate some logic when parsing CPU features. Change the callback signature so that this duplication can be pushed up a level to common code. Signed-off-by: Daniel P. Berrangé --- src/cpu/cpu_map.c | 98 +- src/cpu/cpu_map.h | 22 ++--- src

[libvirt] [PATCH v2 4/8] cpu: simplify failure cleanup paths

2018-08-16 Thread Daniel P . Berrangé
Get rid of the separate 'error:' label, so all code paths jump straight to the 'cleanup:' label. Signed-off-by: Daniel P. Berrangé --- src/cpu/cpu_ppc64.c | 38 src/cpu/cpu_x86.c | 71 - 2 files changed, 49 insertions(+), 60

[libvirt] [PATCH v2 8/8] xml: report the filename (if any) when parsing files

2018-08-16 Thread Daniel P . Berrangé
A generic "failed to parse xml document" message without telling us which XML file failed is quite unhelpful. Signed-off-by: Daniel P. Berrangé --- src/util/virxml.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/util/virxml.c b/src/util/virxml.c index

[libvirt] [PATCH 2/3] qemu: rename method for getting preferred machine type

2018-08-16 Thread Daniel P . Berrangé
The virQEMUCapsGetDefaultMachine() method doesn't get QEMU's default machine any more, instead it gets the historical default that libvirt prefers for each arch. Rename it, so that the old name can be used for getting QEMU's default. Signed-off-by: Daniel P. Berrangé --- src/qemu

[libvirt] [PATCH 3/3] qemu: fix default machine for argv -> xml convertor

2018-08-16 Thread Daniel P . Berrangé
get, as QEMU does not define any default machine. Thus we should not having been accepting argv without a -machine provided. Signed-off-by: Daniel P. Berrangé --- src/qemu/qemu_capabilities.c | 17 +++- src/qemu/qemu_capabilities.h | 1 + src/qemu/qemu_drive

Re: [libvirt] [PATCH v3 1/3] vsh: Add API for printing tables.

2018-08-16 Thread Daniel P . Berrangé
On Thu, Aug 16, 2018 at 02:05:45PM +0200, Ján Tomko wrote: > On Thu, Aug 16, 2018 at 12:56:24PM +0200, Simon Kobyda wrote: > > It solves problems with alignment of columns. Width of each column > > is calculated by its biggest cell. Should solve unicode bug. > > In future, it may be implemented in

[libvirt] [PATCH v2 0/8] cpu: modularize the CPU map data file

2018-08-16 Thread Daniel P . Berrangé
> 30a34 > 42a47 > 56a62 > 57a64 > 58a66,67 > > Changed in v2: - Moved all XML files into a new src/cpu_map/ directory - Simplify the goto labels for error code paths. - Code style fixes Danie

[libvirt] [PATCH v2 2/8] cpu: fix cleanup when signature parsing fails

2018-08-16 Thread Daniel P . Berrangé
Two pieces of code accidentally jumped to the wrong label when they failed causing incorrect cleanup, returning a partially initialized CPU model struct. Signed-off-by: Daniel P. Berrangé --- src/cpu/cpu_x86.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cpu

[libvirt] [PATCH v2 5/8] cpu: move the CPU map data files into a src/cpu_map directory

2018-08-16 Thread Daniel P . Berrangé
In preparation for splitting up the CPU map data file, move it into a dedicated directory of its own. Signed-off-by: Daniel P. Berrangé --- libvirt.spec.in| 2 +- mingw-libvirt.spec.in | 4 ++-- src/Makefile.am| 7

Re: [libvirt] [Qemu-devel] clean/simple Q35 support in libvirt+QEMU for guest OSes that don't support virtio-1.0

2018-08-17 Thread Daniel P . Berrangé
On Fri, Aug 17, 2018 at 12:35:11PM +0200, Andrea Bolognani wrote: > On Fri, 2018-08-17 at 10:29 +0100, Daniel P. Berrangé wrote: > > On Thu, Aug 16, 2018 at 06:20:29PM -0400, Laine Stump wrote: > > > 5) Some guest OSes that we still want to support (and which would > &g

Re: [libvirt] [Qemu-devel] clean/simple Q35 support in libvirt+QEMU for guest OSes that don't support virtio-1.0

2018-08-17 Thread Daniel P . Berrangé
On Thu, Aug 16, 2018 at 06:20:29PM -0400, Laine Stump wrote: > Summary of the problem: > > 1) We want to persuade libvirt+QEMU users to move away from the i440fx > machinetype in favor of Q35. (NB: Someday this *might* lead to the > ability to deprecate and even remove the 440fx machinetype, but

Re: [libvirt] [RFC] secdrivers remembering original labels

2018-08-06 Thread Daniel P . Berrangé
On Mon, Aug 06, 2018 at 12:01:03PM +0200, Michal Prívozník wrote: > On 08/06/2018 10:30 AM, Daniel P. Berrangé wrote: > > >> > >> So do we really need virtlockd for this? I mean, the whole purpose of it > >> is to hold locks so that libvirtd can restart independen

[libvirt] [PATCH] qemu: ensure default machine types don't change if QEMU changes

2018-08-07 Thread Daniel P . Berrangé
vide the "pc" alias, it is too hard to decide which to default so. Versioned machine types are supposed to be considered opaque strings, so we can't apply any sensible ordering ourselves and QEMU isn't reporting the list of machines in any sensible ordering itself. Signed-off-by: Daniel P. B

Re: [libvirt] [PATCH] qemu: ensure "pc" machine is always used as default if available

2018-08-07 Thread Daniel P . Berrangé
On Mon, Aug 06, 2018 at 11:38:06AM +0200, Andrea Bolognani wrote: > On Fri, 2018-08-03 at 13:59 +0100, Daniel P. Berrangé wrote: > > It is increasingly likely that some distro is going to change the > > default "x86" machine type in QEMU from "pc" to "q35&

<    4   5   6   7   8   9   10   11   12   13   >