Re: [libvirt] [PATCH] qemu: Fix double free in qemuDomainSecretAESClear

2018-06-06 Thread Peter Krempa
On Tue, Jun 05, 2018 at 16:34:47 -0400, John Ferlan wrote: > Commit id 02b031a4 added a secondary path from which the > incoming @secinfo would not be free'd until the private > data was freed in qemuDomainStorageSourcePrivateDispose. > > However, by doing this the original intention to free > @*s

Re: [libvirt] [PATCH] qemu: fix msg could be a wild pointer in qemuMonitorIOProcess()

2018-06-06 Thread zhuweilun
在 2018/6/5 15:10, Peter Krempa 写道: > On Tue, Jun 05, 2018 at 10:14:39 +0800, Shannon Zhao wrote: >> From: Weilun Zhu >> >> As qemuMonitorJSONIOProcess() will unlock the qemu monitor, there is >> some extreme situation, eg qemu send message to monitor twice in a short >> time, where the local vir

Re: [libvirt] [RFC PATCH 0/2] Introduce RDT memory bandwidth allocation support

2018-06-06 Thread bing.niu
Hi Pavel, On 2018年06月06日 13:56, bing.niu wrote: Then there is the domain XML, for CAT we use this:    ...    ...       ...       ... so the possible domain XML could look like this:    ...    ...       ...       ... Ag

Re: [libvirt] [PATCH] docs: document mandatory signoffs in governance.html

2018-06-06 Thread Daniel P . Berrangé
On Tue, Jun 05, 2018 at 09:02:40PM +0200, Ján Tomko wrote: > Amend the paragraphs about no CLAs and implicit license > agreements to mention mandatory Signed-off-by tags. > > Signed-off-by: Ján Tomko > --- > This is duplicating information, but I did not find a reasonable > way to link the number

Re: [libvirt] [PATCH 06/13] qemu: Generate and use zPCI device in QEMU command line

2018-06-06 Thread Yi Min Zhao
在 2018/6/2 下午10:22, Ján Tomko 写道: On Thu, May 24, 2018 at 02:24:31PM +0200, Xiao Feng Ren wrote: From: Yi Min Zhao Add new functions to generate zPCI command string and append it to QEMU command line. Signed-off-by: Yi Min Zhao Reviewed-by: Boris Fiuczynski Reviewed-by: Stefan Zimmermann

Re: [libvirt] [PATCH v7 3/9] expose virNodeGetSEVCapability API

2018-06-06 Thread Erik Skultety
On Tue, Jun 05, 2018 at 12:59:25PM -0500, Brijesh Singh wrote: > The API can be used by application to query the SEV capability. > > Signed-off-by: Brijesh Singh <> > --- > include/libvirt/libvirt-host.h | 42 + > src/driver-hypervisor.h | 6 +++ > src/libvirt-hos

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Daniel P . Berrangé
On Wed, Jun 06, 2018 at 08:24:59AM +0200, Andrea Bolognani wrote: > On Tue, 2018-06-05 at 18:03 +0100, Daniel P. Berrangé wrote: > > We can't use docker on centos6 either and believe it or not the host > > doesn't have hardware virt either. > > > > I could possibly setup libvirt lxc to run the job

Re: [libvirt] [PATCH v7 0/9] x86: Secure Encrypted Virtualization (AMD)

2018-06-06 Thread Erik Skultety
... > Changes since v6: > * add API to get SEV PDH and Certificate chain data > * drop virsh command changes. We can revisit this later when we have > more visibility on setter. You're going to have to split patch 4 (or 3 for that matter) into multiple patches, drop patch 3 (or 4 depending on w

Re: [libvirt] [PATCH] qemu: fix msg could be a wild pointer in qemuMonitorIOProcess()

2018-06-06 Thread Peter Krempa
On Wed, Jun 06, 2018 at 11:46:07 +0800, zhuweilun wrote: > > > 在 2018/6/5 15:10, Peter Krempa 写道: > > On Tue, Jun 05, 2018 at 10:14:39 +0800, Shannon Zhao wrote: > >> From: Weilun Zhu > >> > >> As qemuMonitorJSONIOProcess() will unlock the qemu monitor, there is > >> some extreme situation, eg q

Re: [libvirt] [PATCH] travis: switch to using Ubuntu 16.04 and 18.04

2018-06-06 Thread Andrea Bolognani
On Tue, 2018-06-05 at 18:47 +0100, Daniel P. Berrangé wrote: > The container images provided by Travis only support Ubuntu 14.04, > however, Travis has ability to run docker, which allows the build > script to use arbitrary OS images. This takes advantage of that to > convert the build over to Ubun

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 09:45 +0100, Daniel P. Berrangé wrote: > On Wed, Jun 06, 2018 at 08:24:59AM +0200, Andrea Bolognani wrote: > > On Tue, 2018-06-05 at 18:03 +0100, Daniel P. Berrangé wrote: > > > We can't use docker on centos6 either and believe it or not the host > > > doesn't have hardware vi

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Peter Krempa
On Wed, Jun 06, 2018 at 11:44:37 +0200, Andrea Bolognani wrote: > On Wed, 2018-06-06 at 09:45 +0100, Daniel P. Berrangé wrote: > > On Wed, Jun 06, 2018 at 08:24:59AM +0200, Andrea Bolognani wrote: > > > On Tue, 2018-06-05 at 18:03 +0100, Daniel P. Berrangé wrote: > > > > We can't use docker on cent

