Re: [PATCH] qemu_security: Set the label of monitor

2021-09-06 Thread Peng Liang
On 9/6/2021 10:52 PM, Michal Prívozník wrote: > On 9/6/21 4:33 PM, Peng Liang wrote: >> On 9/6/2021 9:21 PM, Michal Prívozník wrote: >>> On 9/6/21 2:36 PM, Peng Liang wrote: Signed-off-by: Peng Liang --- src/qemu/qemu_security.c | 6 ++ 1 file changed, 6 insertions(+)

Re: [libvirt PATCH 00/24] tests: use g_auto more (glib chronicles)

2021-09-06 Thread Laine Stump
On 9/4/21 4:43 PM, Ján Tomko wrote: Ján Tomko (24): tests: virnetdaemontest: split variable declarations conf: add cleanup func for virNetworkXMLOption conf: add cleanup func for virMacMap tests: use g_autoptr instead of virObjectUnref tests: qemu: use g_autofree tests:

Re: [libvirt PATCH 18/24] tests: qemu: remove pointless labels

2021-09-06 Thread Laine Stump
On 9/4/21 4:44 PM, Ján Tomko wrote: 6 files changed, 51 insertions(+), 105 deletions(-) diff --git a/tests/qemuagenttest.c b/tests/qemuagenttest.c index 10d02bd1b4..bef6dfd152 100644 --- a/tests/qemuagenttest.c +++ b/tests/qemuagenttest.c @@ -471,51 +471,39 @@

Re: [libvirt PATCH 19/24] tests: vmx: remove pointless labels

2021-09-06 Thread Laine Stump
On 9/4/21 4:44 PM, Ján Tomko wrote: Signed-off-by: Ján Tomko --- tests/vmx2xmltest.c | 19 +++ tests/xml2vmxtest.c | 15 +-- 2 files changed, 12 insertions(+), 22 deletions(-) diff --git a/tests/vmx2xmltest.c b/tests/vmx2xmltest.c index b7f232eb77..0974168cb4

Re: [libvirt PATCH 20/24] tests: libxl: remove pointless labels

