Re: [PATCH v4 0/2] introduction of migration_version attribute for VFIO live migration

2020-03-23 Thread Yan Zhao
On Tue, Mar 24, 2020 at 05:29:59AM +0800, Alex Williamson wrote: > On Mon, 3 Jun 2019 20:34:22 -0400 > Yan Zhao wrote: > > > On Tue, Jun 04, 2019 at 03:29:32AM +0800, Alex Williamson wrote: > > > On Thu, 30 May 2019 20:44:38 -0400 > > > Yan Zhao wrote: > > > > > > > This patchset introduces a

Re: Propose to extend the capability of arm cpu driver

2020-03-23 Thread Zhenyu Zheng
Hi Andrea, Thanks again for the reply, I've already re-implement the codes on the master branch last week and trying to get ready to post it in the mailing list. As for calling lscpu, it does show a very good textual information, I will have a try using that as the source. BR, Zhenyu On Mon, Ma

Re: [PATCH v1 3/4] qemu_domain.c: do not launch ppc64 guests with 'pmu' setting

2020-03-23 Thread David Gibson
On Mon, Mar 23, 2020 at 06:28:34PM +0100, Andrea Bolognani wrote: > On Thu, 2020-03-19 at 18:44 -0300, Daniel Henrique Barboza wrote: > > The Perfomance Monitoring Unit (PMU) feature is not available for > > the Power architecture. The "" feature will always have a value > > 'on' or 'off' after sav

Re: TCK regression from blockdev change

2020-03-23 Thread Jim Fehlig
On 3/10/20 1:21 AM, Peter Krempa wrote: On Mon, Mar 09, 2020 at 15:11:22 -0600, Jim Fehlig wrote: Hi all, I noticed libvirt-tck test 207-disk-media-change.t is failing with 6.1.0, although I _think_ the failure has actually been around since the change to using blockdev in the qemu driver. The

[libvirt-tck] scripts: fix disk media change test

2020-03-23 Thread Jim Fehlig
Since the introduction of the 'index' attribute of a disk's element, test 207-disk-media-change.t is failing. The test is a bit flawed in that it compares initial and final domXML after changing the media of a cdrom disk device. The test only needs to check the final domXML to ensure the correct

[PATCH] docs: fix typo in domcaps host-model CPU description

2020-03-23 Thread Jim Fehlig
The domain capabilities documentation contains a small but confusing error in the host-model CPU description, referencing the element instead of . Fix this small typo. Signed-off-by: Jim Fehlig --- I only found this small typo (well, I'm pretty sure it's a typo :-)) by tring to understand a mor

Re: [PATCH v4 0/2] introduction of migration_version attribute for VFIO live migration

2020-03-23 Thread Alex Williamson
On Mon, 3 Jun 2019 20:34:22 -0400 Yan Zhao wrote: > On Tue, Jun 04, 2019 at 03:29:32AM +0800, Alex Williamson wrote: > > On Thu, 30 May 2019 20:44:38 -0400 > > Yan Zhao wrote: > > > > > This patchset introduces a migration_version attribute under sysfs of VFIO > > > Mediated devices. > > > >

[PATCH v4 6/6] news.xml: document the new NVDIMM support for Pseries guests

2020-03-23 Thread Daniel Henrique Barboza
Signed-off-by: Daniel Henrique Barboza --- docs/news.xml | 11 +++ 1 file changed, 11 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index ae4ee444d0..9bdfc21dc4 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -44,6 +44,17 @@ + + + qemu: NVD

[PATCH v4 3/6] formatdomain.html.in: document the new 'uuid' NVDIMM element

2020-03-23 Thread Daniel Henrique Barboza
Signed-off-by: Daniel Henrique Barboza --- docs/formatdomain.html.in | 13 + 1 file changed, 13 insertions(+) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index 0d229386eb..e5e46a3f4e 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -889

[PATCH v4 2/6] conf: Introduce optional 'uuid' element for NVDIMM memory

2020-03-23 Thread Daniel Henrique Barboza
ppc64 NVDIMM support was implemented in QEMU by commit [1]. The support is similar to what x86 already does, aside from an extra 'uuid' element. This patch introduces a new optional 'uuid' element for the NVDIMM memory model. This element behaves like the 'uuid' element of the domain definition -

[PATCH v4 4/6] conf, qemu: enable NVDIMM support for ppc64

2020-03-23 Thread Daniel Henrique Barboza
Using the 'uuid' element for ppc64 NVDIMM memory added in the previous patch, use it in qemuBuildMemoryDeviceStr() to pass it over to QEMU. Another ppc64 restriction is the necessity of a mem->labelsize, given than ppc64 only support label-area backed NVDIMMs. Finally, we don't want ppc64 NVDIMMs

[PATCH v4 0/6] NVDIMM suport for pSeries guests

2020-03-23 Thread Daniel Henrique Barboza
changes in v4: - moved label size requirement from virDomainMemoryDefParseXML() to virDomainMemoryDefValidate() Previous version: https://www.redhat.com/archives/libvir-list/2020-March/msg00769.html Daniel Henrique Barboza (6): qemu: capabilities: update qemu-5.0.0 capabilities for ppc64 con

[PATCH v4 5/6] formatdomain.html.in: document NVDIMM 'label' requirement for pSeries

2020-03-23 Thread Daniel Henrique Barboza
Signed-off-by: Daniel Henrique Barboza --- docs/formatdomain.html.in | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index e5e46a3f4e..fb07d107f0 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.ht

