Re: [libvirt] [RFC] virfile: fix cast-align error

2018-10-09 Thread Bjoern Walk
Michal Privoznik [2018-10-09, 04:52PM +0200]: > What header file are you looking at? From /usr/include/bits/statfs.h: It's s390x-specific hard-coded as an unsigned int. > > Also, I am against exposing any > > internal data types. > > It's not internal if it is exposed in a public header file. >

Re: [libvirt] The results of lspci are inconsistent between vfio reset pci devices and reset devices by sysfs interafce

2018-10-09 Thread Alex Williamson
On Wed, 10 Oct 2018 01:47:10 + "Wuzongyong (Euler Dept)" wrote: > > You're right. The initial states are not identical. > I found the function vfio_pci_pre_reset in qemu. > /* > * Stop any ongoing DMA by disconecting I/O, MMIO, and bus master. > * Also put INTx Disable in known

Re: [libvirt] The results of lspci are inconsistent between vfio reset pci devices and reset devices by sysfs interafce

2018-10-09 Thread Wuzongyong (Euler Dept)
> > > Hi, > > > > > > I start a virtual machine with commandline: > > > /usr/libexec/qemu-kvm --enable-kvm -smp 8 -m 8192 -device > > > vfio-pci,host=:81:00.0 > > > > > > Then I pause the qemu process before executing the main_loop > > > function by > > gdb. > > > At this moment, lspci show

Re: [libvirt] The results of lspci are inconsistent between vfio reset pci devices and reset devices by sysfs interafce

2018-10-09 Thread Wuzongyong (Euler Dept)
> > Hi, > > > > I start a virtual machine with commandline: > > /usr/libexec/qemu-kvm --enable-kvm -smp 8 -m 8192 -device > > vfio-pci,host=:81:00.0 > > > > Then I pause the qemu process before executing the main_loop function by > gdb. > > At this moment, lspci shows the regions are disabl

Re: [libvirt] [PATCHv5 07/19] util: Refactor code for creating resctrl group

2018-10-09 Thread John Ferlan
On 10/9/18 6:30 AM, Wang Huaqiang wrote: > The code for creating resctrl allocation group could be reused > for monitoring group, refactor it for reusing in the later patch. > > Signed-off-by: Wang Huaqiang > --- > src/util/virresctrl.c | 37 +++-- > 1 file cha

Re: [libvirt] [PATCHv5 02/19] util: Introduce resctrl monitor for CMT

2018-10-09 Thread John Ferlan
On 10/9/18 6:30 AM, Wang Huaqiang wrote: > Cache Monitoring Technology (aka CMT) provides the capability > to report cache utilization information of system task. > > This patch introduces the concept of resctrl monitor through > data structure virResctrlMonitor. > > Signed-off-by: Wang Huaqia

Re: [libvirt] [PATCHv5 06/19] util: Add monitor interface to determine path

2018-10-09 Thread John Ferlan
On 10/9/18 6:30 AM, Wang Huaqiang wrote: > Add interface for resctrl monitor to determine the path. > > Signed-off-by: Wang Huaqiang > --- > src/libvirt_private.syms | 1 + > src/util/virresctrl.c| 32 > src/util/virresctrl.h| 3 +++ > 3 files change

Re: [libvirt] [PATCHv5 05/19] util: Refactor code for determining allocation path

2018-10-09 Thread John Ferlan
On 10/9/18 6:30 AM, Wang Huaqiang wrote: > The code for determining resctrl allocation path could be reused > for monitor. Refactor it for reusing. > > Signed-off-by: Wang Huaqiang > --- > src/util/virresctrl.c | 33 +++-- > 1 file changed, 27 insertions(+), 6 dele

Re: [libvirt] [PATCHv5 04/19] util: Add interface for adding PID to monitor