Re: [libvirt] [RFC PATCH 6/6] qemu: Format pseries.cap-hpt-mps on the command line

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 11:14 +1000, David Gibson wrote: > Personally I think the shift is *more* usable than a raw page size, > since the latter is inevitably going to involve counting a bunch of > zeroes to see if it's the number you meant. Allowing forms like "16M" > / "16G" could be nicer; not s

Re: [libvirt] [RFC PATCH 6/6] qemu: Format pseries.cap-hpt-mps on the command line

2018-06-06 Thread Peter Krempa
On Wed, Jun 06, 2018 at 12:02:12 +0200, Andrea Bolognani wrote: > On Wed, 2018-06-06 at 11:14 +1000, David Gibson wrote: > > Personally I think the shift is *more* usable than a raw page size, > > since the latter is inevitably going to involve counting a bunch of > > zeroes to see if it's the numb

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 11:54 +0200, Peter Krempa wrote: > Well, so we need to be able to run configure so that we can create > makefiles which build the docs. > > If we extract the steps to build the docs from makefile into a > standalone script called by the makefile we still can build the web > w

Re: [libvirt] [RFC PATCH 6/6] qemu: Format pseries.cap-hpt-mps on the command line

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 12:04 +0200, Peter Krempa wrote: > On Wed, Jun 06, 2018 at 12:02:12 +0200, Andrea Bolognani wrote: > > On Wed, 2018-06-06 at 11:14 +1000, David Gibson wrote: > > > TBH, if the user is already thinking about page sizes at this low > > > level, I don't think doing it by shift is

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Daniel P . Berrangé
On Wed, Jun 06, 2018 at 12:05:28PM +0200, Andrea Bolognani wrote: > On Wed, 2018-06-06 at 11:54 +0200, Peter Krempa wrote: > > Well, so we need to be able to run configure so that we can create > > makefiles which build the docs. > > > > If we extract the steps to build the docs from makefile into

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Daniel P . Berrangé
On Wed, Jun 06, 2018 at 11:54:41AM +0200, Peter Krempa wrote: > On Wed, Jun 06, 2018 at 11:44:37 +0200, Andrea Bolognani wrote: > > On Wed, 2018-06-06 at 09:45 +0100, Daniel P. Berrangé wrote: > > > On Wed, Jun 06, 2018 at 08:24:59AM +0200, Andrea Bolognani wrote: > > > > On Tue, 2018-06-05 at 18:0

Re: [libvirt] [PATCH] travis: switch to using Ubuntu 16.04 and 18.04

2018-06-06 Thread Daniel P . Berrangé
On Wed, Jun 06, 2018 at 11:27:38AM +0200, Andrea Bolognani wrote: > On Tue, 2018-06-05 at 18:47 +0100, Daniel P. Berrangé wrote: > > The container images provided by Travis only support Ubuntu 14.04, > > however, Travis has ability to run docker, which allows the build > > script to use arbitrary O

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 11:20 +0100, Daniel P. Berrangé wrote: > On Wed, Jun 06, 2018 at 12:05:28PM +0200, Andrea Bolognani wrote: > > We also need to be able to run 'make dist' in order to produce > > nightly snapshots. > > > > Whether those are actually useful to anyone in $currentyear is of > > c

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 11:21 +0100, Daniel P. Berrangé wrote: > On Wed, Jun 06, 2018 at 11:54:41AM +0200, Peter Krempa wrote: > > If we extract the steps to build the docs from makefile into a > > standalone script called by the makefile we still can build the web > > without the need to configure e

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Michal Privoznik
On 06/06/2018 11:44 AM, Andrea Bolognani wrote: > On Wed, 2018-06-06 at 09:45 +0100, Daniel P. Berrangé wrote: >> On Wed, Jun 06, 2018 at 08:24:59AM +0200, Andrea Bolognani wrote: >>> On Tue, 2018-06-05 at 18:03 +0100, Daniel P. Berrangé wrote: We can't use docker on centos6 either and believe

Re: [libvirt] [PATCH] qemu: Honour

2018-06-06 Thread Ruben Kerkhof
Hi Michal, Replying to an old thread: On Fri, Aug 4, 2017 at 9:55 AM, Michal Privoznik wrote: > I think this patch enables exactly that. The VM admins don't start the > domains by hand but probably have some SW that starts configured domains > whenever not running. E.g. if one domain crashes, t

Re: [libvirt] [ v3 2/4] 1) Loader: Add a more elaborate definition.