Re: [PATCH v2 3/5] conf, qemu: enable NVDIMM support for ppc64

2020-03-23 Thread Daniel Henrique Barboza
On 3/23/20 3:46 PM, Michal Prívozník wrote: On 11. 3. 2020 22:29, Daniel Henrique Barboza wrote: Using the 'uuid' element for ppc64 NVDIMM memory added in the previous patch, use it in qemuBuildMemoryDeviceStr() to pass it over to QEMU. Another ppc64 restriction is the necessity of a mem->la

Re: [PATCH v2 3/5] conf, qemu: enable NVDIMM support for ppc64

2020-03-23 Thread Michal Prívozník
On 11. 3. 2020 22:29, Daniel Henrique Barboza wrote: > Using the 'uuid' element for ppc64 NVDIMM memory added in the > previous patch, use it in qemuBuildMemoryDeviceStr() to pass > it over to QEMU. > > Another ppc64 restriction is the necessity of a mem->labelsize, > given than ppc64 only support

Re: [PATCH v1 3/4] qemu_domain.c: do not launch ppc64 guests with 'pmu' setting

2020-03-23 Thread Daniel Henrique Barboza
On 3/23/20 2:28 PM, Andrea Bolognani wrote: On Thu, 2020-03-19 at 18:44 -0300, Daniel Henrique Barboza wrote: The Perfomance Monitoring Unit (PMU) feature is not available for the Power architecture. The "" feature will always have a value 'on' or 'off' after saving the domain XML, and both w

[PATCH 13/14] qemuBlockGetBackingStoreString: Properly handle 'http/s' with cookies and others

2020-03-23 Thread Peter Krempa
Format cookies into the backing store string without encryption as they will not be visible on the command line when formatting a 'target' only string. In cases when cookies or other options are used we must use the JSON format rather than pure URI. Add tests to validate the scenario. Signed-off-

[PATCH 11/14] qemuBlockGetBackingStoreString: Add extra wrapping object to JSON strings

2020-03-23 Thread Peter Krempa
QEMU requires an extra wrapper object where only the "file" member is populated. This is basically a placeholder for establishing the format layer. We did the same in qemuDiskSourceGetProps for the old-school JSON usage with -drive but forgot to adopt this for -blockdev. https://bugzilla.redhat.co

[PATCH 06/14] qemuBlockGetBackingStoreString: Add 'pretty' argument

2020-03-23 Thread Peter Krempa
Add support for pretty-printing of the JSON variant of the output for consumption in tests. All current callers pass 'false'. Signed-off-by: Peter Krempa --- src/qemu/qemu_block.c | 8 +--- src/qemu/qemu_block.h | 3 ++- src/qemu/qemu_driver.c | 4 ++-- 3 files changed, 9 insertions(+), 6

[PATCH 14/14] storage: Parse 'nvme' disk source properties from json:{} pseudo-uri

2020-03-23 Thread Peter Krempa
Our code allows snapshots of NVMe based disks which means we create overlay file with a 'json:{}' pseudo-uri refering to the NVME device. Our parser code doesn't handle them though. Add the parser and test it via the XML->json->XML round-trip and reference data. Signed-off-by: Peter Krempa --- s

[PATCH 12/14] qemu: block: Extract formatting of cookie string

2020-03-23 Thread Peter Krempa
Introduce qemuBlockStorageSourceGetCookieString which does the concatenation so that we can reuse it later. Signed-off-by: Peter Krempa --- src/qemu/qemu_block.c | 25 + src/qemu/qemu_block.h | 3 +++ src/qemu/qemu_domain.c | 13 + 3 files changed, 29 inser

[PATCH 07/14] testQemuDiskXMLToProps: Store all per-image data in one structure

2020-03-23 Thread Peter Krempa
We had two non-syncrhonized arrays holding the individual data. This was a lazy way to do it when I was adding new tests recently. Since it's hard to extend with new data to test refactor the storage of test data to use a new struct where all per-image data are kept and can be extended easily. Sig

[PATCH 08/14] qemublocktest: Test backing store strings

2020-03-23 Thread Peter Krempa
With -blockdev libvirt provides the string which is recorded as 'backing store' property of an image to qemu. Add testing for qemuBlockGetBackingStoreString which generates these strings as there's logic which determines which format to use. Signed-off-by: Peter Krempa --- tests/qemublocktest.c

[PATCH 01/14] conf: rename 'namespace' property of struct _virStorageSourceNVMeDef

2020-03-23 Thread Peter Krempa
While 'namespace' is not a reserved word in C, it is in C++. Our compilers are happy with it but syntax-hilighting in some editors hilights is as a keyword. Rename it to prevent confusion. Signed-off-by: Peter Krempa --- src/conf/domain_conf.c | 12 ++-- src/hypervisor/virhostdev.c

[PATCH 10/14] storage: Implement backing store support for "fat:" prefix

2020-03-23 Thread Peter Krempa
qemublocktest showed that we don't add the "fat:" prefix for directory storage when formatting the backing store string. While it's unlikely to be used it's simple enough to actually implement the support rather than trying to forbid it. Signed-off-by: Peter Krempa --- src/qemu/qemu_block.c

[PATCH 04/14] qemublocktest: xml->json: Refactor cleanup in test case functions