2018-10-09 Thread John Ferlan
On 10/9/18 6:30 AM, Wang Huaqiang wrote: > Add interface for adding task PID to monitor. to the monitor > > Signed-off-by: Wang Huaqiang > --- > src/libvirt_private.syms | 1 + > src/util/virresctrl.c| 8 > src/util/virresctrl.h| 4 > 3 files changed, 13 insertions(+)

Re: [libvirt] [PATCHv5 03/19] util: Refactor code for adding PID to the resource group

2018-10-09 Thread John Ferlan
On 10/9/18 6:30 AM, Wang Huaqiang wrote: > The code of adding PID to the allocation could be reused, refactor it > for later reusing. reuse. > > Signed-off-by: Wang Huaqiang > --- > src/util/virresctrl.c | 26 +- > 1 file changed, 17 insertions(+), 9 deletions(-) >

Re: [libvirt] [PATCH v4 2/5] libxl: add support for PVH

2018-10-09 Thread Marek Marczykowski-Górecki
On Tue, Oct 09, 2018 at 04:45:01PM -0600, Jim Fehlig wrote: > On 10/7/18 9:39 AM, Marek Marczykowski-Górecki wrote: > > @@ -647,6 +669,22 @@ libxlMakeDomBuildInfo(virDomainDefPtr def, > > return -1; > > } > > #endif > > +} else if (pvh) { > > +if (VIR_STRDUP(b_

Re: [libvirt] [PATCH v4 2/5] libxl: add support for PVH

2018-10-09 Thread Jim Fehlig
On 10/7/18 9:39 AM, Marek Marczykowski-Górecki wrote: Since this is something between PV and HVM, it makes sense to put the setting in place where domain type is specified. To enable it, use It is also included in capabilities.xml, for every supported HVM guest type - it doesn't seems to be

Re: [libvirt] [PATCHv5 01/19] docs: Refactor schemas to support default allocation

2018-10-09 Thread John Ferlan
s/docs/conf,util/ It's more than just docs... On 10/9/18 6:30 AM, Wang Huaqiang wrote: > The resctrl default allocation is introduced in this patch, > which refers to the root directory (/sys/fs/resctrl) and > immediately be created after mounting, owns all the tasks > and cpus in the system an

Re: [libvirt] [Qemu-devel] [PATCH v2 0/3] HMP/snapshot changes - do not use ID anymore

2018-10-09 Thread Markus Armbruster
Cc: libvir-list for review of the compatibility argument below. Daniel Henrique Barboza writes: > Hey David, > > On 9/21/18 9:29 AM, Dr. David Alan Gilbert wrote: >> * Daniel Henrique Barboza (danielhb...@gmail.com) wrote: >>> changes in v2: >>> - removed the "RFC" marker; >>> - added a new patc

Re: [libvirt] [PATCHv5 00/19] Introduce x86 Cache Monitoring Technology (CMT)

2018-10-09 Thread John Ferlan
On 10/9/18 6:30 AM, Wang Huaqiang wrote: > This series of patches and the series already been merged introduce > the x86 Cache Monitoring Technology (CMT) to libvirt by interacting > with kernel resource control (resctrl) interface. CMT is one of the > Intel(R) x86 CPU feature which belongs to t

Re: [libvirt] [ocaml] reset and resync the libvirt-ocaml repository

2018-10-09 Thread Daniel P . Berrangé
On Thu, Sep 06, 2018 at 05:13:23PM +0200, Pino Toscano wrote: > Hi, > > for reasons mostly lost in the history, after the libvirt-ocaml > repository was converted to git, it was not used by its main author > (Rich Jones); the development continued on Rich's git, at > http://git.annexia.org/?p=oc

Re: [libvirt] [RFC v2] virfile: fix cast-align error

2018-10-09 Thread Daniel P . Berrangé
On Tue, Oct 09, 2018 at 05:55:29PM +0200, Marc Hartmayer wrote: > On s390x the struct member f_type of statsfs is hard coded to > 'unsigned int'. So let's try to determine the type by means of the GNU > extension typeof. > > This fixes the following error: > ../../src/util/virfile.c:3578:38: error

