On 12/12/23 05:07, Peter Krempa wrote:
On Tue, Dec 12, 2023 at 12:50:52 +0100, Michal Privoznik wrote:
Virtiofsd has two implementations: C and Rust. The former is now
deprecated (QEMU commit v7.0.0-rc0~52^2~1) and in fact removed
from QEMU (QEMU commit v8.0.0-rc0~55). While Rust version was
On 12/14/23 8:50 AM, Dmitry Frolov wrote:
A lot of unreacheble code was caused by int functions, which return nothing
except zero. Unreacheble code was removed. Corresponding functions type was
changed to void.
Dmitry Frolov (14):
cpu: turn virCPUx86DataAddItem() to void
cpu: turn
On 12/14/23 8:51 AM, Dmitry Frolov wrote:
virNetClientAddProgram() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/admin/admin_remote.c| 3 +--
src/locking/lock_driver_lockd.c | 3 +--
src/logging/log_manager.c | 3 +--
src/lxc/lxc_monitor.c | 4 +---
On 12/14/23 8:51 AM, Dmitry Frolov wrote:
xenParseXLNamespaceData() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/libxl/xen_xl.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/src/libxl/xen_xl.c b/src/libxl/xen_xl.c
index 553aa77896..78a3e1d519 100644
---
On 12/14/23 8:51 AM, Dmitry Frolov wrote:
virDomainGraphicsListenAppendAddress() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/conf/domain_conf.c | 4 +---
src/conf/domain_conf.h | 2 +-
src/libxl/xen_common.c | 7 ++-
src/libxl/xen_xl.c | 3 +--
src/vbox/vbox_common.c |
On 12/14/23 19:32, Fima Shevrin wrote:
From: "Denis V. Lunev"
They are not exported from the module and thus should be static.
Signed-off-by: Denis V. Lunev
Signed-off-by: Fima Shevrin
---
src/util/vireventglibwatch.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git
On Thu, Dec 14, 2023 at 05:55:41PM +0100, Peter Krempa wrote:
> If you need any form of more complex logic in your application for error
> reporting (ab)using libvirt's thread local variable to store the error
I'm a bit lost on the "abuse" claim here. Is this abuse in your eyes:
```
int
The ability to use virObjectLockable allows to unlock an
object at the prepare stage inside the Main Event Loop.
Co-authored-by: Denis V. Lunev
Co-authored-by: Nikolai Barybin
Signed-off-by: Fima Shevrin
---
src/rpc/virnetclient.c | 6 +++---
src/util/vireventglib.c | 4 ++--
From: "Denis V. Lunev"
They are not exported from the module and thus should be static.
Signed-off-by: Denis V. Lunev
Signed-off-by: Fima Shevrin
---
src/util/vireventglibwatch.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/util/vireventglibwatch.c
RPC client implementation uses the following paradigm. The critical
section is organized via virObjectLock(client)/virObjectUnlock(client)
braces. Though this is potentially problematic as
main thread:side thread:
virObjectUnlock(client);
Probe the current URI so that other places don't need to do that.
Signed-off-by: Peter Krempa
---
tools/virt-admin.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tools/virt-admin.c b/tools/virt-admin.c
index 1e22a3c8a9..02cf421cee 100644
--- a/tools/virt-admin.c
+++
virsh already stores the connection URI in 'ctl->connname', use that
instead.
Signed-off-by: Peter Krempa
---
tools/virsh.c | 10 ++
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/tools/virsh.c b/tools/virsh.c
index 18a8c32f53..95ff63baeb 100644
--- a/tools/virsh.c
+++
Client application shouldn't need to reset the error.
Peter Krempa (4):
virshReconnect: Preserve current URI if not explicitly set in
ctl->connname
virshCatchDisconnect: Don't probe connection URI
vshAdmConnect: Preserve connection URI in ctl->connname if
auto-detected
Probe the current URI so that other places don't need to do that.
Signed-off-by: Peter Krempa
---
tools/virsh.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tools/virsh.c b/tools/virsh.c
index 7b71131db3..18a8c32f53 100644
--- a/tools/virsh.c
+++ b/tools/virsh.c
@@ -225,6 +225,9 @@
On Thu, Dec 14, 2023 at 12:03:55 +, John Levon wrote:
> On Thu, Dec 14, 2023 at 12:18:27PM +0100, Peter Krempa wrote:
>
> > While I have no problems with virErrorPreserveLast() as that's just
> > syntax sugar on top of existing public functions, I don't think that
> > it's a good idea to
On Thu, Dec 14, 2023 at 13:26:35 +0100, Ján Tomko wrote:
> On a Thursday in 2023, Peter Krempa wrote:
> > Allow users to easily resize 'raw' images on block devices to the full
> > capacity of the block device. Obviously this won't work on file-backed
> > storage (filling the remaining capacity is
libxlMakeDomainDeviceDiskCaps() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/libxl/libxl_capabilities.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c
index f419dd9d20..31b6fbc629 100644
---
virDomainGraphicsListenAppendAddress() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/conf/domain_conf.c | 4 +---
src/conf/domain_conf.h | 2 +-
src/libxl/xen_common.c | 7 ++-
src/libxl/xen_xl.c | 3 +--
src/vbox/vbox_common.c | 4 +---
src/vmx/vmx.c | 3 +--
6 files
virCapabilitiesAddHostFeature() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/conf/capabilities.c| 4 +---
src/conf/capabilities.h| 2 +-
src/libxl/libxl_capabilities.c | 5 ++---
src/test/test_driver.c | 6 ++
4 files changed, 6 insertions(+), 11
libxl_get_physinfo() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/libxl/libxl_capabilities.c | 6 +-
src/libxl/libxl_conf.c | 20 +---
src/libxl/libxl_driver.c | 6 +-
tests/libxlmock.c | 5 +
4 files changed, 8 insertions(+),
virCapabilitiesSetNetPrefix() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/conf/capabilities.c| 4 +---
src/conf/capabilities.h| 2 +-
src/libxl/libxl_capabilities.c | 3 +--
3 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/src/conf/capabilities.c
xenParseXLNamespaceData() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/libxl/xen_xl.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/src/libxl/xen_xl.c b/src/libxl/xen_xl.c
index 553aa77896..78a3e1d519 100644
--- a/src/libxl/xen_xl.c
+++ b/src/libxl/xen_xl.c
libxlMakeDomainDeviceVideoCaps() always returns 0.
Signed-off-by: Dmitry Frolov
---
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 b1e0985b7a..3a2b0fe2bd 100644
---
virCPUx86DataAdd() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/cpu/cpu_x86.c | 66 +-
src/cpu/cpu_x86.h | 2 +-
src/libxl/libxl_capabilities.c | 7 +---
3 files changed, 26 insertions(+), 49 deletions(-)
diff --git
virNetClientAddProgram() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/admin/admin_remote.c| 3 +--
src/locking/lock_driver_lockd.c | 3 +--
src/logging/log_manager.c | 3 +--
src/lxc/lxc_monitor.c | 4 +---
src/remote/remote_driver.c | 7 +++
libxlMakeDomainDeviceGraphicsCaps() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/libxl/libxl_capabilities.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c
index 31b6fbc629..b1e0985b7a 100644
libxlMakeDomainOSCaps() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/libxl/libxl_capabilities.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c
index 1a0ce25d56..f419dd9d20 100644
---
vboxDumpDisplay() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/vbox/vbox_common.c | 9 ++---
1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/src/vbox/vbox_common.c b/src/vbox/vbox_common.c
index 9f6612ad61..305c85f4ec 100644
--- a/src/vbox/vbox_common.c
+++
libxlCapsAddCPUID() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/libxl/libxl_capabilities.c | 7 ++-
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/src/libxl/libxl_capabilities.c b/src/libxl/libxl_capabilities.c
index 9da0fe851c..9be64a53a8 100644
---
virCPUx86DataAddItem() always returns 0.
Signed-off-by: Dmitry Frolov
---
src/cpu/cpu_x86.c | 27 +++
1 file changed, 11 insertions(+), 16 deletions(-)
diff --git a/src/cpu/cpu_x86.c b/src/cpu/cpu_x86.c
index 8d0e3947ce..f32770b8a3 100644
--- a/src/cpu/cpu_x86.c
+++
A lot of unreacheble code was caused by int functions, which return nothing
except zero. Unreacheble code was removed. Corresponding functions type was
changed to void.
Dmitry Frolov (14):
cpu: turn virCPUx86DataAddItem() to void
cpu: turn virCPUx86DataAdd() to void
libxl: turn
On a Thursday in 2023, Peter Krempa wrote:
This series implements two features:
- automatic size discovery when resizing a raw disk on a block device
- resizing of raw disks when a 'storage slice' is in use
Peter Krempa (10):
qemu: block: Introduce helpers for properly testing for 'raw' and
On a Thursday in 2023, Peter Krempa wrote:
Until now resizing a disk with a storage slice would break in one of the
following ways:
1) for a non-raw format, the virtual size would change, but the slice
would still remain in place
2) for raw disks qemu would refuse to change the size
The only
On Thu, Dec 14, 2023 at 13:14:43 +0100, Ján Tomko wrote:
> On a Thursday in 2023, Peter Krempa wrote:
> > Unfortunately a LUKS image to be decrypted by qemu has
> > VIR_STORAGE_FILE_RAW as format, but has encryption properties populated.
> >
> > Many places in the code don't check it properly and
On a Thursday in 2023, Peter Krempa wrote:
Allow users to easily resize 'raw' images on block devices to the full
capacity of the block device. Obviously this won't work on file-backed
storage (filling the remaining capacity is most likely wrong) or for
formats with metadata due to the overhead.
On 12/14/23 12:07, Ján Tomko wrote:
> On a Thursday in 2023, Michal Prívozník wrote:
>> On 12/13/23 15:47, Ján Tomko wrote:
>>> When this check was introduced, virtiofsd required root privileges.
>>>
>>> This has changed since then - now it does not need to set up all the
>>> sandboxing when
On a Thursday in 2023, Peter Krempa wrote:
Unfortunately a LUKS image to be decrypted by qemu has
VIR_STORAGE_FILE_RAW as format, but has encryption properties populated.
Many places in the code don't check it properly and also don't check
properly whether the image is indeed LUKS to be
On Thu, Dec 14, 2023 at 12:18:27PM +0100, Peter Krempa wrote:
> While I have no problems with virErrorPreserveLast() as that's just
> syntax sugar on top of existing public functions, I don't think that
> it's a good idea to expose virErrorRestore() as that gives the access to
> previously
On a Thursday in 2023, Michal Prívozník wrote:
On 12/12/23 13:07, Peter Krempa wrote:
On Tue, Dec 12, 2023 at 12:50:52 +0100, Michal Privoznik wrote:
Virtiofsd has two implementations: C and Rust. The former is now
deprecated (QEMU commit v7.0.0-rc0~52^2~1) and in fact removed
from QEMU (QEMU
On Thu, Dec 14, 2023 at 10:17:01 +0100, Michal Prívozník wrote:
> On 12/13/23 12:04, John Levon wrote:
> >
> > These two functions are currently private to libvirt, hence not available to
> > consumers. Would it be possible to make them public? Without them, there's
> > no
> > way to do any
On a Thursday in 2023, Michal Prívozník wrote:
On 12/13/23 15:47, Ján Tomko wrote:
When this check was introduced, virtiofsd required root privileges.
This has changed since then - now it does not need to set up all the
sandboxing when running as non-root. It even gained support for
id
Until now resizing a disk with a storage slice would break in one of the
following ways:
1) for a non-raw format, the virtual size would change, but the slice
would still remain in place
2) for raw disks qemu would refuse to change the size
The only reasonable scenario we want to support is a
The function will be used in the code for resizing block devices with a
slice.
Signed-off-by: Peter Krempa
---
src/conf/storage_source_conf.c | 2 +-
src/conf/storage_source_conf.h | 2 ++
src/libvirt_private.syms | 1 +
3 files changed, 4 insertions(+), 1 deletion(-)
diff --git
Prepare the blockdev props formatter to skip formatting the slice props
in case they are not applicable.
Signed-off-by: Peter Krempa
---
src/qemu/qemu_block.c | 19 ++-
.../disk-slices.x86_64-latest.args| 10 +-
2 files changed, 19
Rather than pulling the configuration of the storage slice into the
'format' layer make the 'slice' layer effective for raw disks with a
storage slice. This was made possible by the recent refactors which made
the 'format' layer optional if not needed.
Signed-off-by: Peter Krempa
---
Resizing of block-backed storage requires the user to pass the exact
capacity of the device. Implement code which will query it instead so
the user doesn't need to do that.
Closes: https://gitlab.com/libvirt/libvirt/-/issues/449
Signed-off-by: Peter Krempa
---
src/qemu/qemu_driver.c | 22
Allow users to easily resize 'raw' images on block devices to the full
capacity of the block device. Obviously this won't work on file-backed
storage (filling the remaining capacity is most likely wrong) or for
formats with metadata due to the overhead.
Signed-off-by: Peter Krempa
---
VSH_ALTERNATIVE_OPTIONS takes just the name of the options instead of
requiring also the getter functions.
Signed-off-by: Peter Krempa
---
tools/vsh.h | 4
1 file changed, 4 insertions(+)
diff --git a/tools/vsh.h b/tools/vsh.h
index 377c5947c1..2a1be29b1c 100644
--- a/tools/vsh.h
+++
Refactor code checking whether image is raw. This fixes multiple places
where a LUKS encrypted disk could be mistreated.
Signed-off-by: Peter Krempa
---
src/qemu/qemu_block.c | 32
src/qemu/qemu_command.c | 2 +-
src/qemu/qemu_driver.c | 4 ++--
3 files
Move the check for readonly and empty disks to the top where all other
checks will be done.
Signed-off-by: Peter Krempa
---
src/qemu/qemu_driver.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index
Unfortunately a LUKS image to be decrypted by qemu has
VIR_STORAGE_FILE_RAW as format, but has encryption properties populated.
Many places in the code don't check it properly and also don't check
properly whether the image is indeed LUKS to be decrypted by qemu.
Introduce helpes which will
This series implements two features:
- automatic size discovery when resizing a raw disk on a block device
- resizing of raw disks when a 'storage slice' is in use
Peter Krempa (10):
qemu: block: Introduce helpers for properly testing for 'raw' and
'luks' images
qemu: Use
On 12/13/23 12:04, John Levon wrote:
>
> These two functions are currently private to libvirt, hence not available to
> consumers. Would it be possible to make them public? Without them, there's no
> way to do any libvirt call without stomping on an existing error that you may
> want to preserve.
On 12/13/23 15:47, Ján Tomko wrote:
> Allow the user to manually tweak the ID mapping that will allow
> virtiofsd to run unprivileged.
>
> Signed-off-by: Ján Tomko
> ---
> docs/formatdomain.rst | 8 +++
> src/conf/domain_conf.c| 50
On 12/13/23 15:47, Ján Tomko wrote:
> When this check was introduced, virtiofsd required root privileges.
>
> This has changed since then - now it does not need to set up all the
> sandboxing when running as non-root. It even gained support for
> id mapping, which makes running unprivileged even
On 12/13/23 15:47, Ján Tomko wrote:
> Now with automatic id mapping selection.
>
> Ján Tomko (9):
> conf: move idmap definition earlier
> conf: move idmap parsing earlier
> conf: add idmap element to filesystem
> qemu: format uid/gid map for virtiofs
> qemu: virtiofs: do not force UID 0
On 12/12/23 13:07, Peter Krempa wrote:
> On Tue, Dec 12, 2023 at 12:50:52 +0100, Michal Privoznik wrote:
>> Virtiofsd has two implementations: C and Rust. The former is now
>> deprecated (QEMU commit v7.0.0-rc0~52^2~1) and in fact removed
>> from QEMU (QEMU commit v8.0.0-rc0~55). While Rust
New Alpine and Fedora releases were added to libvirt-ci (3.19 and
39, respectively) and old ones were removed. Update the manifest
file and regenerate the rest.
Signed-off-by: Michal Privoznik
---
ci/buildenv/{alpine-317.sh => alpine-319.sh} | 0
ci/buildenv/{fedora-37.sh => fedora-39.sh}
Green pipeline:
https://gitlab.com/MichalPrivoznik/libvirt/-/pipelines/1106643445
Michal Prívozník (2):
ci: integration: Switch upstream integration tests to Fedora 39
ci: Update Alpine and Fedora and regenerate
ci/buildenv/{alpine-317.sh => alpine-319.sh} | 0
ci/buildenv/{fedora-37.sh
Currently, Fedora 37 and 38 is used. The former is now EOL since
there's new release. Switch 37 to 39 then.
Signed-off-by: Michal Privoznik
---
ci/integration.yml | 80 +++---
1 file changed, 40 insertions(+), 40 deletions(-)
diff --git
60 matches
Mail list logo