2018-06-06 Thread Prerna
On Mon, Jun 4, 2018 at 6:24 PM, John Ferlan wrote: > > On 05/21/2018 07:10 AM, Prerna Saxena wrote: > > Augment definition to include virStorageSourcePtr that > > more comprehensively describes the nature of backing element. > > Also include flags for annotating if input XML definition is > > old

Re: [libvirt] [PATCH] travis: switch to using Ubuntu 16.04 and 18.04

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 11:28 +0100, Daniel P. Berrangé wrote: > On Wed, Jun 06, 2018 at 11:27:38AM +0200, Andrea Bolognani wrote: > > We will probably want to do that, since installing packages takes > > quite a bit of time and using Docker like this apparently causes > > jobs to serialize, which ma

Re: [libvirt] [PATCH v2 1/5] configure: Require GnuTLS

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 12:51 +0200, Michal Privoznik wrote: > On 06/06/2018 11:44 AM, Andrea Bolognani wrote: > > The lxc route sounds like a decent stop-gap measure until either > > the current box is upgraded or everything is moved off to a new > > box running CentOS 7, whenever that might be. >

[libvirt] [PATCH 0/2] qemu: Fix memleak in qemuBuildNumaArgStr

2018-06-06 Thread Michal Privoznik
*** BLURB HERE *** Michal Privoznik (2): qemu: Fix memleak in qemuBuildNumaArgStr qemuBuildNumaArgStr: Simplify @nodeBackends src/qemu/qemu_command.c | 11 --- 1 file changed, 4 insertions(+), 7 deletions(-) -- 2.16.4 -- libvir-list mailing list libvir-list@redhat.com https://www.

[libvirt] [PATCH 1/2] qemu: Fix memleak in qemuBuildNumaArgStr

2018-06-06 Thread Michal Privoznik
We are allocating each individual buffer in @nodeBackends array but never free it. ==22516== 96 bytes in 4 blocks are definitely lost in loss record 166 of 195 ==22516==at 0x4C2EF26: calloc (vg_replace_malloc.c:711) ==22516==by 0x5D2C7D5: virAlloc (viralloc.c:144) ==22516==by 0x56FAABD

[libvirt] [PATCH 2/2] qemuBuildNumaArgStr: Simplify @nodeBackends

2018-06-06 Thread Michal Privoznik
Instead of array of pointers to individual buffers it can be array of buffers directly. Signed-off-by: Michal Privoznik --- src/qemu/qemu_command.c | 15 +-- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index fb5bb26

Re: [libvirt] [PATCH 2/2] qemuBuildNumaArgStr: Simplify @nodeBackends

2018-06-06 Thread Peter Krempa
On Wed, Jun 06, 2018 at 13:13:14 +0200, Michal Privoznik wrote: > Instead of array of pointers to individual buffers it can be > array of buffers directly. > > Signed-off-by: Michal Privoznik > --- > src/qemu/qemu_command.c | 15 +-- > 1 file changed, 5 insertions(+), 10 deletions(-)

Re: [libvirt] [PATCH] virQEMUCapsFreeHostCPUModel: Don't always free host cpuData

2018-06-06 Thread Ján Tomko
On Tue, Jun 05, 2018 at 09:24:53AM +0200, Michal Privoznik wrote: This function exists because of 5276ec712a44b36. But it is missing initial check just like virQEMUCapsInitHostCPUModel() has. Signed-off-by: Michal Privoznik --- src/qemu/qemu_capabilities.c | 4 src/qemu/qemu_capspriv.h

Re: [libvirt] [PATCH] travis: switch to using Ubuntu 16.04 and 18.04

2018-06-06 Thread Daniel P . Berrangé
On Wed, Jun 06, 2018 at 01:01:05PM +0200, Andrea Bolognani wrote: > On Wed, 2018-06-06 at 11:28 +0100, Daniel P. Berrangé wrote: > > On Wed, Jun 06, 2018 at 11:27:38AM +0200, Andrea Bolognani wrote: > > > We will probably want to do that, since installing packages takes > > > quite a bit of time an

Re: [libvirt] [RFC PATCH 0/7] Enable vfio-pci 'property' for mediated devices

2018-06-06 Thread Erik Skultety
On Tue, Jun 05, 2018 at 11:52:03AM +0200, Gerd Hoffmann wrote: > Hi, > > > > TL;DR: > > > - we have a new attribute value for vfio-pci mediated devices called > > > 'display' > > > -> devices can now format this new 'display=on/off' property to the > > > cmdline > > Good. > > > > - if user

Re: [libvirt] [PATCH 02/12] Introduce new domain create API virDomainCreateWithParams

2018-06-06 Thread Pino Toscano
On Wednesday, 16 May 2018 18:31:26 CEST Daniel P. Berrangé wrote: > On Wed, May 16, 2018 at 06:21:40PM +0200, Christian Borntraeger wrote: > > > > > > On 05/16/2018 05:35 PM, Daniel P. Berrangé wrote: > > > On Wed, May 16, 2018 at 05:30:33PM +0200, Marc Hartmayer wrote: > > >> On Wed, May 09, 201

