[libvirt] [PATCH v2 1/4] cpu: define sub-leaf 0 for leaf 7 in cpu_map.xml

2017-07-03 Thread Marek Marczykowski-Górecki
CPUID leaf 7 is sub-leaf aware. Add missing attribute. Signed-off-by: Marek Marczykowski-Górecki --- Changes since v1: - format ecx_in='0x00' --- src/cpu/cpu_map.xml | 58 +++--- 1 file changed, 29 insertions(+), 29

[libvirt] [PATCH v2 2/4] libxl: add support for CPUID features policy

2017-07-03 Thread Marek Marczykowski-Górecki
Convert CPU features policy into libxl cpuid policy settings. Use new ("libxl") syntax, which allow to enable/disable specific bits, using host CPU as a base. For this reason, accept only "host-passthrough" mode. Libxl do not have distinction between "force" and "required" policy (there is only

[libvirt] [PATCH v2 4/4] tests: check CPU features handling in libxl driver

2017-07-03 Thread Marek Marczykowski-Górecki
Test enabling/disabling individual CPU features and also setting nested HVM support, which is also controlled by CPU features node. Signed-off-by: Marek Marczykowski-Górecki --- Changes since v1: - rewritten to Jim's test suite for libxl_domain_config generator

[libvirt] [PATCH v2 0/4] Add setting CPU features (CPUID) with libxenlight driver.

2017-07-03 Thread Marek Marczykowski-Górecki
Tests (patches 3 and 4) depends on libxl_domain_config test suite: https://www.redhat.com/archives/libvir-list/2017-February/msg01477.html But first two patches can be applied independently. Marek Marczykowski-Górecki (4): cpu: define sub-leaf 0 for leaf 7 in cpu_map.xml libxl: add support

[libvirt] [PATCH v2 3/4] tests: switch libxlxml2domconfig test to use testXLInintCaps

2017-07-03 Thread Marek Marczykowski-Górecki
As name suggests, it's a better choice for libxl test. Important differences: - advertise x86_64 guests support - initialize host CPU caps Signed-off-by: Marek Marczykowski-Górecki --- Changes since v1: - new patch, applicable over Jim's test suite for

[libvirt] [PATCH v4 11/14] nodedev: Privatize _virNodeDeviceObj and _virNodeDeviceObjList

2017-07-03 Thread John Ferlan
Move the structures to withing virnodedeviceobj.c Move the typedefs from node_device_conf to virnodedeviceobj.h Signed-off-by: John Ferlan --- src/conf/node_device_conf.h | 17 - src/conf/virnodedeviceobj.c | 11 +++ src/conf/virnodedeviceobj.h | 6

[libvirt] [PATCH v4 12/14] nodedev: Convert virNodeDeviceObj to use virObjectLockable

2017-07-03 Thread John Ferlan
Now that we have a bit more control, let's convert our object into a lockable object and let that magic handle the create and lock/unlock. This also involves creating a virNodeDeviceEndAPI in order to handle the object cleaup for API's that use the Add or Find API's in order to get a

[libvirt] [PATCH v4 13/14] nodedev: Convert virNodeDeviceObjListPtr to use hash tables

2017-07-03 Thread John Ferlan
Rather than use a forward linked list of elements, it'll be much more efficient to use a hash table to reference the elements by unique name and to perform hash searches. This patch does all the heavy lifting of converting the list object to use a self locking list that contains the hash table.

[libvirt] [PATCH v4 02/14] test: Adjust cleanup/error paths for nodedev test APIs

2017-07-03 Thread John Ferlan
- In testDestroyVport rather than use a cleanup label, just return -1 immediately since nothing else is needed. - In testStoragePoolDestroy, if !privpool, then just return -1 since nothing else will happen anyway. - Rather than "goto cleanup;" on failure to virNodeDeviceObjFindByName

[libvirt] [PATCH v4 07/14] nodedev: Alter node device obj list function names

2017-07-03 Thread John Ferlan
Ensure that any function that walks the node device object list is prefixed by virNodeDeviceObjList. Also, modify the @filter param name for virNodeDeviceObjListExport to be @aclfilter. Signed-off-by: John Ferlan --- src/conf/virnodedeviceobj.c | 109

[libvirt] [PATCH v4 14/14] nodedev: Remove driver locks around object list mgmt code

2017-07-03 Thread John Ferlan
Since virnodedeviceobj now has a self-lockable hash table, there's no need to lock the table from the driver for processing. Thus remove the locks from the driver for NodeDeviceObjList mgmt. Signed-off-by: John Ferlan --- src/node_device/node_device_driver.c | 61

[libvirt] [PATCH v4 00/14] Make virNodeDeviceObj and virNodeDeviceObjList private

2017-07-03 Thread John Ferlan
v3 here: https://www.redhat.com/archives/libvir-list/2017-June/msg00155.html Most patches were ACK'd in v3 (some with conditions). Changes this time around are: -> Patch1: Make the call to virNodeDeviceObjFree in dev_refresh() prior to dev_create Move the virNodeDeviceObjFree in

[libvirt] [PATCH v4 10/14] nodedev: Introduce virNodeDeviceObjListFindSCSIHostByWWNs

2017-07-03 Thread John Ferlan
In an overall effort to privatize access to virNodeDeviceObj and virNodeDeviceObjList into the virnodedeviceobj module, move the object list parsing from node_device_driver and replace with a call to a virnodedeviceobj helper. This follows other similar APIs/helpers which peruse the object list

[libvirt] [PATCH v4 03/14] nodedev: Use common naming for virnodedeviceobj

2017-07-03 Thread John Ferlan
A virNodeDeviceObjPtr is an @obj A virNodeDeviceObjListPtr is an @devs Signed-off-by: John Ferlan --- src/conf/virnodedeviceobj.c | 130 ++-- 1 file changed, 65 insertions(+), 65 deletions(-) diff --git a/src/conf/virnodedeviceobj.c

[libvirt] [PATCH v4 09/14] nodedev: Introduce virNodeDeviceGetSCSIHostCaps

2017-07-03 Thread John Ferlan
We're about to move the call to nodeDeviceSysfsGetSCSIHostCaps from node_device_driver into virnodedeviceobj, so move the guts of the code from the driver specific node_device_linux_sysfs into its own API since virnodedeviceobj cannot callback into the driver. Nothing in the code deals with sysfs

[libvirt] [PATCH v4 05/14] nodedev: Introduce virNodeDeviceObjNew

2017-07-03 Thread John Ferlan
Create an allocator for the virNodeDeviceObjPtr - include setting up the mutex, saving the virNodeDeviceDefPtr, and locking the return object. Signed-off-by: John Ferlan --- src/conf/virnodedeviceobj.c | 34 +++--- 1 file changed, 23

[libvirt] [PATCH v4 08/14] nodedev: Dereference the obj/def in virNodeDeviceObjListFind* APIs

2017-07-03 Thread John Ferlan
Create local @obj and @def for the API's rather than referencing the devs->objs[i][->def->]. It'll make future patches easier to read. Signed-off-by: John Ferlan --- src/conf/virnodedeviceobj.c | 60 - 1 file changed, 37

[libvirt] [PATCH v4 01/14] nodedev: Alter virNodeDeviceObjRemove

2017-07-03 Thread John Ferlan
Rather than passing the object to be removed by reference, pass by value and then let the caller decide whether or not the object should be free'd and how to handle the logic afterwards. This includes free'ing the object and/or setting the local variable to NULL to prevent subsequent unexpected

[libvirt] [PATCH v4 06/14] nodedev: Introduce virNodeDeviceObjListNew

2017-07-03 Thread John Ferlan
In preparation to make things private, make the ->devs be pointers to a virNodeDeviceObjList and then manage everything inside virnodedeviceobj Signed-off-by: John Ferlan --- src/conf/virnodedeviceobj.c | 13 - src/conf/virnodedeviceobj.h | 5

[libvirt] [PATCH v4 04/14] nodedev: Use consistent names for driver variables

2017-07-03 Thread John Ferlan
A virNodeDeviceObjPtr is an @obj A virNodeDeviceObjListPtr is a @devs A virNodeDevicePtr is a @device Signed-off-by: John Ferlan --- src/node_device/node_device_driver.c | 74 ++-- src/node_device/node_device_hal.c| 39

Re: [libvirt] [PATCH v3 10/12] nodedev: Introduce virNodeDeviceObjListFindSCSIHostByWWNs

2017-07-03 Thread John Ferlan
On 07/03/2017 09:12 AM, Erik Skultety wrote: > On Sat, Jun 03, 2017 at 09:12:00AM -0400, John Ferlan wrote: >> Alter the nodeDeviceLookupSCSIHostByWWN to use the new API in order >> to find what it's looking for. >> > > Would you mind enhancing the commit message a bit? I assume the new API is

Re: [libvirt] [PATCH v3 01/12] nodedev: Alter virNodeDeviceObjRemove

2017-07-03 Thread John Ferlan
[...] >> >> Doh... true - of course I have in mind the end goal which is making >> this whole process awfully difficult. Going step by step hasn't really >> helped as much as it should have /-(. Adjustments to later patches will >> be necessary to either Unref or EndAPI. > > I'm sorry, I don't

[libvirt] [PATCH 0/2] Fix a couple issues found w/ vHBA logic

2017-07-03 Thread John Ferlan
Patch 1 fixes something seen whilst working through patch 2. Long description in patch 2 describes the problem. John Ferlan (2): storage: Alter check for default managed setting conf: Fix vHBA checkParent logic for pool creation src/conf/node_device_conf.c| 50

[libvirt] [PATCH 2/2] conf: Fix vHBA checkParent logic for pool creation

2017-07-03 Thread John Ferlan
https://bugzilla.redhat.com/show_bug.cgi?id=1458708 When originally designed in commit id '42a021c1', providing the 'parent' attribute to the was checked to make sure that the "parent" of the wwnn/wwpn matched that of the provided parent "just in case" someone created the node device first, then

[libvirt] [PATCH 1/2] storage: Alter check for default managed setting

2017-07-03 Thread John Ferlan
Only alter the managed setting if it wasn't provided. If someone provided 'no', then honor that rather than overwriting. Signed-off-by: John Ferlan --- src/storage/storage_backend_scsi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

Re: [libvirt] [PATCH] docs: add entry to download table listing the Rust language binding

2017-07-03 Thread John Ferlan
On 07/03/2017 11:58 AM, Daniel P. Berrange wrote: > Signed-off-by: Daniel P. Berrange > --- > docs/downloads.html.in | 16 > 1 file changed, 16 insertions(+) > Reviewed-by: John Ferlan John -- libvir-list mailing list

Re: [libvirt] [PATCH] news: Update for 3.5.0 release

2017-07-03 Thread John Ferlan
On 07/03/2017 08:16 AM, Andrea Bolognani wrote: > Signed-off-by: Andrea Bolognani > --- > docs/news.xml | 82 > +++ > 1 file changed, 82 insertions(+) > Reviewed-by: John Ferlan John --

Re: [libvirt] Entering freeze for libvirt-3.5.0

2017-07-03 Thread Guido Günther
On Mon, Jul 03, 2017 at 10:49:46AM +0200, Ján Tomko wrote: > [cc: Guido] > > On Sat, Jul 01, 2017 at 02:18:58PM +0400, Roman Bogorodskiy wrote: > > Andrea Bolognani wrote: > > > virnetsockettest also fails pretty often for me, certainly > > > more than your figure; even if that wasn't the case,

[libvirt] [PATCH] docs: add entry to download table listing the Rust language binding

2017-07-03 Thread Daniel P. Berrange
Signed-off-by: Daniel P. Berrange --- docs/downloads.html.in | 16 1 file changed, 16 insertions(+) diff --git a/docs/downloads.html.in b/docs/downloads.html.in index 99da7a6..0306945 100644 --- a/docs/downloads.html.in +++ b/docs/downloads.html.in @@

Re: [libvirt] [PATCHv2 1/2] lxc: add support for docker-json Memory and VCPU conversion

2017-07-03 Thread Cedric Bosdonnat
On Tue, 2017-06-27 at 16:07 -0400, John Ferlan wrote: > > On 06/27/2017 01:02 PM, Venkat Datta N H wrote: > > Docker Memory and VCPU configuration is converted to fit for LXC container > > XML configuration > > --- > >  po/POTFILES.in |   1 + > >  

Re: [libvirt] [PATCH v3 12/12] nodedev: Convert virNodeDeviceObj to use virObjectLockable

2017-07-03 Thread Erik Skultety
On Thu, Jun 29, 2017 at 12:11:47PM -0400, John Ferlan wrote: > > > On 06/03/2017 09:12 AM, John Ferlan wrote: > > Now that we have a bit more control, let's convert our object into > > a lockable object and let that magic handle the create and lock/unlock. > > > > This also involves creating a

Re: [libvirt] [PATCH v3 01/12] nodedev: Alter virNodeDeviceObjRemove

2017-07-03 Thread Erik Skultety
On Fri, Jun 30, 2017 at 09:47:07AM -0400, John Ferlan wrote: > > > On 06/30/2017 07:41 AM, Erik Skultety wrote: > > On Fri, Jun 30, 2017 at 07:14:13AM -0400, John Ferlan wrote: > >> > >> > >> On 06/30/2017 04:40 AM, Erik Skultety wrote: > >>> On Thu, Jun 29, 2017 at 12:07:42PM -0400, John Ferlan

Re: [libvirt] [PATCH] qemu: Take all PHBs into account while calculating memlock limits

2017-07-03 Thread Andrea Bolognani
On Fri, 2017-06-30 at 13:56 +0530, Shivaprasad G Bhat wrote: > -/* TODO: Detect at runtime once we start using more than just > - *   the default PCI Host Bridge */ > -nPCIHostBridges = 1; > +for (i = 0; i < def->ncontrollers; i++) { > +if

Re: [libvirt] Entering freeze for libvirt-3.5.0

2017-07-03 Thread Roman Bogorodskiy
Ján Tomko wrote: > [cc: Guido] > > On Sat, Jul 01, 2017 at 02:18:58PM +0400, Roman Bogorodskiy wrote: > > Andrea Bolognani wrote: > >> virnetsockettest also fails pretty often for me, certainly > >> more than your figure; even if that wasn't the case, 1/5 > >> failure rate is way too high for

Re: [libvirt] [PATCH v3 09/12] nodedev: Introduce virNodeDeviceGetSCSIHostCaps

2017-07-03 Thread Erik Skultety
On Sat, Jun 03, 2017 at 09:11:59AM -0400, John Ferlan wrote: > We're about to move the call to nodeDeviceSysfsGetSCSIHostCaps from > node_device_driver into virnodedeviceobj, so move the guts of the code > from the driver specific node_device_linux_sysfs into its own API > since virnodedeviceobj

Re: [libvirt] [PATCH v3 10/12] nodedev: Introduce virNodeDeviceObjListFindSCSIHostByWWNs

2017-07-03 Thread Erik Skultety
On Sat, Jun 03, 2017 at 09:12:00AM -0400, John Ferlan wrote: > Alter the nodeDeviceLookupSCSIHostByWWN to use the new API in order > to find what it's looking for. > Would you mind enhancing the commit message a bit? I assume the new API is virNodeDeviceGetSCSIHostCaps but a random reader would

[libvirt] [PATCH] news: Update for 3.5.0 release

2017-07-03 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- docs/news.xml | 82 +++ 1 file changed, 82 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index 636154e..f38abeb 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -68,6

Re: [libvirt] [RFC PATCH v2 1/4] numa: describe siblings distances within cells

2017-07-03 Thread Daniel P. Berrange
On Mon, Jul 03, 2017 at 11:19:07AM +0200, Wim ten Have wrote: > On Wed, 28 Jun 2017 15:21:29 +0100 > "Daniel P. Berrange" wrote: > > Hi Daniel, > > Appreciate your input and comments. Let me work on package and return > asap. > > One quick question; For future i

Re: [libvirt] [RFC PATCH v2 1/4] numa: describe siblings distances within cells

2017-07-03 Thread Wim ten Have
On Wed, 28 Jun 2017 15:21:29 +0100 "Daniel P. Berrange" wrote: Hi Daniel, Appreciate your input and comments. Let me work on package and return asap. One quick question; For future i am looking into way to somehow auto- tune node (cell/socket/cpu) assignment

Re: [libvirt] Entering freeze for libvirt-3.5.0

2017-07-03 Thread Ján Tomko
[cc: Guido] On Sat, Jul 01, 2017 at 02:18:58PM +0400, Roman Bogorodskiy wrote: Andrea Bolognani wrote: virnetsockettest also fails pretty often for me, certainly more than your figure; even if that wasn't the case, 1/5 failure rate is way too high for a CI job. I played a little more with

Re: [libvirt] [PATCH RESEND] qemu: Remove inactive vm when failed to start it

2017-07-03 Thread wang.yi59
Hi all, Could someone review my patch please? > Libvirt forgets to remove inactive vm when failed to start a defined vm. > That may result in residual domain in driver->domains on such condition: > during the process of starting a vm, undefine it, and qemu exit because > of some exception.

Re: [libvirt] [PATCH v3 08/12] nodedev: Dereference the obj/def in virNodeDeviceObjListFind* APIs

2017-07-03 Thread Erik Skultety
On Fri, Jun 30, 2017 at 01:08:22PM -0400, John Ferlan wrote: > > > On 06/30/2017 08:06 AM, Erik Skultety wrote: > > On Sat, Jun 03, 2017 at 09:11:58AM -0400, John Ferlan wrote: > >> Create local @obj and @def for the API's rather than referencing the > >> devs->objs[i][->def->]. It'll make future