2021-09-06 Thread Laine Stump
On 9/4/21 4:44 PM, Ján Tomko wrote: diff --git a/tests/xmconfigtest.c b/tests/xmconfigtest.c index bd23e5fd5d..c99d1f2bd9 100644 --- a/tests/xmconfigtest.c +++ b/tests/xmconfigtest.c @@ -41,7 +41,6 @@ testCompareParseXML(const char *xmcfg, const char *xml) { g_autofree char

Re: [libvirt PATCH 22/24] tests: vshtabletest: remove pointless labels

2021-09-06 Thread Laine Stump
On 9/4/21 4:44 PM, Ján Tomko wrote: Signed-off-by: Ján Tomko --- tests/vshtabletest.c | 71 +--- 1 file changed, 28 insertions(+), 43 deletions(-) diff --git a/tests/vshtabletest.c b/tests/vshtabletest.c index 569d7a852f..716b11dbc0 100644 ---

Re: [libvirt PATCH 23/24] tests: vir: remove pointless labels

2021-09-06 Thread Laine Stump
On 9/4/21 4:44 PM, Ján Tomko wrote: @@ -319,9 +308,9 @@ testFileIsSharedFSType(const void *opaque G_GNUC_UNUSED) return EXIT_AM_SKIP; #else const struct testFileIsSharedFSType *data = opaque; +int ret = -1; g_autofree char *mtabFile = NULL; bool actual; -int

Re: [libvirt PATCH 0/6] tests: refactor some functions (glib chronicles)

2021-09-06 Thread Pavel Hrdina
On Sat, Sep 04, 2021 at 09:34:46PM +0200, Ján Tomko wrote: > Ján Tomko (6): > tests: esxutils: refactor testParseDatastorePath > tests: esxutils: reduce variable scope in testEscapeDatastoreItem > tests: esxutils: reduce variable scope in testConvertWindows1252ToUTF8 > tests: reduce

Re: [libvirt PATCH] secretxml2xmltest: refactor testCompareXMLToXMLFiles (glib chronicles)

2021-09-06 Thread Michal Prívozník
On 9/4/21 9:42 PM, Ján Tomko wrote: > Use g_auto where possible and remove the pointless label. > > Signed-off-by: Ján Tomko > --- > tests/secretxml2xmltest.c | 18 ++ > 1 file changed, 6 insertions(+), 12 deletions(-) > Reviewed-by: Michal Privoznik Michal

Re: [libvirt PATCH 0/4] Reinstate -Wunused-but-set-variable

2021-09-06 Thread Michal Prívozník
On 9/4/21 9:25 PM, Ján Tomko wrote: > Personally, I feel like all the cases caught by new Clang's > -Wunused-but-set-variable > behavior were also unnecessarily difficult to read for humans, we should be > more obvious > when relying purely on side effects of g_auto and the warning is worth >

Re: [libvirt PATCH 0/2] tests: bhyve: minor style tweaks for constants

2021-09-06 Thread Pavel Hrdina
On Sat, Sep 04, 2021 at 09:27:41PM +0200, Ján Tomko wrote: > I found these lying around in a forgotten branch. > > Ján Tomko (2): > tests: bhyve: remove magic constants > tests: bhyve: use bitwise shift when defining flags Reviewed-by: Pavel Hrdina signature.asc Description: PGP signature

[libvirt PATCH 5/6] libxl: use g_auto in libxlCapsNodeData

2021-09-06 Thread Ján Tomko
Also remove pointless labels. Signed-off-by: Ján Tomko --- src/libxl/libxl_capabilities.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c index 38a9b36d8b..ef77bec7a0 100644 ---

[libvirt PATCH 6/6] libxl: use g_auto in libxlDomainGetEmulatorType

2021-09-06 Thread Ján Tomko
Signed-off-by: Ján Tomko --- src/libxl/libxl_capabilities.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c index ef77bec7a0..a516910215 100644 --- a/src/libxl/libxl_capabilities.c +++

[libvirt PATCH 2/6] libxl: remove enum libxlHwcapVersion

2021-09-06 Thread Ján Tomko
As well as the code probing for the version in libxlCapsInitHost. Signed-off-by: Ján Tomko --- src/libxl/libxl_capabilities.c | 24 1 file changed, 4 insertions(+), 20 deletions(-) diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c index

[libvirt PATCH 3/6] libxl: capsInitCPU: fail if we can't initialize host features

2021-09-06 Thread Ján Tomko
Introduced by: commit 17322e551861a5bc4dd464a7c5399204dc8c7caa libxl: describe host cpu features based on hwcaps with the justification that libxl_hwcaps does not have a stable format across all version. Even though the code would return '0' in the case of such failure, it frees the 'cpu'

[libvirt PATCH 4/6] libxl: refactor libxlCapsInitCPU

2021-09-06 Thread Ján Tomko
Use g_auto, g_steal_pointer and remove unnecessary labels. Signed-off-by: Ján Tomko --- src/libxl/libxl_capabilities.c | 22 ++ 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c index

[libvirt PATCH 0/6] libxl: remove enum libxlHwcapVersion

2021-09-06 Thread Ján Tomko
While looking at users of virCPU.*Free, I found some code that is supposed to deal with Xen < 4.7. The minimum version is 4.9 since the following commit: commit 68940b3fb3c43b8aa03cb6fd2f1d00b1737c9b2c Author: Jim Fehlig CommitDate: 2021-06-17 10:11:56 -0600 Xen: Bump minimum supported

[libvirt PATCH 1/6] libxl: capabilities: assume Xen version >= 4.7

2021-09-06 Thread Ján Tomko
Remove the code handling old Xen's hwcap words, as well as the comment describing it. Signed-off-by: Ján Tomko --- src/libxl/libxl_capabilities.c | 54 +- 1 file changed, 20 insertions(+), 34 deletions(-) diff --git a/src/libxl/libxl_capabilities.c

Re: [PATCH] qemu_security: Set the label of monitor

2021-09-06 Thread Michal Prívozník
On 9/6/21 4:33 PM, Peng Liang wrote: > On 9/6/2021 9:21 PM, Michal Prívozník wrote: >> On 9/6/21 2:36 PM, Peng Liang wrote: >>> Signed-off-by: Peng Liang >>> --- >>> src/qemu/qemu_security.c | 6 ++ >>> 1 file changed, 6 insertions(+) >>> >>> diff --git a/src/qemu/qemu_security.c

Re: [PATCH] qemu_security: Set the label of monitor

2021-09-06 Thread Peng Liang
On 9/6/2021 9:21 PM, Michal Prívozník wrote: > On 9/6/21 2:36 PM, Peng Liang wrote: >> Signed-off-by: Peng Liang >> --- >> src/qemu/qemu_security.c | 6 ++ >> 1 file changed, 6 insertions(+) >> >> diff --git a/src/qemu/qemu_security.c b/src/qemu/qemu_security.c >> index

Re: [PATCH] qemu_driver: Don't check for g_strdup_printf() retval

2021-09-06 Thread Martin Kletzander
On Mon, Sep 06, 2021 at 03:59:04PM +0200, Martin Kletzander wrote: On Mon, Sep 06, 2021 at 03:12:59PM +0200, Michal Privoznik wrote: The g_strdup_printf() function can't fail really. There's no need to check for its return value. Signed-off-by: Michal Privoznik For the concept:

[PATCH 3/3] qemu: Add support for virtio device option paeg-per-vq

2021-09-06 Thread Han Han
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1925363 Signed-off-by: Han Han --- src/qemu/qemu_command.c | 4 ++ src/qemu/qemu_hotplug.c | 3 +- src/qemu/qemu_validate.c | 8

[PATCH 2/3] conf: Add page_per_vq for driver element

2021-09-06 Thread Han Han
Signed-off-by: Han Han --- docs/formatdomain.rst | 9 + docs/schemas/domaincommon.rng | 5 + src/conf/domain_conf.c| 16 src/conf/domain_conf.h| 1 + src/conf/domain_validate.c| 7 +++ 5 files changed, 38 insertions(+) diff --git

[PATCH 0/3] Implement paeg-per-vq to virtio devices

2021-09-06 Thread Han Han
The the paeg-per-vq option controlles the VQ Notification Virtio Capability, added since QEMU 2.8(commit d9997d89a4). It could bring some flexibility[1][2] to vhost_vdpa. Gavi, I am not very clear about how it can help with vhost_vdpa. So I paste some description from the doc of your previous

[PATCH 1/3] qemu_capabilities: Add flag QEMU_CAPS_VIRTIO_PAGE_PER_VQ

2021-09-06 Thread Han Han
The qemu capability will be used for the page_per_vq option of virtio devices. Signed-off-by: Han Han --- src/qemu/qemu_capabilities.c | 6 ++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_2.11.0.s390x.xml | 1 +

Re: [PATCH] qemu_driver: Don't check for g_strdup_printf() retval

2021-09-06 Thread Martin Kletzander
On Mon, Sep 06, 2021 at 03:12:59PM +0200, Michal Privoznik wrote: The g_strdup_printf() function can't fail really. There's no need to check for its return value. Signed-off-by: Michal Privoznik For the concept: Reviewed-by: Martin Kletzander but it needs to be properly rebased as it does

Re: [PATCH] qemu_security: Set the label of monitor

2021-09-06 Thread Michal Prívozník
On 9/6/21 2:36 PM, Peng Liang wrote: > Signed-off-by: Peng Liang > --- > src/qemu/qemu_security.c | 6 ++ > 1 file changed, 6 insertions(+) > > diff --git a/src/qemu/qemu_security.c b/src/qemu/qemu_security.c > index 19d957dd4b96..96755a62bd2c 100644 > --- a/src/qemu/qemu_security.c > +++

[PATCH] qemu_driver: Don't check for g_strdup_printf() retval

2021-09-06 Thread Michal Privoznik
The g_strdup_printf() function can't fail really. There's no need to check for its return value. Signed-off-by: Michal Privoznik --- src/qemu/qemu_driver.c | 49 +- 1 file changed, 10 insertions(+), 39 deletions(-) diff --git a/src/qemu/qemu_driver.c

[PATCH] qemu_security: Set the label of monitor

2021-09-06 Thread Peng Liang
Signed-off-by: Peng Liang --- src/qemu/qemu_security.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/qemu/qemu_security.c b/src/qemu/qemu_security.c index 19d957dd4b96..96755a62bd2c 100644 --- a/src/qemu/qemu_security.c +++ b/src/qemu/qemu_security.c @@ -52,6 +52,12 @@

RE: [PATCH 1/1] qemu: add virtio-blk queue-size option

2021-09-06 Thread Hiroki Narukawa
Thank you for your review. I resent patches after splitting into 3 commits and fixing conditions and error message. -Original Message- From: Peter Krempa Sent: Monday, September 6, 2021 3:25 PM To: 成川 弘樹 Cc: libvir-list@redhat.com; 大岩 朗 Subject: Re: [PATCH 1/1] qemu: add virtio-blk

[PATCH 1/3] qemu: accept queue_size XML element

2021-09-06 Thread Hiroki Narukawa
--- docs/schemas/domaincommon.rng | 5 + src/conf/domain_conf.c| 6 ++ src/conf/domain_conf.h| 1 + 3 files changed, 12 insertions(+) diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng index 11fa24f398..fdc04f90aa 100644 ---

[PATCH 0/3] Resend after following review: qemu: add virtio-blk queue-size option

2021-09-06 Thread Hiroki Narukawa
This is resubmit of "qemu: add virtio-blk queue-size option" after following the review. The option "queue-size" in virtio-blk was added in qemu-2.12.0, and default value increased from qemu-5.0.0. However, increasing this value may lead to drop of random access performance. This is configurable

[PATCH 2/3] qemu: add QEMU_CAPS_VIRTIO_BLK_QUEUE_SIZE capability

2021-09-06 Thread Hiroki Narukawa
--- src/qemu/qemu_capabilities.c | 2 ++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml | 1 + tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml | 1 + tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml | 1 +

[PATCH 3/3] qemu: add virtio-blk queue-size option

2021-09-06 Thread Hiroki Narukawa
--- src/qemu/qemu_command.c | 3 ++ src/qemu/qemu_validate.c | 6 .../disk-virtio-queue-size.args | 29 +++ .../disk-virtio-queue-size.xml| 35 +++ tests/qemuxml2argvtest.c

Re: [PATCH 2/2] qemu: support for virtio-blk-pci discard options

2021-09-06 Thread Peter Krempa
On Tue, Aug 31, 2021 at 20:50:04 +0800, yuxiating wrote: > DISCARD and WRITE_ZEROES features for machine type >= 4.0 is enabled by > default since > commit 5c81161f804144b146607f890e84613a4cbad95c > virtio-blk: add "discard" and "write-zeroes" properties > Sometimes guestos has bugs

Re: [PATCH 1/1] qemu: add virtio-blk queue-size option

2021-09-06 Thread Peter Krempa
On Tue, Aug 31, 2021 at 18:51:07 +0900, Hiroki Narukawa wrote: > The option "queue-size" in virtio-blk was added in qemu-2.12.0, and default > value increased from qemu-5.0.0. > However, increasing this value may lead to drop of random access performance. > This is configurable value, so we want