Re: [libvirt] [PATCH v1 01/18] add macros for implementing automatic cleanup functionality

2018-06-06 Thread Sukrit Bhatnagar
On Tue, 5 Jun 2018 at 21:00, Erik Skultety wrote: > > On Sun, Jun 03, 2018 at 01:41:59PM +0530, Sukrit Bhatnagar wrote: > > New macros are added to src/util/viralloc.h which help in > > adding cleanup attribute to variable declarations. > > > > Signed-off-by: Sukrit Bhatnagar > > If you recall th

[libvirt] [PATCH] fdstream: Report error from the I/O thread

2018-06-06 Thread John Ferlan
https://bugzilla.redhat.com/show_bug.cgi?id=1529059 Commit id 0fe4aa14 added the thread specific error message reporting (or save) to virFDStreamEvent; however, as processing goes via virStream{Send|SendHole|Recv} via calls from daemonStreamHandle{WriteData|Hole|Read} the last error gets reset in

[libvirt] [PATCH] qemu: Check for existing hostdev address for cold attach device

2018-06-06 Thread John Ferlan
https://bugzilla.redhat.com/show_bug.cgi?id=1559867 Add a check if the incoming with specified already exists and if so fail the attach. Signed-off-by: John Ferlan --- src/qemu/qemu_driver.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_drive

[libvirt] [PATCH] storage: minor fix in luks encrypted volume creation

2018-06-06 Thread Katerina Koukiou
This patch fixes the case when creating a luks encrypted volume via an xml file without 'secret' element. libvirtd was receiving SIGSEGV, now proper error is reported for the missing element. (see bz 1468422) Signed-off-by: Katerina Koukiou --- src/storage/storage_util.c | 7 +++ 1 file chan

Re: [libvirt] [PATCH] fdstream: Report error from the I/O thread

2018-06-06 Thread Michal Privoznik
On 06/06/2018 04:15 PM, John Ferlan wrote: > https://bugzilla.redhat.com/show_bug.cgi?id=1529059 > > Commit id 0fe4aa14 added the thread specific error message > reporting (or save) to virFDStreamEvent; however, as processing > goes via virStream{Send|SendHole|Recv} via calls from > daemonStreamHa

Re: [libvirt] [PATCH] storage: minor fix in luks encrypted volume creation

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 16:54 +0200, Katerina Koukiou wrote: > This patch fixes the case when creating a luks encrypted volume > via an xml file without 'secret' element. > libvirtd was receiving SIGSEGV, now proper error is reported for > the missing element. (see bz 1468422) Something like Reso

Re: [libvirt] [PATCH] storage: minor fix in luks encrypted volume creation

2018-06-06 Thread Ján Tomko
s/minor fix/fix crash/ in the title On Wed, Jun 06, 2018 at 04:54:20PM +0200, Katerina Koukiou wrote: This patch fixes the case when creating a luks encrypted volume s/This patch fixes/Fix/ via an xml file without 'secret' element. libvirtd was receiving SIGSEGV, now proper error is reported

Re: [libvirt] [PATCH] storage: minor fix in luks encrypted volume creation

2018-06-06 Thread Ján Tomko
On Wed, Jun 06, 2018 at 05:30:15PM +0200, Andrea Bolognani wrote: On Wed, 2018-06-06 at 16:54 +0200, Katerina Koukiou wrote: This patch fixes the case when creating a luks encrypted volume via an xml file without 'secret' element. libvirtd was receiving SIGSEGV, now proper error is reported for

Re: [libvirt] [PATCH v9 00/17] Add support for TPM emulator

2018-06-06 Thread Stefan Berger
On 06/04/2018 11:46 AM, Stefan Berger wrote: This series of patches adds support for the TPM emulator backend that is available in QEMU and based on swtpm + libtpms. It allows to attach a TPM 1.2 or 2.0 to a QEMU VM. sVirt labels are used for labeling the swtpm process, its Unix socket, and log f

Re: [libvirt] [PATCH] storage: minor fix in luks encrypted volume creation

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 17:35 +0200, Ján Tomko wrote: > On Wed, Jun 06, 2018 at 05:30:15PM +0200, Andrea Bolognani wrote: > > On Wed, 2018-06-06 at 16:54 +0200, Katerina Koukiou wrote: [] > > > (see bz 1468422) > > > > Something like > > > > Resolves: https://bugzilla.redhat.com/show_bug.cgi?i

Re: [libvirt] [PATCH] storage: minor fix in luks encrypted volume creation

