On 13.07.23 08:41, zhenwei pi wrote:
enum ThrottleType is already there, use ThrottleType instead of
'bool is_write' for throttle API, also modify related codes from
block, fsdev, cryptodev and tests.
Signed-off-by: zhenwei pi
---
backends/cryptodev.c| 9 +
block/throttle-gr
On 13.07.23 08:41, zhenwei pi wrote:
Use enum ThrottleType instead in the throttle test codes.
Reviewed-by: Alberto Garcia
Signed-off-by: zhenwei pi
---
tests/unit/test-throttle.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
Reviewed-by: Hanna Czenczek
On 13.07.23 08:41, zhenwei pi wrote:
Reviewed-by: Alberto Garcia
Signed-off-by: zhenwei pi
---
tests/unit/test-throttle.c | 66 ++
1 file changed, 66 insertions(+)
Reviewed-by: Hanna Czenczek
ould be shorter as `timer = tt->timers[is_write ? THROTTLE_WRITE :
THROTTLE_READ];`.
Anyway, I only have style suggestion to offer, so either way:
Reviewed-by: Hanna Czenczek
+assert(timer);
+
must_wait = throttle_compute_timer(ts,
is_write,
now,
REALTIME, NULL,
cryptodev_backend_throttle_timer_cb, backend);
}
With the typo in the commit message fixed:
Reviewed-by: Hanna Czenczek
after patch 3. Still, optional, of course, so either way:
Reviewed-by: Hanna Czenczek
Of note is that we still have instances in util/throttle.c and
block/throttle-groups.c that don’t use these enums to access the
tt->timers[] array, and that’s a bit unfortunate now (i.e.
`tt->timers[is_
On 20.07.23 18:03, Stefan Hajnoczi wrote:
On Wed, Jul 19, 2023 at 04:27:58PM +0200, Hanna Czenczek wrote:
On 19.07.23 16:11, Hanna Czenczek wrote:
On 18.07.23 17:10, Stefan Hajnoczi wrote:
On Tue, Jul 11, 2023 at 05:52:28PM +0200, Hanna Czenczek wrote:
The only user of
index
outside of virtio_queue_packed_get_last_avail_idx(), where we
reconstruct the 32-bit value from avail and used indices and their wrap
counters again. There, it does not matter whether the highest bit of
the used_idx is the used index wrap counter, because we put the wrap
counter exactly in that position anyway.
Signed-off-by
On 20.07.23 17:05, Hao Xu wrote:
On 7/20/23 21:20, Hanna Czenczek wrote:
On 20.07.23 14:13, Hao Xu wrote:
On 7/12/23 19:17, Hanna Czenczek wrote:
Add the interface for transferring the back-end's state during
migration
as defined previously in vhost-user.rst.
Signed-off-by: Hanna Cze
ink: https://bugzilla.redhat.com/show_bug.cgi?id=2217204
Signed-off-by: Hanna Czenczek
---
block.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/block.c b/block.c
index a307c151a8..f530dd9c02 100644
--- a/block.c
+++ b/block.c
@@ -661,8 +661,10 @@ int coroutine_fn bdrv_co_create_o
On 20.07.23 14:13, Hao Xu wrote:
On 7/12/23 19:17, Hanna Czenczek wrote:
Add the interface for transferring the back-end's state during migration
as defined previously in vhost-user.rst.
Signed-off-by: Hanna Czenczek
---
include/hw/virtio/vhost-backend.h | 24 +
include/hw/v
On 18.07.23 20:42, Stefan Hajnoczi wrote:
On Wed, Jul 12, 2023 at 01:17:01PM +0200, Hanna Czenczek wrote:
vhost_save_backend_state() and vhost_load_backend_state() can be used by
vhost front-ends to easily save and load the back-end's state to/from
the migration stream.
Because we do not
On 18.07.23 18:12, Stefan Hajnoczi wrote:
On Wed, Jul 12, 2023 at 01:16:59PM +0200, Hanna Czenczek wrote:
@@ -1471,6 +1511,53 @@ Front-end message types
before. The back-end must again begin processing rings that are not
stopped, and it may resume background operations
On 18.07.23 17:57, Stefan Hajnoczi wrote:
On Wed, Jul 12, 2023 at 01:16:59PM +0200, Hanna Czenczek wrote:
For vhost-user devices, qemu can migrate the virtio state, but not the
back-end's internal state. To do so, we need to be able to transfer
this internal state between front-end (qemu
On 19.07.23 16:11, Hanna Czenczek wrote:
On 18.07.23 17:10, Stefan Hajnoczi wrote:
On Tue, Jul 11, 2023 at 05:52:28PM +0200, Hanna Czenczek wrote:
The only user of vhost_user_reset_status() is vhost_dev_stop(), which
only uses it as a fall-back to stop the back-end if it does not support
On 18.07.23 17:10, Stefan Hajnoczi wrote:
On Tue, Jul 11, 2023 at 05:52:28PM +0200, Hanna Czenczek wrote:
The only user of vhost_user_reset_status() is vhost_dev_stop(), which
only uses it as a fall-back to stop the back-end if it does not support
SUSPEND. However, vhost-user's implement
On 18.07.23 16:50, Stefan Hajnoczi wrote:
On Tue, Jul 11, 2023 at 05:52:27PM +0200, Hanna Czenczek wrote:
vhost-vdpa and vhost-user differ in how they reset the status in their
respective vhost_reset_status implementations: vhost-vdpa zeroes it,
then re-adds the S_ACKNOWLEDGE and S_DRIVER
On 18.07.23 16:25, Stefan Hajnoczi wrote:
On Tue, Jul 11, 2023 at 05:52:23PM +0200, Hanna Czenczek wrote:
When stopping the VM, qemu wants all devices to fully cease any
operation, too. Currently, we can only have vhost-user back-ends stop
processing vrings, but not background operations. Add
On 18.07.23 17:26, Stefan Hajnoczi wrote:
On Wed, Jul 12, 2023 at 11:17:04AM +0200, Hanna Czenczek wrote:
Currently, the vhost-user documentation says that rings are to be
initialized in a disabled state when VHOST_USER_F_PROTOCOL_FEATURES is
negotiated. However, by the time of feature
er Maydell
Fixes: 18743311b829cafc1737a5f20bc3248d5f91ee2a
("block: Collapse padded I/O vecs exceeding IOV_MAX")
Signed-off-by: Hanna Czenczek
---
v2:
- Added paragraph to the commit message to express explicitly that this
patch will not change guest-visible behavior
- (No code c
On 12.07.23 16:15, Stefan Hajnoczi wrote:
On Wed, Jul 12, 2023 at 09:41:05AM +0200, Hanna Czenczek wrote:
On 11.07.23 22:23, Stefan Hajnoczi wrote:
On Fri, Jun 09, 2023 at 10:33:16AM +0200, Hanna Czenczek wrote:
bdrv_pad_request() relies on requests' lengths not to exceed SIZE_MAX,
On 12.07.23 13:17, Michael S. Tsirkin wrote:
On Wed, Jul 12, 2023 at 11:17:04AM +0200, Hanna Czenczek wrote:
Currently, the vhost-user documentation says that rings are to be
initialized in a disabled state when VHOST_USER_F_PROTOCOL_FEATURES is
negotiated. However, by the time of feature
Add the interface for transferring the back-end's state during migration
as defined previously in vhost-user.rst.
Signed-off-by: Hanna Czenczek
---
include/hw/virtio/vhost-backend.h | 24 +
include/hw/virtio/vhost.h | 79
hw/virtio/vhost-user.c
, and
writes each chunk consecutively into the migration stream, prefixed by
its length. EOF is indicated by a 0-length chunk.
Signed-off-by: Hanna Czenczek
---
include/hw/virtio/vhost.h | 35 +++
hw/virtio/vhost.c | 204 ++
2 files changed, 239 inser
VICE_STATE, which on the destination side includes
checking for integrity (i.e. errors during deserialization).
Suggested-by: Stefan Hajnoczi
Signed-off-by: Hanna Czenczek
---
docs/interop/vhost-user.rst | 87 +
1 file changed, 87 insertions(+)
diff --git a/do
ernal
migration, it can be disabled.
Signed-off-by: Hanna Czenczek
---
hw/virtio/vhost-user-fs.c | 101 +-
1 file changed, 100 insertions(+), 1 deletion(-)
diff --git a/hw/virtio/vhost-user-fs.c b/hw/virtio/vhost-user-fs.c
index 49d699ffc2..2b30f3d442 100644
old patch 1, which I dropped.)
Hanna Czenczek (4):
vhost-user.rst: Migrating back-end-internal state
vhost-user: Interface for migration state transfer
vhost: Add high-level state save/load functions
vhost-user-fs: Implement internal migration
docs/interop/vhost-user.rst
n the documentation.
Signed-off-by: Hanna Czenczek
---
docs/interop/vhost-user.rst | 23 +--
1 file changed, 17 insertions(+), 6 deletions(-)
diff --git a/docs/interop/vhost-user.rst b/docs/interop/vhost-user.rst
index 5a070adbc1..ca0e899765 100644
--- a/docs/interop/vhost-user.rst
+++ b
On 11.07.23 22:23, Stefan Hajnoczi wrote:
On Fri, Jun 09, 2023 at 10:33:16AM +0200, Hanna Czenczek wrote:
bdrv_pad_request() relies on requests' lengths not to exceed SIZE_MAX,
which bdrv_check_qiov_request() does not guarantee.
bdrv_check_request32() however will guarantee this, and bo
The next commit is going to have vhost_vdpa_dev_start() call this, so
move it up to have the declaration where we are going to need it.
Signed-off-by: Hanna Czenczek
---
hw/virtio/vhost-vdpa.c | 28 ++--
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/hw
ESET_DEVICE and RESET_OWNER should
remain valid as fall-backs.
Therefore, have vhost_user_reset_status() fall back to
vhost_user_reset_device() if the back-end has no STATUS support.
Signed-off-by: Hanna Czenczek
---
hw/virtio/vhost-user.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/hw/virt
therefore it makes more sense to keep the status
field fully cleared until the back-end is re-started, which is how
vhost-user does it. Make vhost-vdpa do the same -- if nothing else it's
confusing to have both vhost implementations handle this differently.
Signed-off-by: Hanna Czenczek
--
Implement SUSPEND/RESUME like vDPA does, by automatically using it in
vhost_user_dev_start(). (Though our vDPA code does not implement RESUME
yet, so there, the device is reset when it is to be resumed.)
Signed-off-by: Hanna Czenczek
---
hw/virtio/vhost-user.c | 99
-vdpa code currently does not
make use of RESUME, it is actually always used for vhost-vdpa (to take
the device out of a suspended state).
Hanna Czenczek (6):
vhost-user.rst: Add suspend/resume
vhost-vdpa: Move vhost_vdpa_reset_status() up
vhost: Do not reset suspended devices on stop
l
the device is resumed, which is why this patch specifies handling of
kicks as it does.
Signed-off-by: Hanna Czenczek
---
docs/interop/vhost-user.rst | 35 +--
1 file changed, 33 insertions(+), 2 deletions(-)
diff --git a/docs/interop/vhost-user.rst b/docs/in
for back-ends that do not support suspend.
Unfortunately, for vDPA specifically, RESUME is not yet implemented, so
when the device is re-started, we still have to do the reset to have it
un-suspend.
Signed-off-by: Hanna Czenczek
---
include/hw/virtio/vhost-vdpa.h | 2 --
include/hw/virtio/vhos
On 09.06.23 10:33, Hanna Czenczek wrote:
bdrv_pad_request() relies on requests' lengths not to exceed SIZE_MAX,
which bdrv_check_qiov_request() does not guarantee.
bdrv_check_request32() however will guarantee this, and both of
bdrv_pad_request()'s callers (bdrv_co_preadv_
On 09.06.23 15:21, Alexander Ivanov wrote:
On 6/2/23 16:59, Hanna Czenczek wrote:
On 29.05.23 17:15, Alexander Ivanov wrote:
Repair an image at opening if the image is unclean or out-of-image
corruption was detected.
Signed-off-by: Alexander Ivanov
---
block/parallels.c | 65
Peter Maydell
Fixes: 18743311b829cafc1737a5f20bc3248d5f91ee2a
("block: Collapse padded I/O vecs exceeding IOV_MAX")
Signed-off-by: Hanna Czenczek
---
block/io.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/block/io.c b/block/io.c
index 30748f0b59.
On 08.06.23 11:52, Peter Maydell wrote:
On Mon, 5 Jun 2023 at 16:48, Hanna Czenczek wrote:
When processing vectored guest requests that are not aligned to the
storage request alignment, we pad them by adding head and/or tail
buffers for a read-modify-write cycle.
Hi; Coverity complains (CID
On 07.06.23 08:51, Michael Tokarev wrote:
05.06.2023 18:45, Hanna Czenczek wrote:
From: Alexander Ivanov
data_end field in BDRVParallelsState is set to the biggest offset
present
in BAT. If this offset is outside of the image, any further write will
create the cluster at this offset and/or
Hi everyone!
I’ve just released the first version (0.1) of RSD, which is a
proof-of-concept to rewrite the qemu-storage-daemon (QSD) and thus the
qemu block layer in Rust:
https://gitlab.com/hreitz/rsd
https://gitlab.com/hreitz/rsd/-/releases/v0.1
We’ve been talking for quite a long time abo
On 06.06.23 10:00, Michael Tokarev wrote:
05.06.2023 18:45, Hanna Czenczek wrote:
When processing vectored guest requests that are not aligned to the
storage request alignment, we pad them by adding head and/or tail
buffers for a read-modify-write cycle.
The guest can submit I/O vectors up to
parate function
parallels: Fix statistics calculation
parallels: Move check of leaks to a separate function
parallels: Move statistic collection to a separate function
parallels: Replace qemu_co_mutex_lock by WITH_QEMU_LOCK_GUARD
parallels: Incorrect condition in out-of-image check
Hanna Czenczek
: <20230424093147.197643-7-alexander.iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 31 +--
1 file changed, 21 insertions(+), 10 deletions(-)
diff --git a/block/parallels.c b/block/parallels.c
index fa8a
iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 17 +
1 file changed, 17 insertions(+)
diff --git a/block/parallels.c b/block/parallels.c
index d8a3f13e24..7b6d770f8e 100644
--- a/block/parallels.c
+++ b/block/parallels.c
@@ -733,6
u/-/issues/1621
Signed-off-by: Jean-Louis Dupond
Message-Id: <20230605084523.34134-2-jean-lo...@dupond.be>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
qapi/block-core.json | 12
block/qcow2.h | 3 +++
block/qcow2-cluster.c | 32 +++
: <20230424093147.197643-11-alexander.iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 52 +++
1 file changed, 30 insertions(+), 22 deletions(-)
diff --git a/block/parallels.c b/block/paral
From: Alexander Ivanov
All the offsets in the BAT must be lower than the file size.
Fix the check condition for correct check.
Signed-off-by: Alexander Ivanov
Reviewed-by: Denis V. Lunev
Message-Id: <20230424093147.197643-13-alexander.iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
ed-by: Denis V. Lunev
Message-Id: <20230424093147.197643-4-alexander.iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/block/parallels.c b/block/parallels.c
index
(), which might
also benefit its pre-existing users.
Reviewed-by: Eric Blake
Reviewed-by: Vladimir Sementsov-Ogievskiy
Signed-off-by: Hanna Czenczek
Message-Id: <20230411173418.19549-4-hre...@redhat.com>
---
include/qemu/iov.h | 5 ---
util/iov.c
iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 23 ++-
1 file changed, 10 insertions(+), 13 deletions(-)
diff --git a/block/parallels.c b/block/parallels.c
index db6426e5f9..fa8a56a948 100644
--- a/block/parallels.c
+++ b
wed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 74 ---
1 file changed, 45 insertions(+), 29 deletions(-)
diff --git a/block/parallels.c b/block/parallels.c
index fd1e2860d0..ba766e5e86 100644
--- a/block/parallels.c
+++ b
qiov_slice() itself, thus get the number of elements, and also create an
iovec array with the superfluous prefixing elements stripped, so the
following processing functions no longer need to skip them.)
Reviewed-by: Eric Blake
Reviewed-by: Vladimir Sementsov-Ogievskiy
Signed-off-by: Hanna Czenczek
com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 11 ---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/block/parallels.c b/block/parallels.c
index ea382e8382..db6426e5f9 100644
--- a/block/parallels.c
+++ b/block/parallels.c
@@
From: Alexander Ivanov
Exclude out-of-image clusters from allocated and fragmented clusters
calculation.
Signed-off-by: Alexander Ivanov
Message-Id: <20230424093147.197643-9-alexander.iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels
viewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/block/parallels.c b/block/parallels.c
index 7b6d770f8e..204d20685b 100644
--- a/block/parallels.c
+++ b/block/parallels.c
@@ -462,12 +462,12 @@ pa
From: Alexander Ivanov
Replace the way we use mutex in parallels_co_check() for simplier
and less error prone code.
Signed-off-by: Alexander Ivanov
Reviewed-by: Denis V. Lunev
Message-Id: <20230424093147.197643-12-alexander.iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-
iva...@virtuozzo.com>
Reviewed-by: Hanna Czenczek
Signed-off-by: Hanna Czenczek
---
block/parallels.c | 75 +++
1 file changed, 49 insertions(+), 26 deletions(-)
diff --git a/block/parallels.c b/block/parallels.c
index 94b7408b6b..7f0f72e879 100644
gzilla.redhat.com/show_bug.cgi?id=2141964
Signed-off-by: Hanna Czenczek
Message-Id: <20230411173418.19549-3-hre...@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy
---
block/io.c | 166 -
1 file changed, 151 insertions(+), 15 deletions
Test that even vectored IO requests with 1024 vector elements that are
not aligned to the device's request alignment will succeed.
Reviewed-by: Eric Blake
Reviewed-by: Vladimir Sementsov-Ogievskiy
Signed-off-by: Hanna Czenczek
Message-Id: <20230411173418.19549-5-hre...@redhat.com>
files changed, 73 insertions(+), 4 deletions(-)
Thanks!
Reviewed-by: Hanna Czenczek
On 02.06.23 14:47, Jean-Louis Dupond wrote:
When we for example have a sparse qcow2 image and discard: unmap is enabled,
there can be a lot of fragmentation in the image after some time. Especially on
VM's
that do a lot of writes/deletes.
This causes the qcow2 image to grow even over 110% of its
d even
reuse that where migrate_add_blocker() fails.
Anyway, not wrong as-is, just suggestion, so:
Reviewed-by: Hanna Czenczek
+error_setg_errno(errp, -ret, "Could not repair corrupted image");
+goto fail;
+}
+}
+
return 0;
fail_format:
On 29.05.23 17:15, Alexander Ivanov wrote:
If the check is called during normal work, tracking of the check must be
present in VM logs to have some clues if something going wrong with user's
data.
I understand stderr counts as part of the VM log, doesn’t it? I thought
stderr is generally logg
le changed, 2 insertions(+), 2 deletions(-)
Reviewed-by: Hanna Czenczek
On 29.05.23 17:15, Alexander Ivanov wrote:
Cluster offsets must be unique among all the BAT entries. Find duplicate
offsets in the BAT and fix it by copying the content of the relevant
cluster to a newly allocated cluster and set the new cluster offset to the
duplicated entry.
Add host_cluster_i
On 29.05.23 17:15, Alexander Ivanov wrote:
We need to fix leak after deduplication in the next patch. Move leak
fixing to a separate helper parallels_fix_leak() and add
parallels_get_leak_size() helper wich used in parallels_fix_leak() and
parallels_check_leak().
Signed-off-by: Alexander Ivanov
On 01.06.23 14:56, Jean-Louis Dupond wrote:
On 31/05/2023 17:05, Hanna Czenczek wrote:
On 15.05.23 09:36, Jean-Louis Dupond wrote:
When we for example have a sparse qcow2 image and discard: unmap is
enabled,
there can be a lot of fragmentation in the image after some time.
Surely on VM'
On 31.05.23 21:09, Stefan Hajnoczi wrote:
Another issue is that 145 uses $TEST_IMG as follows:
SYSEMU_DRIVE_ARG=if=none,file="$TEST_IMG",driver=$IMGFMT
That doesn't work when json: contains a comma, since commas need to be
doubled up to escape them. This fails:
$ qemu-system-x86_64 -driv
On 15.05.23 09:36, Jean-Louis Dupond wrote:
When we for example have a sparse qcow2 image and discard: unmap is enabled,
there can be a lot of fragmentation in the image after some time. Surely on VM's
that do a lot of writes/deletes.
This causes the qcow2 image to grow even over 110% of its virt
On 15.05.23 09:36, Jean-Louis Dupond wrote:
When we for example have a sparse qcow2 image and discard: unmap is enabled,
there can be a lot of fragmentation in the image after some time. Surely on VM's
s/. Surely/, especially/
that do a lot of writes/deletes.
This causes the qcow2 image to gr
On 26.05.23 16:30, Jean-Louis Dupond wrote:
On 26/05/2023 15:31, Hanna Czenczek wrote:
[...]
I don’t follow how this patch is cleaner than the “block: Add zeroes
discard option” patch. That patch’s diff stat is +14/-5, this one’s
is 120+/57-.
Multiple reasons :)
- It's made for thi
On 15.05.23 09:36, Jean-Louis Dupond wrote:
When we for example have a sparse qcow2 image and discard: unmap is enabled,
there can be a lot of fragmentation in the image after some time. Surely on VM's
that do a lot of writes/deletes.
This causes the qcow2 image to grow even over 110% of its virt
gh to be low priority, R-b dropped
---
tests/unit/test-cutils.c | 20 +---
util/cutils.c| 25 +++--
2 files changed, 28 insertions(+), 17 deletions(-)
Reviewed-by: Hanna Czenczek
int err;
+/* 1 less than -ULONG_MAX */
+str = ULONG_MAX == UINT_MAX ? "-4294967296" : "-18446744073709551616";
+endptr = "somewhere";
+res = 999;
err = qemu_strtoul(str, &endptr, 0, &res);
+g_assert_cmpint(err, ==, -ERANGE);
+g_assert_cmpint(res, ==, ULONG_MAX);
Should be g_assert_cmpuint().
Reviewed-by: Hanna Czenczek
On 19.05.23 19:52, Eric Blake wrote:
On Fri, May 19, 2023 at 05:05:20PM +0200, Hanna Czenczek wrote:
On 12.05.23 04:10, Eric Blake wrote:
It's hard to tweak code for consistency if I can't prove what will or
won't break from those tweaks. Time to add unit tests for
qe
anna]
---
tests/unit/test-cutils.c | 50 +-----
util/cutils.c| 89 ++--
2 files changed, 86 insertions(+), 53 deletions(-)
Reviewed-by: Hanna Czenczek
cified. Must be between 0 and
9223372036854775807.
qemu-img: Unknown file format 'foo'
== Size calculation for a new file (human) ==
With that squashed in:
Reviewed-by: Hanna Czenczek
is significant enough
that I doropped Hanna's R-b
---
tests/unit/test-cutils.c | 106 +++
util/cutils.c| 17 +--
2 files changed, 63 insertions(+), 60 deletions(-)
Reviewed-by: Hanna Czenczek
ll do_strtosz*() with a NULL str –
did you intent for this to go into patch 12?
Regardless (with the subject fixed, though):
Reviewed-by: Hanna Czenczek
| 3 +++
util/cutils.c| 2 +-
2 files changed, 4 insertions(+), 1 deletion(-)
Reviewed-by: Hanna Czenczek
27;m not too worried about
it.
Signed-off-by: Eric Blake
---
tests/unit/test-cutils.c | 503 ---
1 file changed, 100 insertions(+), 403 deletions(-)
Reviewed-by: Hanna Czenczek
tually expect EINVAL, but understand that’s a personal preference.
(Same for the _finite_ variant)
Reviewed-by: Hanna Czenczek
+str = "1e-999junk";
+endptr = "somewhere";
+res = 999;
+err = qemu_strtod(str, &endptr, &res);
+g_assert_cmpint(err
';
-char *endptr;
+uint64_t i;
+const char *endptr = "somewhere";
The initialization here is technically not necessary because it’s reset
above the parse_uint() call below.
Anyway:
Reviewed-by: Hanna Czenczek
const char *str;
int r;
i = 999;
-en
ls.c| 34 --
2 files changed, 28 insertions(+), 24 deletions(-)
Reviewed-by: Hanna Czenczek
1 file changed, 12 insertions(+), 8 deletions(-)
Reviewed-by: Hanna Czenczek
-cutils.c | 11 +--
util/cutils.c| 14 ++
2 files changed, 15 insertions(+), 10 deletions(-)
Reviewed-by: Hanna Czenczek
diff --git a/util/cutils.c b/util/cutils.c
index 5887e744140..997ddcd09e5 100644
--- a/util/cutils.c
+++ b/util/cutils.c
@@ -466,10 +466,16 @@ int qemu
On 12.05.23 04:10, Eric Blake wrote:
We have quite a few undertested and underdocumented integer parsing
corner cases. To ensure that any changes we make in the code are
intentional rather than accidental semantic changes, it is time to add
more unit tests of existing behavior.
In particular, t
Thanks for the patch!
As a note for hopefully many future patches ( :) ), you should run
scripts/checkpatch.pl on them to check for coding style issues. Here, it
reports two lines that are longer than 80 characters.
Second, ideally, patches are not just sent to the qemu-devel list, but
also
On 10.05.23 09:46, Hanna Czenczek wrote:
On 09.05.23 23:28, Eric Blake wrote:
[...]
But I think the solution to that is not to treat underflow as valf =
0, but rather to alter this snippet:
- valf = (uint64_t)(fraction * 0x1p64);
+ /*
+ * If fraction was
On 09.05.23 23:28, Eric Blake wrote:
On Tue, May 09, 2023 at 07:54:30PM +0200, Hanna Czenczek wrote:
On 08.05.23 22:03, Eric Blake wrote:
We have several limitations and bugs worth fixing; they are
inter-related enough that it is not worth splitting this patch into
smaller pieces:
* &quo
unit/test-cutils.c | 1213 ++
util/cutils.c| 180 --
3 files changed, 1090 insertions(+), 314 deletions(-)
Patches 1 – 5, 7 – 10:
Reviewed-by: Hanna Czenczek
On 08.05.23 22:03, Eric Blake wrote:
We have several limitations and bugs worth fixing; they are
inter-related enough that it is not worth splitting this patch into
smaller pieces:
* ".5k" should work to specify 512, just as "0.5k" does
* "1.k" and "1." + "9"*50 + "k" should both produce the
On 08.05.23 22:03, Eric Blake wrote:
Add some more strings that the user might send our way. In
particular, some of these additions include FIXME comments showing
where our parser doesn't quite behave the way we want.
Signed-off-by: Eric Blake
---
tests/unit/test-cutils.c | 226 +
On 09.05.23 14:31, Hanna Czenczek wrote:
On 08.05.23 22:03, Eric Blake wrote:
Add some more strings that the user might send our way. In
particular, some of these additions include FIXME comments showing
where our parser doesn't quite behave the way we want.
Signed-off-by: Eric
On 08.05.23 22:03, Eric Blake wrote:
Add some more strings that the user might send our way. In
particular, some of these additions include FIXME comments showing
where our parser doesn't quite behave the way we want.
Signed-off-by: Eric Blake
---
tests/unit/test-cutils.c | 226 +
On 09.05.23 08:31, Eugenio Perez Martin wrote:
On Mon, May 8, 2023 at 9:12 PM Stefan Hajnoczi wrote:
[...]
VHOST_USER_GET_VRING_BASE itself isn't really enough because it stops a
specific virtqueue but not the whole device. Unfortunately stopping all
virtqueues is not the same as SUSPEND sin
On 08.05.23 21:31, Eugenio Perez Martin wrote:
On Mon, May 8, 2023 at 7:51 PM Eugenio Perez Martin wrote:
On Mon, May 8, 2023 at 7:00 PM Hanna Czenczek wrote:
On 05.05.23 16:37, Hanna Czenczek wrote:
On 05.05.23 16:26, Eugenio Perez Martin wrote:
On Fri, May 5, 2023 at 11:51 AM Hanna
On 08.05.23 23:10, Stefan Hajnoczi wrote:
On Fri, May 05, 2023 at 02:51:55PM +0200, Hanna Czenczek wrote:
On 05.05.23 11:53, Eugenio Perez Martin wrote:
On Fri, May 5, 2023 at 11:03 AM Hanna Czenczek wrote:
On 04.05.23 23:14, Stefan Hajnoczi wrote:
On Thu, 4 May 2023 at 13:39, Hanna
201 - 300 of 398 matches
Mail list logo