[libvirt] [RFC v2] virfile: fix cast-align error

2018-10-09 Thread Marc Hartmayer
On s390x the struct member f_type of statsfs is hard coded to 'unsigned int'. So let's try to determine the type by means of the GNU extension typeof. This fixes the following error: ../../src/util/virfile.c:3578:38: error: cast increases required alignment of target type [-Werror=cast-align]

Re: [libvirt] The results of lspci are inconsistent between vfio reset pci devices and reset devices by sysfs interafce

2018-10-09 Thread Alex Williamson
On Tue, 9 Oct 2018 12:11:29 + "Wuzongyong (Euler Dept)" wrote: > Hi, > > I start a virtual machine with commandline: > /usr/libexec/qemu-kvm --enable-kvm -smp 8 -m 8192 -device > vfio-pci,host=:81:00.0 > > Then I pause the qemu process before executing the main_loop function by gdb

[libvirt] [PATCH 1/2] qemu: Allow coldplugging of hub device

2018-10-09 Thread Han Han
https://bugzilla.redhat.com/show_bug.cgi?id=1375423 Signed-off-by: Han Han --- src/qemu/qemu_driver.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index a52e2495d5..130ce4cbd6 100644 --- a/src/qemu/qemu_driver.c +++ b/sr

[libvirt] [PATCH 2/2] qemu: Allow coldunplugging of hub device

2018-10-09 Thread Han Han
https://bugzilla.redhat.com/show_bug.cgi?id=1375423 Signed-off-by: Han Han --- src/conf/domain_conf.c | 30 ++ src/conf/domain_conf.h | 3 +++ src/libvirt_private.syms | 1 + src/qemu/qemu_driver.c | 10 +- 4 files changed, 43 insertions(+), 1 deletion

[libvirt] [PATCH 0/2] Allow coldplug and coldunplug of hub device

2018-10-09 Thread Han Han
Han Han (2): qemu: Allow coldplugging of hub device qemu: Allow coldunplugging of hub device src/conf/domain_conf.c | 30 ++ src/conf/domain_conf.h | 3 +++ src/libvirt_private.syms | 1 + src/qemu/qemu_driver.c | 16 ++-- 4 files changed, 48

Re: [libvirt] Overview of libvirt incremental backup API, part 2 (incremental/differential pull mode)

2018-10-09 Thread Eric Blake
On 10/9/18 8:29 AM, Nir Soffer wrote: On Fri, Oct 5, 2018 at 7:58 AM Eric Blake wrote: On 10/4/18 12:05 AM, Eric Blake wrote: The following (long) email describes a portion of the work-flow of how my proposed incremental backup APIs will work, along with the backend QMP commands that each one

Re: [libvirt] [RFC] virfile: fix cast-align error

2018-10-09 Thread Michal Privoznik
On 10/09/2018 04:39 PM, Bjoern Walk wrote: > Michal Privoznik [2018-10-09, 03:45PM +0200]: >> On 10/08/2018 08:41 PM, Marc Hartmayer wrote: >>> Use the correct type in order to fix the following error on s390x: >>> >>> In function 'virFileIsSharedFSType': >>> ../../src/util/virfile.c:3578:38: erro

[libvirt] [dbus PATCH] maint: fix compiler errors for FreeBSD

2018-10-09 Thread Katerina Koukiou
We were facing such errors: * error: unused function 'glib_slistautoptr_cleanup_virtDBusConnect Moving the G_DEFINE_AUTOPTR_CLEANUP_FUNC macros in the header files fixes the issue. Signed-off-by: Katerina Koukiou --- src/connect.c | 3 +-- src/connect.h | 5 + src/network.c | 4 +--- src/ne

Re: [libvirt] [RFC] virfile: fix cast-align error

2018-10-09 Thread Bjoern Walk
Michal Privoznik [2018-10-09, 03:45PM +0200]: > On 10/08/2018 08:41 PM, Marc Hartmayer wrote: > > Use the correct type in order to fix the following error on s390x: > > > > In function 'virFileIsSharedFSType': > > ../../src/util/virfile.c:3578:38: error: cast increases required alignment > > of