2018-06-06 Thread Andrea Bolognani
On Wed, 2018-06-06 at 17:30 +0200, Ján Tomko wrote: [...] > > +if (!enc->secrets) { > > You can use enc->secrets != 1, to match the error message. > > But the > 1 cause will be caught anyway later in > storageBackendCreateQemuImgCheckEncryption which cannot be simply called > before here beca

Re: [libvirt] [PATCH v7 3/9] expose virNodeGetSEVCapability API

2018-06-06 Thread Brijesh Singh
On 06/06/2018 03:45 AM, Erik Skultety wrote: On Tue, Jun 05, 2018 at 12:59:25PM -0500, Brijesh Singh wrote: The API can be used by application to query the SEV capability. Signed-off-by: Brijesh Singh <> --- include/libvirt/libvirt-host.h | 42 + src/driver-hypervisor

[libvirt] [go PATCH] Blacklist virGetLastError{Code,Domain}

2018-06-06 Thread Daniel P . Berrangé
These methods will not be exposed to apps, since we always return all errors. Signed-off-by: Daniel P. Berrangé --- api_test.go | 2 ++ 1 file changed, 2 insertions(+) Pushed as a trivial build fix diff --git a/api_test.go b/api_test.go index 27f77dd..53632df 100644 --- a/api_test.go +++ b/api

[libvirt] [python PATCH] Blacklist virGetLastError{Code,Domain}

2018-06-06 Thread Daniel P . Berrangé
These methods will not be exposed to apps, since we auto raise all errors. Signed-off-by: Daniel P. Berrangé --- sanitytest.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) Pushed as a trivial build fix diff --git a/sanitytest.py b/sanitytest.py index 190d32b..d5c23dc 100644 --- a/s

[libvirt] [perl PATCH] Blacklist virGetLastError{Code,Domain}

2018-06-06 Thread Daniel P . Berrangé
These methods will not be exposed to apps, since we auto raise all errors. Signed-off-by: Daniel P. Berrangé --- t/030-api-coverage.t | 2 ++ 1 file changed, 2 insertions(+) Pushed as a trivial build fix diff --git a/t/030-api-coverage.t b/t/030-api-coverage.t index 39d6146..15d4a77 100644 ---

Re: [libvirt] [PATCH v1 01/18] add macros for implementing automatic cleanup functionality

2018-06-06 Thread Erik Skultety
On Wed, Jun 06, 2018 at 06:42:29PM +0530, Sukrit Bhatnagar wrote: > On Tue, 5 Jun 2018 at 21:00, Erik Skultety wrote: > > > > On Sun, Jun 03, 2018 at 01:41:59PM +0530, Sukrit Bhatnagar wrote: > > > New macros are added to src/util/viralloc.h which help in > > > adding cleanup attribute to variable

Re: [libvirt] [PATCH] storage: minor fix in luks encrypted volume creation

2018-06-06 Thread Ján Tomko
On Wed, Jun 06, 2018 at 05:41:58PM +0200, Andrea Bolognani wrote: On Wed, 2018-06-06 at 17:35 +0200, Ján Tomko wrote: On Wed, Jun 06, 2018 at 05:30:15PM +0200, Andrea Bolognani wrote: > On Wed, 2018-06-06 at 16:54 +0200, Katerina Koukiou wrote: [] > > (see bz 1468422) > > Something like >

[libvirt] [PATCH v2] travis: switch to using Ubuntu 16.04 and 18.04

2018-06-06 Thread Daniel P . Berrangé
The container images provided by Travis only support Ubuntu 14.04, however, Travis has ability to run docker, which allows the build script to use arbitrary OS images. This takes advantage of that to convert the build over to Ubuntu 16.04 and 18.04 This is using the official Ubuntu provided images

[libvirt] [PATCH 0/2] cmdDomblkinfo: introduce --all to show all

2018-06-06 Thread Chen Hanxiao
This series introduce --all to cmdDomblkinfo to show all block devices info in one cmd. Likes a combination of domblklist and domblkinfo. Chen Hanxiao (2): cmdDomblkinfo: introduce --all to show all block devices info news: add cmdDomblkinfo --all option docs/news.xml| 8 +++

[libvirt] [PATCH 2/2] news: add cmdDomblkinfo --all option

2018-06-06 Thread Chen Hanxiao
From: Chen Hanxiao Update news for cmdDomblkinfo --all option. Signed-off-by: Chen Hanxiao --- docs/news.xml | 8 1 file changed, 8 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index c45850f625..daee3aa6b7 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -123,6 +123,14 @

[libvirt] [PATCH 1/2] cmdDomblkinfo: introduce --all to show all block devices info

2018-06-06 Thread Chen Hanxiao
From: Chen Hanxiao This patch introduces --all to show all block devices info of guests like: virsh # domblkinfo w08 --all Target CapacityAllocation Physical --- hda42949672960 9878110208 9878110208 vda1073

[libvirt] [PATCH] util: Implement and use virFileIsRegular() rather than d_type

2018-06-06 Thread Stefan Berger
The dirent's d_type field is not portable to all platforms. So we have to use stat() to determine the type of file for the functions that need to be cross-platform. Fix virFileChownFiles() by calling the new virFileIsRegular() function. Signed-off-by: Stefan Berger --- src/libvirt_private.syms |