2020-03-23 Thread Peter Krempa
Use automatic variable clearing and remove the cleanup sections of testQemuDiskXMLToProps, testQemuDiskXMLToPropsValidateSchema and testQemuDiskXMLToPropsValidateFile. testQemuDiskXMLToPropsValidateFileSrcOnly already uses new helpers. Signed-off-by: Peter Krempa --- tests/qemublocktest.c | 76

[PATCH 00/14] qemu: Fix 'backing store' string generator for -blockdev

2020-03-23 Thread Peter Krempa
QEMU doesn't like the backing store string generated by libvirt with -blockdev. Luckily we are able to parse them back and with blockdev they would no longer be used by qemu directly. Fix the generator an da few issues noticed along. Peter Krempa (14): conf: rename 'namespace' property of struc

[PATCH 02/14] qemublocktest: xml->json: Add test for NVMe

2020-03-23 Thread Peter Krempa
Based on the configuration from the only qemuxml2argv test. Signed-off-by: Peter Krempa --- tests/qemublocktest.c | 2 ++ .../xml2json/nvme-raw-noopts-srconly.json | 5 + .../xml2json/nvme-raw-noopts.json | 14 ++ .../qemub

[PATCH 09/14] qemuBlockGetBackingStoreString: Remove 'ret' variable

2020-03-23 Thread Peter Krempa
We can return the appropriate string directly. Signed-off-by: Peter Krempa --- src/qemu/qemu_block.c | 16 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/src/qemu/qemu_block.c b/src/qemu/qemu_block.c index d6cc999a43..b7c3ba7530 100644 --- a/src/qemu/qemu_block.c

[PATCH 05/14] testQemuDiskXMLToPropsValidateFileSrcOnly: Move together with rest of xml->json code

2020-03-23 Thread Peter Krempa
The function was misplaced. Group it together with other helper functions for testing disk XML to qemu JSON props conversion. Signed-off-by: Peter Krempa --- tests/qemublocktest.c | 61 ++- 1 file changed, 31 insertions(+), 30 deletions(-) diff --git a/te

[PATCH 03/14] virDomainDiskSourceNVMeFormat: Format only valid 'managed' values

2020-03-23 Thread Peter Krempa
VIR_TRISTATE_BOOL_ABSENT which maps to the 'default' string would not be parsed back, so we shouldn't format it either. Signed-off-by: Peter Krempa --- src/conf/domain_conf.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c

Re: [PATCH RESEND 2/5] qemuProcessStartManagedPRDaemon: Don't pass -f pidfile to the daemon

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 17:36, Marc-André Lureau wrote: > Hi > > On Mon, Mar 23, 2020 at 5:16 PM Michal Privoznik wrote: >> >> Now, that our virCommandSetPidFile() is more intelligent we don't >> need to rely on the daemon to create and lock the pidfile and use >> virCommandSetPidFile() at the same time.

Re: [PATCH v1 1/4] qemu_domain.c: do not launch ppc64 guests with APIC-EOI setting

2020-03-23 Thread Andrea Bolognani
On Mon, 2020-03-23 at 14:21 -0300, Daniel Henrique Barboza wrote: > On 3/23/20 2:01 PM, Andrea Bolognani wrote: > > This is > > > >https://bugzilla.redhat.com/show_bug.cgi?id=1236440 > > > > Please include the Bugzilla URL for other patches in the series > > as well, if applicable. > > Sure.

Re: [PATCH v1 4/4] qemu_domain.c: do not launch ppc64 guests with Hyperv settings