[libvirt] [PATCH 0/4] Couple of virFileIsShared* fixes

2018-10-09 Thread Michal Privoznik
This patch [1] got me looking into the code. I've found couple of issues which I'm fixing and also I'm introducing couple of new test cases. 1: https://www.redhat.com/archives/libvir-list/2018-October/msg00513.html Michal Prívozník (4): virfiletest: Fix test name prefix for virFileInData test

[libvirt] [PATCH 1/4] virfiletest: Fix test name prefix for virFileInData test

2018-10-09 Thread Michal Privoznik
Because of lacking virTestCounterReset() call, the old test cases name was preserved. Signed-off-by: Michal Privoznik --- tests/virfiletest.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/virfiletest.c b/tests/virfiletest.c index efe15485eb..19dd06e49e 100644 --- a/tests/virfiletest.

[libvirt] [PATCH 3/4] virFileIsSharedFSType: Detect direct mount points

2018-10-09 Thread Michal Privoznik
If the given path is already a mount point (e.g. a bind mount of a file, or simply a direct mount point of a FS), then our code fails to detect that because the first thing it does is cutting off part after last slash '/'. Signed-off-by: Michal Privoznik --- src/util/virfile.c | 8 tes

[libvirt] [PATCH 2/4] virfiletst: Test virFileIsSharedFS

2018-10-09 Thread Michal Privoznik
Introduce some basic test cases for virFileIsSharedFS(). More will be added later. In order to achieve desired result, mocks for setmntent() and statfs() need to be invented because the first thing that virFileIsSharedFS() does is calling the latter. If it finds a FUSE mount it'll call the former.

[libvirt] [PATCH 4/4] virfile: Rework virFileIsSharedFixFUSE

2018-10-09 Thread Michal Privoznik
There are couple of things wrong with the current implementation. The first one is that in the first loop the code tries to build a list of fuse.glusterfs mount points. Well, since the strings are allocated in a temporary buffer and are not duplicated this results in wrong decision made later in th

Re: [libvirt] [PATCH v2] virFileIsSharedFixFUSE: Copy mnt_dir when browsing mount table

2018-10-09 Thread Michal Privoznik
On 10/09/2018 09:10 AM, Han Han wrote: > Fix typos of function name in commit msg. > v1 version: > https://www.redhat.com/archives/libvir-list/2018-October/msg00511.html > > virFileIsSharedFixFUSE doesn't fix f_type when "fuse.glusterfs" > is not the last row of mount table. For example, it doesn

Re: [libvirt] [RFC] virfile: fix cast-align error

2018-10-09 Thread Michal Privoznik
On 10/08/2018 08:41 PM, Marc Hartmayer wrote: > Use the correct type in order to fix the following error on s390x: > > In function 'virFileIsSharedFSType': > ../../src/util/virfile.c:3578:38: error: cast increases required alignment of > target type [-Werror=cast-align] > virFileIsShared

Re: [libvirt] Regarding the installtion of libvirt on ubuntu

2018-10-09 Thread Andrea Bolognani
On Tue, 2018-10-09 at 13:34 +0100, Daniel P. Berrangé wrote: > On Wed, Oct 03, 2018 at 12:32:04PM +, Mousumi Paul wrote: > > I have installed libvirt-bin on ubuntu using the following command:sudo > > apt-get install libvirt-bin > > I checked the virsh version. It says 4.6.0.Now i want to reco

Re: [libvirt] Overview of libvirt incremental backup API, part 2 (incremental/differential pull mode)

2018-10-09 Thread Nir Soffer
On Fri, Oct 5, 2018 at 7:58 AM Eric Blake wrote: > On 10/4/18 12:05 AM, Eric Blake wrote: > > The following (long) email describes a portion of the work-flow of how > > my proposed incremental backup APIs will work, along with the backend > > QMP commands that each one executes. I will reply to