Re: [libvirt] [PATCH v1 01/18] add macros for implementing automatic cleanup functionality

2018-06-06 Thread Sukrit Bhatnagar
On Wed, 6 Jun 2018 at 21:25, Erik Skultety wrote: > > On Wed, Jun 06, 2018 at 06:42:29PM +0530, Sukrit Bhatnagar wrote: > > On Tue, 5 Jun 2018 at 21:00, Erik Skultety wrote: > > > > > > On Sun, Jun 03, 2018 at 01:41:59PM +0530, Sukrit Bhatnagar wrote: > > > > New macros are added to src/util/vira

[libvirt] [PATCH] Don't use enums in TPM struct fields

2018-06-06 Thread Daniel P . Berrangé
When using an enum in a struct field, the compiler is free to decide to make it an unsigned type if it desires. This in turn leads to bugs when code does if ((def->foo = virDomainFooTypeFromString(str)) < 0) ... because 'def->foo' can't technically have an unsigned value from the compi

Re: [libvirt] [PATCH] util: Implement and use virFileIsRegular() rather than d_type

2018-06-06 Thread Daniel P . Berrangé
On Wed, Jun 06, 2018 at 12:37:06PM -0400, Stefan Berger wrote: > The dirent's d_type field is not portable to all platforms. So we have > to use stat() to determine the type of file for the functions that need > to be cross-platform. Fix virFileChownFiles() by calling the new > virFileIsRegular() f

Re: [libvirt] [PATCH] util: Implement and use virFileIsRegular() rather than d_type

2018-06-06 Thread Stefan Berger
On 06/06/2018 12:48 PM, Daniel P. Berrangé wrote: Reviewed-by: Daniel P. Berrangé Thanks. I pushed this.   Stefan -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list

Re: [libvirt] [PATCH] util: Implement and use virFileIsRegular() rather than d_type

2018-06-06 Thread Eric Blake
On 06/06/2018 11:37 AM, Stefan Berger wrote: The dirent's d_type field is not portable to all platforms. So we have to use stat() to determine the type of file for the functions that need to be cross-platform. Fix virFileChownFiles() by calling the new virFileIsRegular() function. Signed-off-by:

[libvirt] Mystery of qemu being unable to open NBD Unix domain socket in current directory

2018-06-06 Thread Richard W.M. Jones
I'm chasing down a very frustrating bug which only happens on i686 & Koji during the nbdkit tests and seemingly nowhere else. Anyway this is what I've been able to put together: The libguestfs appliance (guest) is created with this XML snippet: It fails to

[libvirt] [PATCH v8 01/11] qemu: provide support to query the SEV capability

2018-06-06 Thread Brijesh Singh
QEMU version >= 2.12 provides support for launching an encrypted VMs on AMD x86 platform using Secure Encrypted Virtualization (SEV) feature. This patch adds support to query the SEV capability from the qemu. Signed-off-by: Brijesh Singh --- src/conf/domain_capabilities.c | 1

[libvirt] [PATCH v8 0/9] x86: Secure Encrypted Virtualization (AMD)

2018-06-06 Thread Brijesh Singh
This patch series provides support for launching an encrypted guest using AMD's new Secure Encrypted Virtualization (SEV) feature. SEV is an extension to the AMD-V architecture which supports running multiple VMs under the control of a hypervisor. When enabled, SEV feature allows the memory conte

[libvirt] [PATCH v8 03/11] libvirt: add new public API to get SEV Info

2018-06-06 Thread Brijesh Singh
The API can be used by application to retrieve the Platform Diffie-Hellman Key and Platform Certificate chain. Signed-off-by: Brijesh Singh <> --- include/libvirt/libvirt-host.h | 42 + src/driver-hypervisor.h| 6 ++ src/libvirt-host.c

[libvirt] [PATCH v8 02/11] conf: expose SEV feature in domain capabilities

2018-06-06 Thread Brijesh Singh
Extend hypervisor capabilities to include sev feature. When available, hypervisor supports launching an encrypted VM on AMD platform. The sev feature tag provides additional details like Platform Diffie-Hellman (PDH) key and certificate chain which can be used by the guest owner to establish a cryp

[libvirt] [PATCH v8 08/11] qemu: add support to launch SEV guest

2018-06-06 Thread Brijesh Singh
QEMU >= 2.12 provides 'sev-guest' object which is used to launch encrypted VMs on AMD platform using SEV feature. The various inputs required to launch SEV guest is provided through the tag. A typical SEV guest launch command line looks like this: # $QEMU ...\ -object sev-guest,id=sev0,cbitpos=

[libvirt] [PATCH v8 04/11] remote: implement the remote protocol for virNodeSEVInfo()

2018-06-06 Thread Brijesh Singh
Add remote support for virNodeSEVInfo(). Signed-off-by: Brijesh Singh <> --- src/remote/remote_daemon_dispatch.c | 44 + src/remote/remote_driver.c | 40 + src/remote/remote_protocol.x| 22 ++- sr