2020-03-23 Thread Andrea Bolognani
On Thu, 2020-03-19 at 18:44 -0300, Daniel Henrique Barboza wrote: [...] > +case VIR_DOMAIN_FEATURE_HYPERV: > +if (def->features[i] != VIR_TRISTATE_SWITCH_ABSENT && > +ARCH_IS_PPC64(def->os.arch)) { > +virReportError(VIR_ERR_CONFIG_UNSUPPORTED, > +

Re: [PATCH v1 3/4] qemu_domain.c: do not launch ppc64 guests with 'pmu' setting

2020-03-23 Thread Andrea Bolognani
On Thu, 2020-03-19 at 18:44 -0300, Daniel Henrique Barboza wrote: > The Perfomance Monitoring Unit (PMU) feature is not available for > the Power architecture. The "" feature will always have a value > 'on' or 'off' after saving the domain XML, and both will be rejected > by QEMU when launching. Th

Re: [PATCH v1 1/4] qemu_domain.c: do not launch ppc64 guests with APIC-EOI setting

2020-03-23 Thread Daniel Henrique Barboza
On 3/23/20 2:01 PM, Andrea Bolognani wrote: On Thu, 2020-03-19 at 18:44 -0300, Daniel Henrique Barboza wrote: qemu_domain.c: do not launch ppc64 guests with APIC-EOI setting s/qemu_domain.c/qemu/ Same for the other patches in the series. The "" feature, although it's not available for ps

Re: [libvirt PATCH 4/4] qemu: virtiofs: use a .log.fs suffix for logs

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 06:18:27PM +0100, Ján Tomko wrote: > On a Monday in 2020, Daniel P. Berrangé wrote: > > On Mon, Mar 23, 2020 at 05:10:37PM +0100, Ján Tomko wrote: > > > As Dave pointed out, someone creative might name a domain > > > to make its logfile conflict with a logfile of another > >

Re: [libvirt PATCH 4/4] qemu: virtiofs: use a .log.fs suffix for logs

2020-03-23 Thread Ján Tomko
On a Monday in 2020, Daniel P. Berrangé wrote: On Mon, Mar 23, 2020 at 05:10:37PM +0100, Ján Tomko wrote: As Dave pointed out, someone creative might name a domain to make its logfile conflict with a logfile of another domain's virtiofsd log. Signed-off-by: Ján Tomko Reported-by: Dr. David Ala

Re: [libvirt PATCH 1/4] qemu: virtiofs: kill the whole process group when stopping

2020-03-23 Thread Ján Tomko
On a Monday in 2020, Michal Prívozník wrote: On 23. 3. 2020 17:10, Ján Tomko wrote: After startup, virtiofds forks itself to drop its privileges. Kill the whole process group instead of just the parent. https://bugzilla.redhat.com/show_bug.cgi?id=1808697 Signed-off-by: Ján Tomko Reported-by:

Re: [libvirt PATCH 4/4] qemu: virtiofs: use a .log.fs suffix for logs

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 05:10:37PM +0100, Ján Tomko wrote: > As Dave pointed out, someone creative might name a domain > to make its logfile conflict with a logfile of another > domain's virtiofsd log. > > Signed-off-by: Ján Tomko > Reported-by: Dr. David Alan Gilbert > --- > src/qemu/qemu_virt

Re: [PATCH v1 2/4] qemu_domain.c: do not launch ppc64 guests with 'pvspinlock' setting

2020-03-23 Thread Andrea Bolognani
On Thu, 2020-03-19 at 18:44 -0300, Daniel Henrique Barboza wrote: [...] > +case VIR_DOMAIN_FEATURE_PVSPINLOCK: > +if (def->features[i] != VIR_TRISTATE_SWITCH_ABSENT && > +ARCH_IS_PPC64(def->os.arch)) { > +virReportError(VIR_ERR_CONFIG_UNSUPPORTED,

Re: [PATCH v1 1/4] qemu_domain.c: do not launch ppc64 guests with APIC-EOI setting

2020-03-23 Thread Andrea Bolognani
On Thu, 2020-03-19 at 18:44 -0300, Daniel Henrique Barboza wrote: > qemu_domain.c: do not launch ppc64 guests with APIC-EOI setting s/qemu_domain.c/qemu/ Same for the other patches in the series. > The "" feature, although it's not available for pseries, > can be declared in the domain XML of pp

Re: [libvirt PATCH 4/4] qemu: virtiofs: use a .log.fs suffix for logs

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 17:56, Ján Tomko wrote: > On a Monday in 2020, Michal Prívozník wrote: >> On 23. 3. 2020 17:10, Ján Tomko wrote: >>> As Dave pointed out, someone creative might name a domain >>> to make its logfile conflict with a logfile of another >>> domain's virtiofsd log. >>> >>> Signed-off-by:

Re: [libvirt PATCH 4/4] qemu: virtiofs: use a .log.fs suffix for logs

2020-03-23 Thread Ján Tomko
On a Monday in 2020, Michal Prívozník wrote: On 23. 3. 2020 17:10, Ján Tomko wrote: As Dave pointed out, someone creative might name a domain to make its logfile conflict with a logfile of another domain's virtiofsd log. Signed-off-by: Ján Tomko Reported-by: Dr. David Alan Gilbert --- src/qe

Re: [PATCH RESEND 1/5] virCommand: Actually acquire pidfile instead of just writing it

2020-03-23 Thread Marc-André Lureau
Hi On Mon, Mar 23, 2020 at 5:14 PM Michal Privoznik wrote: > > Our virCommand module allows us to set a pidfile for commands we > want to spawn. The caller constructs the string of pidfile path > and then uses virCommandSetPidFile() to tell the module to write > the pidfile once the command is r

Re: [PATCH RESEND 5/5] bridge_driver: Replace and drop networkKillDaemon

2020-03-23 Thread Marc-André Lureau
Hi On Mon, Mar 23, 2020 at 5:14 PM Michal Privoznik wrote: > > In the network driver code there's networkKillDaemon() which is > the same as virProcessKillPainfully(). Replace the former with > the later and drop what becomes unused function. > > Signed-off-by: Michal Privoznik > --- > src/netw

Re: [libvirt PATCH 4/4] qemu: virtiofs: use a .log.fs suffix for logs

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 17:10, Ján Tomko wrote: > As Dave pointed out, someone creative might name a domain > to make its logfile conflict with a logfile of another > domain's virtiofsd log. > > Signed-off-by: Ján Tomko > Reported-by: Dr. David Alan Gilbert > --- > src/qemu/qemu_virtiofs.c | 4 ++-- > 1

Re: [libvirt PATCH 1/4] qemu: virtiofs: kill the whole process group when stopping

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 17:10, Ján Tomko wrote: > After startup, virtiofds forks itself to drop its privileges. > Kill the whole process group instead of just the parent. > > https://bugzilla.redhat.com/show_bug.cgi?id=1808697 > > Signed-off-by: Ján Tomko > Reported-by: Andrew Jones > --- > src/qemu/qe

Re: [PATCH RESEND 3/5] qemuSlirpStop: Simplify helper kill

2020-03-23 Thread Marc-André Lureau
On Mon, Mar 23, 2020 at 5:14 PM Michal Privoznik wrote: > > Now, that we know that the slirp helper will have the pidfile > open and locked we can use virPidFileForceCleanupPath() to kill > it and unlink the pidfile. > > Signed-off-by: Michal Privoznik Reviewed-by: Marc-André Lureau > --- >

Re: [PATCH RESEND 4/5] qemuVirtioFSStop: Simplify daemon kill

2020-03-23 Thread Marc-André Lureau
On Mon, Mar 23, 2020 at 5:14 PM Michal Privoznik wrote: > > Now, that we know that the virtiofsd will have the pidfile open > and locked we can use virPidFileForceCleanupPath() to kill it and > unlink the pidfile. > > Signed-off-by: Michal Privoznik Reviewed-by: Marc-André Lureau > --- > src

Re: [PATCH RESEND 2/5] qemuProcessStartManagedPRDaemon: Don't pass -f pidfile to the daemon

2020-03-23 Thread Marc-André Lureau
Hi On Mon, Mar 23, 2020 at 5:16 PM Michal Privoznik wrote: > > Now, that our virCommandSetPidFile() is more intelligent we don't > need to rely on the daemon to create and lock the pidfile and use > virCommandSetPidFile() at the same time. > > Signed-off-by: Michal Privoznik Nice, but doesn't t

[PATCH RESEND 0/5] virCommand: fix approach to pidfiles

2020-03-23 Thread Michal Privoznik
The original series doesn't apply cleanly anymore: https://www.redhat.com/archives/libvir-list/2020-March/msg00499.html Here's the rebased one. Michal Prívozník (5): virCommand: Actually acquire pidfile instead of just writing it qemuProcessStartManagedPRDaemon: Don't pass -f pidfile to the

[PATCH RESEND 2/5] qemuProcessStartManagedPRDaemon: Don't pass -f pidfile to the daemon

2020-03-23 Thread Michal Privoznik
Now, that our virCommandSetPidFile() is more intelligent we don't need to rely on the daemon to create and lock the pidfile and use virCommandSetPidFile() at the same time. Signed-off-by: Michal Privoznik --- src/qemu/qemu_process.c | 9 - 1 file changed, 9 deletions(-) diff --git a/src

[PATCH RESEND 4/5] qemuVirtioFSStop: Simplify daemon kill

2020-03-23 Thread Michal Privoznik
Now, that we know that the virtiofsd will have the pidfile open and locked we can use virPidFileForceCleanupPath() to kill it and unlink the pidfile. Signed-off-by: Michal Privoznik --- src/qemu/qemu_virtiofs.c | 21 +++-- 1 file changed, 7 insertions(+), 14 deletions(-) diff --

[PATCH RESEND 3/5] qemuSlirpStop: Simplify helper kill

2020-03-23 Thread Michal Privoznik
Now, that we know that the slirp helper will have the pidfile open and locked we can use virPidFileForceCleanupPath() to kill it and unlink the pidfile. Signed-off-by: Michal Privoznik --- src/qemu/qemu_slirp.c | 16 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a

[PATCH RESEND 1/5] virCommand: Actually acquire pidfile instead of just writing it

2020-03-23 Thread Michal Privoznik
Our virCommand module allows us to set a pidfile for commands we want to spawn. The caller constructs the string of pidfile path and then uses virCommandSetPidFile() to tell the module to write the pidfile once the command is ran. This usually works, but has two flaws: 1) the child process does no

[PATCH RESEND 5/5] bridge_driver: Replace and drop networkKillDaemon

2020-03-23 Thread Michal Privoznik
In the network driver code there's networkKillDaemon() which is the same as virProcessKillPainfully(). Replace the former with the later and drop what becomes unused function. Signed-off-by: Michal Privoznik --- src/network/bridge_driver.c | 106 ++-- 1 file chang

[libvirt PATCH 0/4] qemu: virtiofs fixes

2020-03-23 Thread Ján Tomko
Shorten some paths and kill the whole process group instead of just the parent. Ján Tomko (4): qemu: virtiofs: kill the whole process group when stopping qemu: virtiofs: shorten pid filename qemu: virtiofs: shorten socket filename qemu: virtiofs: use a .log.fs suffix for logs src/qemu/qe

[libvirt PATCH 3/4] qemu: virtiofs: shorten socket filename

2020-03-23 Thread Ján Tomko
Use just 'fs' instead of 'virtiofsd'. Signed-off-by: Ján Tomko --- src/qemu/qemu_virtiofs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_virtiofs.c b/src/qemu/qemu_virtiofs.c index 2e3535873d..aaa25bcbb8 100644 --- a/src/qemu/qemu_virtiofs.c +++ b/src/qemu/qe

[libvirt PATCH 2/4] qemu: virtiofs: shorten pid filename

2020-03-23 Thread Ján Tomko
There is no need to repeat the shortName, since it's already present in the directory path. Also use just 'fs' instead of 'virtiofsd'. Signed-off-by: Ján Tomko Suggested-by: Andrea Bolognani --- src/qemu/qemu_virtiofs.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/s

[libvirt PATCH 1/4] qemu: virtiofs: kill the whole process group when stopping

2020-03-23 Thread Ján Tomko
After startup, virtiofds forks itself to drop its privileges. Kill the whole process group instead of just the parent. https://bugzilla.redhat.com/show_bug.cgi?id=1808697 Signed-off-by: Ján Tomko Reported-by: Andrew Jones --- src/qemu/qemu_virtiofs.c | 2 +- 1 file changed, 1 insertion(+), 1 d

[libvirt PATCH 4/4] qemu: virtiofs: use a .log.fs suffix for logs

2020-03-23 Thread Ján Tomko
As Dave pointed out, someone creative might name a domain to make its logfile conflict with a logfile of another domain's virtiofsd log. Signed-off-by: Ján Tomko Reported-by: Dr. David Alan Gilbert --- src/qemu/qemu_virtiofs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --gi

Re: [libvirt PATCH 1/5] gitlab: use CI for building website contents

2020-03-23 Thread Andrea Bolognani
On Mon, 2020-03-23 at 15:27 +, Daniel P. Berrangé wrote: > On Mon, Mar 23, 2020 at 03:35:03PM +0100, Andrea Bolognani wrote: > > Are we eventually going to have the same syntax-check / build / > > check split as we currently have in Jenkins? > > This isn't a desirable approach, because in gene

Re: Propose to extend the capability of arm cpu driver

2020-03-23 Thread Andrea Bolognani
On Fri, 2020-03-06 at 09:51 +0800, Zhenyu Zheng wrote: > > The problem is that on many ARM machines the file doesn't contain a > > whole lot of information, at least not in a form that's suitable for > > end users: for example, on this machine that I have access to, all > > it contains is > > pro

Re: [libvirt PATCH 1/5] gitlab: use CI for building website contents

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 03:35:03PM +0100, Andrea Bolognani wrote: > On Fri, 2020-03-20 at 17:27 +, Daniel P. Berrangé wrote: > > On Fri, Mar 20, 2020 at 06:07:47PM +0100, Andrea Bolognani wrote: > > > * why do we care about whether all those features are enabled or > > > not? It's pretty

Re: [PATCH] news: Document removal of support for .ini style of comments

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 04:10:11PM +0100, Michal Privoznik wrote: > In previous patches virKeyFile was replaced with its GLib > counterpart which created an incompatible change: comments can > now begin only with a number sign (#). While this won't probably > affect anyone, mention it in the releas

Re: [libvirt PATCH 4/5] gitlab: add several native CI jobs

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 04:00:17PM +0100, Andrea Bolognani wrote: > On Fri, 2020-03-20 at 17:44 +, Daniel P. Berrangé wrote: > > On Fri, Mar 20, 2020 at 06:13:13PM +0100, Andrea Bolognani wrote: > > > On Tue, 2020-03-10 at 10:09 +, Daniel P. Berrangé wrote: > > > > With GitLab CI aiming to

[PATCH] news: Document removal of support for .ini style of comments

2020-03-23 Thread Michal Privoznik
In previous patches virKeyFile was replaced with its GLib counterpart which created an incompatible change: comments can now begin only with a number sign (#). While this won't probably affect anyone, mention it in the release notes. Signed-off-by: Michal Privoznik --- docs/news.xml | 13 +++

Re: Virtualbox Support for 6.x ?

2020-03-23 Thread Martin Kletzander
On Mon, Mar 23, 2020 at 02:14:55PM +, Daniel P. Berrangé wrote: On Mon, Mar 23, 2020 at 02:46:46PM +0100, CDT CDT wrote: Hello all, TL;DR: Is there any libvirt update regarding VBox 6.x planned until July 2020? I tried using libvirt 4.x / virsh with Virtualbox 6.1.4, which seem to not wo

Re: [libvirt PATCH 4/5] gitlab: add several native CI jobs

2020-03-23 Thread Andrea Bolognani
On Fri, 2020-03-20 at 17:44 +, Daniel P. Berrangé wrote: > On Fri, Mar 20, 2020 at 06:13:13PM +0100, Andrea Bolognani wrote: > > On Tue, 2020-03-10 at 10:09 +, Daniel P. Berrangé wrote: > > > With GitLab CI aiming to replace Jenkins and Travis for CI purposes, we > > > need to expand the co

Re: [libvirt PATCH 0/4] cpu_map: Add more -noTSX x86 CPU models

2020-03-23 Thread Christian Ehrhardt
On Wed, Mar 18, 2020 at 11:13 AM Jiri Denemark wrote: > Christian Ehrhardt (1): > cpu_map: Add more -noTSX x86 CPU models > > Jiri Denemark (3): > cpu_map: Add element to x86 CPU model definitions > cpu_x86: Honor CPU models' element > cpu_map: Don't use new noTSX models for host-model

Re: [PATCH v2 2/2] util: remove virKeyFile

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 14:19, Rafael Fonseca wrote: > The functionality is now provided by glib's GKeyFile. > > Signed-off-by: Rafael Fonseca > --- > src/libvirt_private.syms | 10 -- > src/util/Makefile.inc.am | 2 - > src/util/virauthconfig.c | 1 - > src/util/virkeyfile.c| 354 --

[PATCH] qemu: softfail for TCG capabilities probe

2020-03-23 Thread Tobin Feldman-Fitzthum
As of version 2.10, QEMU can be built without the TCG. When libvirt determines that capabilities of a QEMU binary using QMP, it launches a QEMU process with KVM acceleration and TCG as a fallback. If QEMU supports KVM, a second probe is performed, forcing QEMU to use only TCG. This causes an err

Re: [libvirt PATCH 1/5] gitlab: use CI for building website contents

2020-03-23 Thread Andrea Bolognani
On Fri, 2020-03-20 at 17:27 +, Daniel P. Berrangé wrote: > On Fri, Mar 20, 2020 at 06:07:47PM +0100, Andrea Bolognani wrote: > > * why do we care about whether all those features are enabled or > > not? It's pretty ugly to have that list hardcoded in our build > > scripts, and I don't

Re: [PATCH] util: virhostcpu: Fail when fetching CPU Stats for invalid cpu

2020-03-23 Thread Christian Ehrhardt
On Fri, Feb 21, 2020 at 7:11 PM Mauro S. M. Rodrigues < maur...@linux.vnet.ibm.com> wrote: > virHostCPUGetStatsLinux walks through every cpu in /proc/stat until it > finds cpu%cpuNum that matches with the requested cpu. > If none is found it logs the error but it should return -1, instead of 0. >

Re: Virtualbox Support for 6.x ?

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 02:46:46PM +0100, CDT CDT wrote: > Hello all, > > > TL;DR: Is there any libvirt update regarding VBox 6.x planned until July > 2020? > > > I tried using libvirt 4.x / virsh with Virtualbox 6.1.4, which seem to not > work. The output of virsh -V tells me that hypervisor s

Virtualbox Support for 6.x ?

2020-03-23 Thread CDT CDT
Hello all, TL;DR: Is there any libvirt update regarding VBox 6.x planned until July 2020? I tried using libvirt 4.x / virsh with Virtualbox 6.1.4, which seem to not work. The output of virsh -V tells me that hypervisor should be able for that: Compiled with support for: Hypervisors: … Virtual

Re: [libvirt PATCH] api: disallow virDomainAgentSetResponseTimeout() on read-only connections

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 12:37, Daniel Henrique Barboza wrote: > > > On 3/20/20 11:43 AM, Jonathon Jongsma wrote: >> This function changes the amount of time that libvirt waits for a >> response from the guest agent for all guest agent commands. Since this >> is a configuration change, it should not be all

Re: [libvirt PATCH] qemu: fix response timeout for agent guest-sync

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 12:33, Daniel Henrique Barboza wrote: > > > On 3/20/20 7:28 PM, Jonathon Jongsma wrote: >> The agent 'guest-sync' command historically had a 5s response timeout >> which was different from other agent commands, which waited forever. >> When we added the ability to customize the res

Re: [PATCH v1] qemu: Use g_autofree and g_autoptr in qemuAgentSetUserPassword

2020-03-23 Thread Michal Prívozník
On 23. 3. 2020 12:26, Daniel Henrique Barboza wrote: > > > On 3/23/20 8:13 AM, Seeteena Thoufeek wrote: >> Signed-off-by: Seeteena Thoufeek >> --- > > > Reviewed-by: Daniel Henrique Barboza And now pushed. Congratulations on your first libvirt contribution! Michal

[PATCH v2 2/2] util: remove virKeyFile

2020-03-23 Thread Rafael Fonseca
The functionality is now provided by glib's GKeyFile. Signed-off-by: Rafael Fonseca --- src/libvirt_private.syms | 10 -- src/util/Makefile.inc.am | 2 - src/util/virauthconfig.c | 1 - src/util/virkeyfile.c| 354 --- src/util/virkeyfile.h| 58 --

[PATCH v2 1/2] util: authconfig: use g_key_file_*

2020-03-23 Thread Rafael Fonseca
Replace libvirt's virKeyFile by glib's GKeyFile. Signed-off-by: Rafael Fonseca --- src/util/virauthconfig.c | 25 +++-- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/src/util/virauthconfig.c b/src/util/virauthconfig.c index fd846ddd4b..473b4c76d6 100644 ---

Re: [PATCH] conf: use virStringParseYesNo

2020-03-23 Thread Michal Prívozník
On 22. 3. 2020 17:39, Rafael Fonseca wrote: > Use existing function built for this exact purpose. > > Signed-off-by: Rafael Fonseca > --- > src/conf/domain_conf.c| 25 ++--- > src/conf/interface_conf.c | 13 ++--- > 2 files changed, 16 insertions(+), 22 deletions(

Re: [PATCH] util: authconfig: use g_key_file_*

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 01:54:07PM +0100, Michal Prívozník wrote: > On 20. 3. 2020 18:06, Rafael Fonseca wrote: > > Replace libvirt's virKeyFile by glib's GKeyFile. > > > > Signed-off-by: Rafael Fonseca > > --- > > src/util/virauthconfig.c | 25 +++-- > > 1 file changed, 11 i

Re: [PATCH] util: authconfig: use g_key_file_*

2020-03-23 Thread Rafael Fonseca
On Mon, Mar 23, 2020 at 1:54 PM Michal Prívozník wrote: > > If I do, whole src/util/virkeyfile.c module and tests/virkeyfiletest.c > test can be removed too. Do you mind sending v2 where this would be the > first patch and in the second you remove the module, test and > correspodning symbols from

Re: [PATCH] util: authconfig: use g_key_file_*

2020-03-23 Thread Michal Prívozník
On 20. 3. 2020 18:06, Rafael Fonseca wrote: > Replace libvirt's virKeyFile by glib's GKeyFile. > > Signed-off-by: Rafael Fonseca > --- > src/util/virauthconfig.c | 25 +++-- > 1 file changed, 11 insertions(+), 14 deletions(-) > > diff --git a/src/util/virauthconfig.c b/src/u

Re: [libvirt PATCH 1/5] gitlab: use CI for building website contents

2020-03-23 Thread Erik Skultety
On Tue, Mar 10, 2020 at 10:09:41AM +, Daniel P. Berrangé wrote: > Run the bare minimum build that is possible to create the docs. Ideally > the '--without-remote' arg would be passed, but there are several bugs > preventing a build from succeeding without the remote driver built. > > The genera

Re: [libvirt PATCH 4/5] gitlab: add several native CI jobs

2020-03-23 Thread Erik Skultety
On Mon, Mar 23, 2020 at 12:01:49PM +, Daniel P. Berrangé wrote: > On Mon, Mar 23, 2020 at 12:50:45PM +0100, Erik Skultety wrote: > > On Fri, Mar 20, 2020 at 03:31:24PM +, Daniel P. Berrangé wrote: > > > On Fri, Mar 20, 2020 at 04:18:58PM +0100, Erik Skultety wrote: > > > > On Fri, Mar 20, 2

Re: [libvirt PATCH 4/5] gitlab: add several native CI jobs

2020-03-23 Thread Daniel P . Berrangé
On Mon, Mar 23, 2020 at 12:50:45PM +0100, Erik Skultety wrote: > On Fri, Mar 20, 2020 at 03:31:24PM +, Daniel P. Berrangé wrote: > > On Fri, Mar 20, 2020 at 04:18:58PM +0100, Erik Skultety wrote: > > > On Fri, Mar 20, 2020 at 02:59:36PM +, Daniel P. Berrangé wrote: > > > > On Fri, Mar 20, 2

Re: [libvirt PATCH 4/5] gitlab: add several native CI jobs

2020-03-23 Thread Erik Skultety
On Fri, Mar 20, 2020 at 03:31:24PM +, Daniel P. Berrangé wrote: > On Fri, Mar 20, 2020 at 04:18:58PM +0100, Erik Skultety wrote: > > On Fri, Mar 20, 2020 at 02:59:36PM +, Daniel P. Berrangé wrote: > > > On Fri, Mar 20, 2020 at 03:52:15PM +0100, Erik Skultety wrote: > > > > On Tue, Mar 10, 2

Re: [libvirt PATCH] qemu: ensure domain event thread is always stopped

2020-03-23 Thread Daniel Henrique Barboza
On 3/20/20 8:14 AM, Daniel P. Berrangé wrote: In previous commit: commit e6afacb0feabd9bf58331aa0e5259a35378be74e Author: Daniel P. Berrangé Date: Wed Feb 12 12:26:11 2020 + qemu: start/stop an event loop thread for domains A bogus comment was added claiming we didn't n

Re: [libvirt PATCH] api: disallow virDomainAgentSetResponseTimeout() on read-only connections

2020-03-23 Thread Daniel Henrique Barboza
On 3/20/20 11:43 AM, Jonathon Jongsma wrote: This function changes the amount of time that libvirt waits for a response from the guest agent for all guest agent commands. Since this is a configuration change, it should not be allowed on read-only connections. Signed-off-by: Jonathon Jongsma

Re: [libvirt PATCH] qemu: fix response timeout for agent guest-sync

2020-03-23 Thread Daniel Henrique Barboza
On 3/20/20 7:28 PM, Jonathon Jongsma wrote: The agent 'guest-sync' command historically had a 5s response timeout which was different from other agent commands, which waited forever. When we added the ability to customize the response timeout for guest agent commands, we intended to continue t

Re: [PATCH v1] qemu: Use g_autofree and g_autoptr in qemuAgentSetUserPassword

2020-03-23 Thread Daniel Henrique Barboza
On 3/23/20 8:13 AM, Seeteena Thoufeek wrote: Signed-off-by: Seeteena Thoufeek --- Reviewed-by: Daniel Henrique Barboza src/qemu/qemu_agent.c | 19 ++- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/src/qemu/qemu_agent.c b/src/qemu/qemu_agent.c index 9

[PATCH v1] qemu: Use g_autofree and g_autoptr in qemuAgentSetUserPassword

2020-03-23 Thread Seeteena Thoufeek
Signed-off-by: Seeteena Thoufeek --- src/qemu/qemu_agent.c | 19 ++- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/src/qemu/qemu_agent.c b/src/qemu/qemu_agent.c index 9ea2c59563..1583a4eee2 100644 --- a/src/qemu/qemu_agent.c +++ b/src/qemu/qemu_agent.c @@ -2274,10

Fwd: KVM hook

2020-03-23 Thread Aditya Sahu
Hi Team , I am reaching out to you seeking your help for one of my KVM hook script. I am using /etc/libvirt/hooks/network file to trigger an event when a network is created or deleted ( https://www.libvirt.org/hooks.html ). Basically I using a rest call to create the same network in my Infoblox ap

GSOC'20: Add support for Jailhouse hypervisor to libvirt.

2020-03-23 Thread PRAKHAR BANSAL
Hello All, My name is Prakhar Bansal and I am a graduate student in Computer Engineering at Iowa State University, US. I have experience with Analysing Performance of Applications running inside multiple virtual machines hosted by the libvirt QEMU-KVM through virt-manager. I am interested in work

[GSoC] Interested Student for the Project: 'Introducing job control to the storage driver'

2020-03-23 Thread Prathamesh Chavan
Hi Everyone, I'm Prathamesh Chavan, a final year student at studying Computer Science and Engineering at IIT Kharagpur. I've been part of GSoC'17 under the Git Organization and have an internship experience at Nutanix, India during last summer. I'm also currently working on a tired file system wit

Re: GSoC'20 Interested Student: Adding support to Jailhouse Hypervisor

2020-03-23 Thread Jan Kiszka
Hi Prakhar, On 23.03.20 07:53, PRAKHAR BANSAL wrote: Hello All, My name is Prakhar Bansal and I am a graduate student in Computer Engineering at Iowa State University, US. I have experience with Analysing Performance of Applications running inside multiple virtual machines hosted by the libvi