[libvirt] [PATCH v3 6/6] monitor: deprecate acl_show, acl_reset, acl_policy, acl_add, acl_remove

2018-10-09 Thread Daniel P . Berrangé
The various ACL related commands are obsolete now that the QAuthZ framework for authorization is fully integrated throughout QEMU network services. Mark it as deprecated with no replacement to be provided. Authorization is now provided by using 'object_add' together with the 'tls-authz' or 'sasl-a

[libvirt] [PATCH v3 5/6] vnc: allow specifying a custom authorization object name

2018-10-09 Thread Daniel P . Berrangé
From: "Daniel P. Berrange" The VNC server has historically had support for ACLs to check both the SASL username and the TLS x509 distinguished name. The VNC server was responsible for creating the initial ACL, and the client app was then responsible for populating it with rules using the HMP 'acl

[libvirt] [PATCH v3 2/6] nbd: allow authorization with nbd-server-start QMP command

2018-10-09 Thread Daniel P . Berrangé
From: "Daniel P. Berrange" As with the previous patch to qemu-nbd, the nbd-server-start QMP command also needs to be able to specify authorization when enabling TLS encryption. First the client must create a QAuthZ object instance using the 'object-add' command: { 'execute': 'object-add

[libvirt] [PATCH v3 4/6] chardev: add support for authorization for TLS clients

2018-10-09 Thread Daniel P . Berrangé
From: "Daniel P. Berrange" Currently any client which can complete the TLS handshake is able to use a chardev server. The server admin can turn on the 'verify-peer' option for the x509 creds to require the client to provide a x509 certificate. This means the client will have to acquire a certific

[libvirt] [PATCH v3 3/6] migration: add support for a "tls-authz" migration parameter

2018-10-09 Thread Daniel P . Berrangé
From: "Daniel P. Berrange" The QEMU instance that runs as the server for the migration data transport (ie the target QEMU) needs to be able to configure access control so it can prevent unauthorized clients initiating an incoming migration. This adds a new 'tls-authz' migration parameter that is

[libvirt] [PATCH v3 1/6] qemu-nbd: add support for authorization of TLS clients

2018-10-09 Thread Daniel P . Berrangé
From: "Daniel P. Berrange" Currently any client which can complete the TLS handshake is able to use the NBD server. The server admin can turn on the 'verify-peer' option for the x509 creds to require the client to provide a x509 certificate. This means the client will have to acquire a certificat

[libvirt] [PATCH v3 0/6] Add authorization support to all network services

2018-10-09 Thread Daniel P . Berrangé
v1: https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg04482.html v2: https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg05727.html This series builds on the core authorization framework: v5: https://lists.gnu.org/archive/html/qemu-devel/2018-10/msg01613.html enabling its use w

Re: [libvirt] Regarding the installtion of libvirt on ubuntu

2018-10-09 Thread Daniel P . Berrangé
On Wed, Oct 03, 2018 at 12:32:04PM +, Mousumi Paul wrote: > I have installed libvirt-bin on ubuntu using the following command:sudo > apt-get install libvirt-bin > I checked the virsh version. It says 4.6.0.Now i want to recompile libvirt > with esx, xen and hyperv driver.Therefore i went to

Re: [libvirt] Regarding openwsman requirement in libvirt configuration

2018-10-09 Thread Daniel P . Berrangé
On Wed, Oct 03, 2018 at 12:23:53PM +, Mousumi Paul wrote: > Trying to install libvirt 1.2.14 with the following command :./configure > --prefix=/usr --localstatedir=/var --sysconfdir=/etc --with-esx=yes > --with-xen=yes --with-hyperv=yes > > The above generates the following error: > configu

[libvirt] Regarding openwsman requirement in libvirt configuration

2018-10-09 Thread Mousumi Paul
Trying to install libvirt 1.2.14 with the following command :./configure --prefix=/usr --localstatedir=/var --sysconfdir=/etc --with-esx=yes --with-xen=yes --with-hyperv=yes The above generates the following error: configure: error: openwsman is required for the Hyper-V driver I have installed

[libvirt] Regarding the installtion of libvirt on ubuntu

2018-10-09 Thread Mousumi Paul
I have installed libvirt-bin on ubuntu using the following command:sudo apt-get install libvirt-bin I checked the virsh version. It says 4.6.0.Now i want to recompile libvirt with esx, xen and hyperv driver.Therefore i went to /usr/src/libvirt-4.6.0 and trying to run the following command:./conf

[libvirt] The results of lspci are inconsistent between vfio reset pci devices and reset devices by sysfs interafce

2018-10-09 Thread Wuzongyong (Euler Dept)
Hi, I start a virtual machine with commandline: /usr/libexec/qemu-kvm --enable-kvm -smp 8 -m 8192 -device vfio-pci,host=:81:00.0 Then I pause the qemu process before executing the main_loop function by gdb. At this moment, lspci shows the regions are disabled like below: 81:00.0 3D c

[libvirt] [PATCHv5 19/19] qemu: Setting up vcpu and adding pids to resctrl monitor groups during reconnection

2018-10-09 Thread Wang Huaqiang
Invoking qemuProcessSetupVcpus in process of VM reconnection. Signed-off-by: Wang Huaqiang --- src/qemu/qemu_process.c | 3 +++ src/util/virresctrl.c | 7 +++ 2 files changed, 10 insertions(+) diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index a4bbef6..f85aef0 100644 ---

[libvirt] [PATCHv5 07/19] util: Refactor code for creating resctrl group

2018-10-09 Thread Wang Huaqiang
The code for creating resctrl allocation group could be reused for monitoring group, refactor it for reusing in the later patch. Signed-off-by: Wang Huaqiang --- src/util/virresctrl.c | 37 +++-- 1 file changed, 23 insertions(+), 14 deletions(-) diff --git a/src/

[libvirt] [PATCHv5 17/19] qemu: refactor qemuDomainGetStatsCpu

2018-10-09 Thread Wang Huaqiang
Refactoring qemuDomainGetStatsCpu, make it possible to add more CPU statistics. Signed-off-by: Wang Huaqiang --- src/qemu/qemu_driver.c | 45 ++--- 1 file changed, 22 insertions(+), 23 deletions(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_drive

[libvirt] [PATCHv5 18/19] qemu: Report cache occupancy (CMT) with domstats

2018-10-09 Thread Wang Huaqiang
Adding the interface in qemu to report CMT statistic information through command 'virsh domstats --cpu-total'. Below is a typical output: # virsh domstats 1 --cpu-total Domain: 'ubuntu16.04-base' ... cpu.cache.monitor.count=2 cpu.cache.0.name=vcp

[libvirt] [PATCHv5 16/19] conf: Add a 'id' to virDomainResctrlDef

2018-10-09 Thread Wang Huaqiang
Adding element 'id' to virDomainResctrlDef. This 'id' reflects the attribute 'id' of of element 'cachetune in XML. virResctrlAlloc.id is a copy of virDomanResctrlDef.id. Signed-off-by: Wang Huaqiang --- src/conf/domain_conf.c | 20 src/conf/domain_conf.h | 1 + 2 files cha

[libvirt] [PATCHv5 09/19] util: Add more interfaces for resctrl monitor

2018-10-09 Thread Wang Huaqiang
Add interfaces monitor group to support operations such as add PID, set ID, remove group ... etc. The interface for getting cache occupancy information from the monitor is also added. Signed-off-by: Wang Huaqiang --- src/libvirt_private.syms | 6 ++ src/util/virresctrl.c| 209

[libvirt] [PATCHv5 15/19] qemu: enable resctrl monitor in qemu

2018-10-09 Thread Wang Huaqiang
Add functions for creating, destroying, reconnecting resctrl monitor in qemu according to the configuration in domain XML. Signed-off-by: Wang Huaqiang --- src/qemu/qemu_process.c | 49 ++--- 1 file changed, 46 insertions(+), 3 deletions(-) diff --git

[libvirt] [PATCHv5 14/19] Util: Add function for checking if monitor is running

2018-10-09 Thread Wang Huaqiang
Check monitor status by checking the PIDs are in file 'task' or not. Signed-off-by: Wang Huaqiang --- src/libvirt_private.syms | 1 + src/util/virresctrl.c| 84 +++- src/util/virresctrl.h| 4 +++ 3 files changed, 88 insertions(+), 1 deletion(

[libvirt] [PATCHv5 10/19] util: Introduce default monitor

2018-10-09 Thread Wang Huaqiang
In resctrl file system, more than one monitoring groups could be created within one allocation group, along with the creation of allocation group, a monitoring group is created at the same, which monitors the resource utilization information of whole allocation group. This patch is introducing the

[libvirt] [PATCHv5 08/19] util: Add interface for creating monitor group

2018-10-09 Thread Wang Huaqiang
Add interface for creating the resource monitoring group according to '@virResctrlMonitor->path'. Signed-off-by: Wang Huaqiang --- src/libvirt_private.syms | 1 + src/util/virresctrl.c| 28 src/util/virresctrl.h| 6 ++ 3 files changed, 35 insertions(+)

[libvirt] [PATCHv5 12/19] conf: Refactor virDomainResctrlAppend

2018-10-09 Thread Wang Huaqiang
Refactor virDomainResctrlAppend to facilitate virDomainResctrlDef with the capability to hold more element. Signed-off-by: Wang Huaqiang --- src/conf/domain_conf.c | 64 +++--- 1 file changed, 45 insertions(+), 19 deletions(-) diff --git a/src/conf/do

[libvirt] [PATCHv5 03/19] util: Refactor code for adding PID to the resource group

2018-10-09 Thread Wang Huaqiang
The code of adding PID to the allocation could be reused, refactor it for later reusing. Signed-off-by: Wang Huaqiang --- src/util/virresctrl.c | 26 +- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/src/util/virresctrl.c b/src/util/virresctrl.c index 18ee

[libvirt] [PATCHv5 13/19] conf: Add resctrl monitor configuration

2018-10-09 Thread Wang Huaqiang
Introducing element under to represent a cache monitor. Supports two kind of monitors, which are, monitor under default allocation or monitor under particular allocation. Monitor supervises the cache or memory bandwidth usage for interested vcpu thread set, if the vcpu thread set is belong to s

[libvirt] [PATCHv5 06/19] util: Add monitor interface to determine path

2018-10-09 Thread Wang Huaqiang
Add interface for resctrl monitor to determine the path. Signed-off-by: Wang Huaqiang --- src/libvirt_private.syms | 1 + src/util/virresctrl.c| 32 src/util/virresctrl.h| 3 +++ 3 files changed, 36 insertions(+) diff --git a/src/libvirt_private.syms b

[libvirt] [PATCHv5 02/19] util: Introduce resctrl monitor for CMT

2018-10-09 Thread Wang Huaqiang
Cache Monitoring Technology (aka CMT) provides the capability to report cache utilization information of system task. This patch introduces the concept of resctrl monitor through data structure virResctrlMonitor. Signed-off-by: Wang Huaqiang --- src/libvirt_private.syms | 1 + src/util/virresc

[libvirt] [PATCHv5 05/19] util: Refactor code for determining allocation path

2018-10-09 Thread Wang Huaqiang
The code for determining resctrl allocation path could be reused for monitor. Refactor it for reusing. Signed-off-by: Wang Huaqiang --- src/util/virresctrl.c | 33 +++-- 1 file changed, 27 insertions(+), 6 deletions(-) diff --git a/src/util/virresctrl.c b/src/util/vi

[libvirt] [PATCHv5 04/19] util: Add interface for adding PID to monitor

2018-10-09 Thread Wang Huaqiang
Add interface for adding task PID to monitor. Signed-off-by: Wang Huaqiang --- src/libvirt_private.syms | 1 + src/util/virresctrl.c| 8 src/util/virresctrl.h| 4 3 files changed, 13 insertions(+) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index d2573

[libvirt] [PATCHv5 11/19] conf: Refactor code for matching existing resctrls

2018-10-09 Thread Wang Huaqiang
Refactoring the code of matching the new resctrl with existing resctrl groups. Add the virObjectRef action into function virDomainResctrlVcpuMatch. Signed-off-by: Wang Huaqiang --- src/conf/domain_conf.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/conf/domain_conf.

[libvirt] [PATCHv5 00/19] Introduce x86 Cache Monitoring Technology (CMT)

2018-10-09 Thread Wang Huaqiang
This series of patches and the series already been merged introduce the x86 Cache Monitoring Technology (CMT) to libvirt by interacting with kernel resource control (resctrl) interface. CMT is one of the Intel(R) x86 CPU feature which belongs to the Resource Director Technology (RDT). CMT reports t

[libvirt] [PATCHv5 01/19] docs: Refactor schemas to support default allocation

2018-10-09 Thread Wang Huaqiang
The resctrl default allocation is introduced in this patch, which refers to the root directory (/sys/fs/resctrl) and immediately be created after mounting, owns all the tasks and cpus in the system and can make full use of all resources. It does not intentionally allocate any dedicated amount of r

Re: [libvirt] [PATCHv2 1/4] util: Introduce monitor capability interface

2018-10-09 Thread Wang, Huaqiang
Hi Jano, Recognized there was already a commit for a fixing: 7bff646d71aa90ed8727ef99be29d6d2ab5d8f06. And now I got your idea. Thanks Huaqiang > -Original Message- > From: Wang, Huaqiang > Sent: Tuesday, October 9, 2018 5:55 PM > To: 'Ján Tomko' ; John Ferlan > Cc: libvir-list@redhat

Re: [libvirt] [PATCHv2 1/4] util: Introduce monitor capability interface

2018-10-09 Thread Wang, Huaqiang
> -Original Message- > From: Ján Tomko [mailto:jto...@redhat.com] > Sent: Friday, October 5, 2018 10:42 PM > To: John Ferlan > Cc: Wang, Huaqiang ; libvir-list@redhat.com; Feng, > Shaohe ; Niu, Bing ; Ding, Jian- > feng ; Zang, Rui > Subject: Re: [libvirt] [PATCHv2 1/4] util: Introduce

Re: [libvirt] [RFC] virfile: fix cast-align error

2018-10-09 Thread Bjoern Walk
Marc Hartmayer [2018-10-08, 08:41PM +0200]: > Use the correct type in order to fix the following error on s390x: > > In function 'virFileIsSharedFSType': > ../../src/util/virfile.c:3578:38: error: cast increases required alignment of > target type [-Werror=cast-align] > virFileIsSharedF

Re: [libvirt] [PATCH] qemu: use "id" instead of deprecated "name" for -net

2018-10-09 Thread Thomas Huth
On 2018-10-08 16:54, Ján Tomko wrote: > -net name= will be deprecated in QEMU 3.1: > commit 101625a4d4ac7e96227a156bc5f6d21a9cc383cd > net: Deprecate the "name" parameter of -net > git describe: v3.0.0-791-g101625a4d4 > > Use the id option instead, supported since QEMU 1.2: > commit 6687b79d63

[libvirt] [PATCH v2] virFileIsSharedFixFUSE: Copy mnt_dir when browsing mount table

2018-10-09 Thread Han Han
Fix typos of function name in commit msg. v1 version: https://www.redhat.com/archives/libvir-list/2018-October/msg00511.html virFileIsSharedFixFUSE doesn't fix f_type when "fuse.glusterfs" is not the last row of mount table. For example, it doesn't works on the mount table like following: 10.XX.X