[libvirt] [PATCH v8 05/11] qemu: Add support to get the SEV info

2018-06-06 Thread Brijesh Singh
Signed-off-by: Brijesh Singh <> --- src/qemu/qemu_capabilities.c | 7 src/qemu/qemu_capabilities.h | 4 ++ src/qemu/qemu_driver.c | 91 3 files changed, 102 insertions(+) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabiliti

[libvirt] [PATCH v8 07/11] qemu/cgroup: add /dev/sev in shared devices list

2018-06-06 Thread Brijesh Singh
QEMU uses /dev/sev device while creating the SEV guest, lets add /dev/sev in the list of devices allowed to be accessed by the QEMU. Signed-off-by: Brijesh Singh <> Reviewed-by: Erik Skultety --- docs/drvqemu.html.in | 1 + src/qemu/qemu.conf | 2 +- src/qemu/qemu_c

[libvirt] [PATCH v8 06/11] conf: introduce launch-security element in domain

2018-06-06 Thread Brijesh Singh
The launch-security element can be used to define the security model to use when launching a domain. Currently we support 'sev'. When 'sev' is used, the VM will be launched with AMD SEV feature enabled. SEV feature supports running encrypted VM under the control of KVM. Encrypted VMs have their pa

[libvirt] [PATCH v8 10/11] remote: implement the remote protocol for launch security

2018-06-06 Thread Brijesh Singh
Add remote support for launch security info. Signed-off-by: Brijesh Singh Reviewed-by: Erik Skultety --- src/remote/remote_daemon_dispatch.c | 47 + src/remote/remote_driver.c | 40 +++ src/remote/remote_protocol.x

[libvirt] [PATCH v8 09/11] libvirt: add new public API to get launch security info

2018-06-06 Thread Brijesh Singh
The API can be used outside the libvirt to get the launch security information. When SEV is enabled, the API can be used to get the measurement of the launch process. Signed-off-by: Brijesh Singh --- include/libvirt/libvirt-domain.h | 17 ++ src/driver-hypervisor.h | 8

[libvirt] [PATCH v8 11/11] qemu: Add support to launch security info

2018-06-06 Thread Brijesh Singh
This patch implements the internal driver API for launch event into qemu driver. When SEV is enabled, execute 'query-sev-launch-measurement' to get the measurement of memory encrypted through launch sequence. Signed-off-by: Brijesh Singh --- src/qemu/qemu_driver.c | 69

Re: [libvirt] Mystery of qemu being unable to open NBD Unix domain socket in current directory

2018-06-06 Thread Eric Blake
On 06/06/2018 12:29 PM, Richard W.M. Jones wrote: I'm chasing down a very frustrating bug which only happens on i686 & Koji during the nbdkit tests and seemingly nowhere else. Anyway this is what I've been able to put together: The libguestfs appliance (guest) is created with this XML snippet:

Re: [libvirt] [PATCH] qemu: Introduce VIRTIO_NET_F_STANDBY feature bit to virtio_net

2018-06-06 Thread Samudrala, Sridhar
On 6/4/2018 7:06 PM, Jason Wang wrote: On 2018年06月05日 09:41, Samudrala, Sridhar wrote: Ping on this patch now that the kernel patches are accepted into davem's net-next tree. https://patchwork.ozlabs.org/cover/920005/ On 5/7/2018 4:09 PM, Sridhar Samudrala wrote: This feature bit can be use

Re: [libvirt] [PATCH] Don't use enums in TPM struct fields

2018-06-06 Thread Ján Tomko
On Wed, Jun 06, 2018 at 05:47:00PM +0100, Daniel P. Berrangé wrote: When using an enum in a struct field, or anywhere else the compiler is free to decide to make it an unsigned type if it desires. This in turn leads to bugs when code does if ((def->foo = virDomainFooTypeFromString(str)) <

Re: [libvirt] Mystery of qemu being unable to open NBD Unix domain socket in current directory

2018-06-06 Thread Richard W.M. Jones
On Wed, Jun 06, 2018 at 01:25:27PM -0500, Eric Blake wrote: > On 06/06/2018 12:29 PM, Richard W.M. Jones wrote: > >I'm chasing down a very frustrating bug which only happens on i686 & > >Koji during the nbdkit tests and seemingly nowhere else. Anyway this > >is what I've been able to put together:

Re: [libvirt] [PATCH] qemu: Introduce VIRTIO_NET_F_STANDBY feature bit to virtio_net

2018-06-06 Thread Ján Tomko
On Wed, Jun 06, 2018 at 11:17:36AM -0700, Samudrala, Sridhar wrote: On 6/4/2018 7:06 PM, Jason Wang wrote: On 2018年06月05日 09:41, Samudrala, Sridhar wrote: Ping on this patch now that the kernel patches are accepted into davem's net-next tree. https://patchwork.ozlabs.org/cover/920005/ On 5/

Re: [libvirt] [PATCH] qemu: Introduce VIRTIO_NET_F_STANDBY feature bit to virtio_net

2018-06-06 Thread Michael S. Tsirkin
On Wed, Jun 06, 2018 at 11:17:36AM -0700, Samudrala, Sridhar wrote: > On 6/4/2018 7:06 PM, Jason Wang wrote: > > > > > > On 2018年06月05日 09:41, Samudrala, Sridhar wrote: > > > Ping on this patch now that the kernel patches are accepted into > > > davem's net-next tree. > > > https://patchwork.ozla

Re: [libvirt] [PATCH] qemu: Introduce VIRTIO_NET_F_STANDBY feature bit to virtio_net

2018-06-06 Thread Samudrala, Sridhar
On 6/6/2018 11:52 AM, Ján Tomko wrote: On Wed, Jun 06, 2018 at 11:17:36AM -0700, Samudrala, Sridhar wrote: On 6/4/2018 7:06 PM, Jason Wang wrote: On 2018年06月05日 09:41, Samudrala, Sridhar wrote: Ping on this patch now that the kernel patches are accepted into davem's net-next tree. https://

[libvirt] [PATCH 0/2] Fix a couple of virtio-scsi iothread issues

2018-06-06 Thread John Ferlan
See the patches for details John Ferlan (2): qemu: Fix error for attach controller config for live guest qemu: Allow no address to be defined for virtio-scsi iothrad attach src/qemu/qemu_domain.c | 7 --- src/qemu/qemu_driver.c | 5 +++-- 2 files changed, 7 insertions(+), 5 deletions(-)

[libvirt] [PATCH 1/2] qemu: Fix error for attach controller config for live guest

2018-06-06 Thread John Ferlan
Fix the error message to indicate what exactly is failing - that the controller index provided matches an existing controller. Signed-off-by: John Ferlan --- src/qemu/qemu_driver.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_dri

[libvirt] [PATCH 2/2] qemu: Allow no address to be defined for virtio-scsi iothrad attach

2018-06-06 Thread John Ferlan
https://bugzilla.redhat.com/show_bug.cgi?id=1583623 When attaching a virtio-scsi with IOThreads for the config of a live domain, allow the to not be defined thus allowing post parse processing to fill in the address. Make the error a bit clearer that virtio-scsi IOThreads require virtio pci or c

[libvirt] [PATCH v2] As qemuMonitorJSONIOProcess() will unlock the qemu monitor, there is some extreme situation, eg qemu send message to monitor twice in a short time, where the local viriable 'msg'

2018-06-06 Thread Weilun Zhu
1. qemuMonitorSend() assign mon->msg to parameter 'msg', which is alse a local variable of its caller qemuMonitorJSONCommandWithFd(), cause eventloop to send message to monitor, then wait condition. 2. qemu send message to monitor for the first time immediately. 3. qemuMonitorIOProcess() is called,

[libvirt] [PATCH v1.1 2/2] news: add cmdDomblkinfo --all option

2018-06-06 Thread Chen Hanxiao
From: Chen Hanxiao Update news for cmdDomblkinfo --all option. Signed-off-by: Chen Hanxiao --- docs/news.xml | 8 1 file changed, 8 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index c45850f625..daee3aa6b7 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -123,6 +123,14 @

[libvirt] [PATCH v1.1 1/2] cmdDomblkinfo: introduce --all to show all block devices info

2018-06-06 Thread Chen Hanxiao
From: Chen Hanxiao This patch introduces --all to show all block devices info of guests like: virsh # domblkinfo w08 --all Target CapacityAllocation Physical --- hda42949672960 9878110208 9878110208 vda1073

[libvirt] [PATCH v1.1 0/2] cmdDomblkinfo: introduce --all to show all

2018-06-06 Thread Chen Hanxiao
This series introduce --all to cmdDomblkinfo to show all block devices info in one cmd. Likes a combination of domblklist and domblkinfo. v1.1: fix a self test Chen Hanxiao (2): cmdDomblkinfo: introduce --all to show all block devices info news: add cmdDomblkinfo --all option docs/news.x

Re: [libvirt] [RFC PATCH 0/7] Enable vfio-pci 'property' for mediated devices

2018-06-06 Thread Gerd Hoffmann
On Wed, Jun 06, 2018 at 02:49:24PM +0200, Erik Skultety wrote: > On Tue, Jun 05, 2018 at 11:52:03AM +0200, Gerd Hoffmann wrote: > > Hi, > > > > > > TL;DR: > > > > - we have a new attribute value for vfio-pci mediated devices called > > > > 'display' > > > > -> devices can now format this new

[libvirt] [PATCH] qemu_tpm: Drop needles include of cap-ng.h

2018-06-06 Thread Michal Privoznik
qemu_tpm.c is not calling any capng_* functions. Let's drop this include then. This also fixes a build failure without capng. Signed-off-by: Michal Privoznik --- Pushed under build breaker and trivial rules. src/qemu/qemu_tpm.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/qemu/qemu_t