On Wed 20 Jan 2016 07:29:19 PM CET, Max Reitz wrote:
> @@ -2424,6 +2442,15 @@ static void qmp_blockdev_insert_anon_medium(const char
> *device,
>
> blk_insert_bs(blk, bs);
>
> +if (!blk_dev_has_tray(blk)) {
> +/* For tray-less devices, blockdev-close-tray is a no-op (or may no
{insert,remove}-medium (for tray-less devices only).
>
> Reported-by: Peter Maydell
> Cc: qemu-stable
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
Hi,
I'm late to the party but I wanted to say that I generally like the idea
of expressing the notion of op blockers in terms of the specific things
that they allow and require in each one of the affected nodes.
I don't know if all current operations can be expressed easily with
these semantics,
On Thu, Jan 28, 2016 at 08:25:18AM -0700, Eric Blake wrote:
> > Sadly what I need is block-stream to an intermediate layer (as I
> > want to merge in the other direction); I don't think that proposal
> > was ever implemented.
> >
> > http://wiki.qemu.org/Features/Snapshots#Streaming_to_an_Interme
On Tue 10 Nov 2015 06:23:36 PM CET, Eric Blake wrote:
>> +# @stats-intervals: #optional colon-separated list of intervals for
>> +# collecting I/O statistics, in seconds (default: none)
>> +# (Since 2.5)
>
> Eww. Sorry for not noticing this sooner, but can we p
This is the natural JSON representation and prevents us from having to
decode the list manually.
Signed-off-by: Alberto Garcia
---
blockdev.c | 64 ++
qapi/block-core.json | 7 +++---
tests/qemu-iotests/136 | 2 +-
3 files changed
On Tue 10 Nov 2015 04:27:43 AM CET, Max Reitz wrote:
> This function skips to the next BlockBackend for which blk_is_inserted()
> is true.
>
> Signed-off-by: Max Reitz
> Reviewed-by: Eric Blake
Reviewed-by: Alberto Garcia
Berto
On Wed 11 Nov 2015 04:32:42 PM CET, Eric Blake wrote:
>> -for (i = 0; !error && intervals[i] != NULL; i++) {
>> +case QTYPE_QSTRING: {
>
>> +case QTYPE_QINT: {
>
> Why are we accepting both string and int here, but typing it as 'int' in
> qapi? I guess its due t
he important thing is that we are still testing that it has stopped,
> and that it finishes successfully after we send a resume command.
>
> Signed-off-by: John Snow
Reviewed-by: Alberto Garcia
Berto
of the accounting code (2015-11-12 16:22:47 +0100)
>
>
> Block layer patches (rebased Stefan's pull request)
>
> ----
> Alberto Garcia (21):
> xen_disk: Account for flush operations
> ide: Account for wr
On Fri 13 Nov 2015 11:15:52 AM CET, Stefan Hajnoczi wrote:
> blockdev.c: In function ‘blockdev_init’:
> blockdev.c:636:17: error: ‘length’ may be used uninitialized in this function
> [-Werror=maybe-uninitialized]
> block_acct_add_interval(blk_get_stats(blk), length);
>
Otherwise the AioContext will never be released.
Signed-off-by: Alberto Garcia
---
blockdev.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/blockdev.c b/blockdev.c
index fc85128..4dcc510 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -2070,6 +2070,7 @@ static const BlkActionOps actions
This is the natural JSON representation and prevents us from having to
decode the list manually.
Signed-off-by: Alberto Garcia
---
blockdev.c | 91 +++---
qapi/block-core.json | 7 ++--
tests/qemu-iotests/136 | 2 +-
3 files changed
l_dict and interval_list are now initialized to NULL
v1: https://lists.gnu.org/archive/html/qemu-block/2015-11/msg00432.html
Regards,
Berto
Alberto Garcia (1):
block: make 'stats-interval' an array of ints instead of a string
blockdev.c | 91 +++-
On Mon 16 Nov 2015 04:46:44 AM CET, Stefan Hajnoczi wrote:
>> early_err:
>> qemu_opts_del(opts);
>> +QDECREF(interval_dict);
>> +QDECREF(interval_list);
>
> There is a codepath that reaches here without initializing interval_dict
> or interval_list:
>
> qemu_opts_absorb_qdict(opts,
This was accidentally changed by commit 5f81724d
Signed-off-by: Alberto Garcia
---
hw/ide/atapi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/ide/atapi.c b/hw/ide/atapi.c
index 5e3791c..65f8dd4 100644
--- a/hw/ide/atapi.c
+++ b/hw/ide/atapi.c
@@ -443,7 +443,7 @@ eot
Commit 5f81724d made PIO read requests async but didn't add the
relevant block_acct_failed() and block_acct_invalid() calls.
Signed-off-by: Alberto Garcia
---
hw/ide/atapi.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/hw/ide/atapi.c b/hw/ide/atapi.c
index 7b
On Tue 24 Nov 2015 01:47:52 PM CET, Kevin Wolf wrote:
> Am 24.11.2015 um 13:17 hat Alberto Garcia geschrieben:
>> Commit 5f81724d made PIO read requests async but didn't add the
>> relevant block_acct_failed() and block_acct_invalid() calls.
>>
>> Signed-off-
This code has been dead for three years (since commit 7e7b7cba1).
Signed-off-by: Alberto Garcia
---
hw/block/xen_disk.c | 8
1 file changed, 8 deletions(-)
diff --git a/hw/block/xen_disk.c b/hw/block/xen_disk.c
index 02eda6e..8146650 100644
--- a/hw/block/xen_disk.c
+++ b/hw/block
This patch adds all the throttling.*-max-length command-line
parameters to define the length of the burst periods.
Signed-off-by: Alberto Garcia
---
blockdev.c | 37 +
1 file changed, 37 insertions(+)
diff --git a/blockdev.c b/blockdev.c
index c9e91ab
This patch adds the new bps_*_max_length and iops_*_max_length
parameters to the BlockDeviceInfo struct.
Signed-off-by: Alberto Garcia
---
block/qapi.c | 20
qapi/block-core.json | 39 +--
2 files changed, 53 insertions(+), 6
f the throttling
configuration.
This patch ensures that the value of bucket.avg is valid when setting
bucket.max.
Signed-off-by: Alberto Garcia
---
tests/test-throttle.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tests/test-throttle.c b/tests/test-throttle.c
index 5f0b7d4..5031eb7 100644
--- a/
The caller does not need to set it, and this will allow us to refactor
this function later.
Signed-off-by: Alberto Garcia
---
blockdev.c | 4 +---
include/qemu/throttle.h | 2 +-
tests/test-throttle.c | 2 +-
util/throttle.c | 5 -
4 files changed, 7 insertions(+), 6
This test simulates an I/O burst for more than two seconds and checks
that it works as expected.
Signed-off-by: Alberto Garcia
---
tests/test-throttle.c | 22 ++
1 file changed, 22 insertions(+)
diff --git a/tests/test-throttle.c b/tests/test-throttle.c
index 11ede23
This patch expands test_leak_bucket() to check that burst_level leaks
correctly.
Signed-off-by: Alberto Garcia
---
tests/test-throttle.c | 16
1 file changed, 16 insertions(+)
diff --git a/tests/test-throttle.c b/tests/test-throttle.c
index cf81033..11ede23 100644
--- a/tests
There's no need to keep throttle_conflicting(), throttle_is_valid()
and throttle_max_is_missing_limit() as separate functions, so this
patch merges all three into one.
As a consequence, check_throttle_config() becomes redundant and can be
replaced with throttle_is_valid().
Signed-off-by: Al
This patch adds the new bps_*_max_length and iops_*_max_length
parameters to the block_set_io_throttle command.
Signed-off-by: Alberto Garcia
---
blockdev.c | 31 +++
hmp.c| 12
qapi/block-core.json | 51
This function is only used internally in throttle.c
Signed-off-by: Alberto Garcia
---
include/qemu/throttle.h | 6 --
util/throttle.c | 8
2 files changed, 4 insertions(+), 10 deletions(-)
diff --git a/include/qemu/throttle.h b/include/qemu/throttle.h
index d0c98ed
a more clear API.
And I think that's all.
Thanks!
Berto
Alberto Garcia (13):
throttle: Make throttle_compute_timer() static
throttle: Make throttle_conflicting() set errp
throttle: Make throttle_max_is_missing_limit() set errp
throttle: Make throttle_is_valid() set errp
throttle: S
The caller does not need to set it, and this will allow us to refactor
this function later.
Signed-off-by: Alberto Garcia
---
blockdev.c | 4 +---
include/qemu/throttle.h | 2 +-
tests/test-throttle.c | 6 +++---
util/throttle.c | 5 -
4 files changed, 9 insertions
The caller does not need to set it, and this will allow us to refactor
this function later.
Signed-off-by: Alberto Garcia
---
blockdev.c | 4 +---
include/qemu/throttle.h | 2 +-
tests/test-throttle.c | 12 ++--
util/throttle.c | 11 +--
4 files changed
.
Signed-off-by: Alberto Garcia
---
blockdev.c | 4 ++--
include/qemu/throttle.h | 2 ++
tests/test-throttle.c | 28 +---
util/throttle.c | 10 ++
4 files changed, 31 insertions(+), 13 deletions(-)
diff --git a/blockdev.c b/blockdev.c
index
This patch adds support for burst periods to the throttling code.
With this feature the user can keep performing bursts as defined by
the LeakyBucket.max rate for a configurable period of time.
Signed-off-by: Alberto Garcia
---
include/qemu/throttle.h | 41 +++
util
On Fri 05 Feb 2016 03:25:22 AM CET, Changlong Xie
wrote:
> Signed-off-by: Wen Congyang
> Signed-off-by: Changlong Xie
Reviewed-by: Alberto Garcia
Berto
-off-by: Max Reitz
> Reviewed-by: Kevin Wolf
> Reviewed-by: Fam Zheng
Reviewed-by: Alberto Garcia
Berto
Explain what happens if the user tries to delete a BlockBackend that
contains media that was added separately using blockdev-add.
Signed-off-by: Alberto Garcia
---
qapi/block-core.json | 5 -
qmp-commands.hx | 5 -
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/qapi
ss the BDS is ejected first. This is an unnecessary restriction.
Now that we have a list of monitor-owned BDSs we can allow
x-blockdev-del to work in this scenario if the BDS has exactly one
extra reference and that reference is from the monitor.
Signed-off-by: Alberto Garcia
---
block
functionality works as expected.
Signed-off-by: Alberto Garcia
---
tests/qemu-iotests/139 | 30 +-
tests/qemu-iotests/139.out | 4 ++--
2 files changed, 27 insertions(+), 7 deletions(-)
diff --git a/tests/qemu-iotests/139 b/tests/qemu-iotests/139
index a4b9694..a6fc299
On Fri 22 Jan 2016 09:02:10 PM CET, "Dr. David Alan Gilbert"
wrote:
>> In general, what do you do to make sure that the data in a new
>> Quorum child is consistent with that of the rest of the array?
>> >>>
>> >>> Quorum can have more than one child when it starts. But we don't
>> >>>
n this scenario if the BDS has exactly one
>> extra reference and that reference is from the monitor.
>>
>> Signed-off-by: Alberto Garcia
>
> This means that what you created with two blockdev-add commands would be
> destroyed with a single blockdev-del command. I think we all
On Tue 09 Feb 2016 04:34:09 PM CET, Eric Blake wrote:
> On 02/08/2016 07:14 AM, Alberto Garcia wrote:
>
> When sending a multi-patch series, you should always include a 0/3 cover
> letter. The cover letter is optional only for a lone patch.
Sorry, I didn't know. The descrip
On Tue 09 Feb 2016 04:36:31 PM CET, Eric Blake wrote:
>> Both testAttachMedia() and testSnapshot() are splitted in two: one
>
> s/splitted/split/ (one of those weird English words whose past tense
> is identical to present tense)
:)
>> tests/qemu-iotests/139 | 30 +--
2 (with the tests) into the first one with the code [Eric]
- s/splitted/split/ in the description of the tests [Eric]
v1: https://lists.gnu.org/archive/html/qemu-block/2016-02/msg00247.html
- Initial version
Alberto Garcia (2):
block: Allow x-blockdev-del on a BB with a monitor-owned BDS
Explain what happens if the user tries to delete a BlockBackend that
contains media that was added separately using blockdev-add.
Signed-off-by: Alberto Garcia
Reviewed-by: Eric Blake
---
qapi/block-core.json | 5 -
qmp-commands.hx | 5 -
2 files changed, 8 insertions(+), 2
his change. Both
testAttachMedia() and testSnapshot() are split in two: one version
keeps the previous behavior, and a second version checks that the new
functionality works as expected.
Signed-off-by: Alberto Garcia
---
blockdev.c | 13 ++---
tests/qemu-iotests/13
On Fri 12 Feb 2016 06:19:06 PM CET, Kevin Wolf wrote:
> Anyway, the cover letter makes sense to me. And thanks for this great
> writeup! Can we turn it into documentation? Throttling seems to be quite
> underdocumented, and your explanation above let me understand for the
> first time what these *
On Tue 16 Feb 2016 11:45:32 AM CET, Kevin Wolf wrote:
>> +/* If the bucket is not full yet we have to make sure that we
>> + * fulfill the goal of bkt->max units per second. */
>> +if (bkt->burst_length > 1) {
>> +/* We use 1/10 of the max value to smooth the throttling.
>> +
On Mon 15 Feb 2016 05:40:29 PM CET, Stefan Hajnoczi wrote:
> On Fri, Feb 05, 2016 at 12:59:10PM +0200, Alberto Garcia wrote:
>> - With this series we set "a maximum of X operations/second for a
>>period of T seconds". If would also be possible to make it "a
adds a .bdrv_join_options callback to BlockDriver and
> implements it for qcow2.
>
> Signed-off-by: Kevin Wolf
Reviewed-by: Alberto Garcia
Berto
ld result in an options QDict that has both
> "overlap-check.template=all" and "overlap-check=none", which obviously
> conflicts. In this case, the old option should be overridden by the
> newly specified option.
>
> Signed-off-by: Kevin Wolf
Reviewed-by: Alberto Garcia
Berto
On Mon 23 Nov 2015 04:59:42 PM CET, Kevin Wolf wrote:
> @@ -370,11 +371,22 @@ static void mirror_exit(BlockJob *job, void *opaque)
> if (s->to_replace) {
> to_replace = s->to_replace;
> }
> +
> +/* This was checked in mirror_start_job(), but meanwhile one of
> Signed-off-by: Kevin Wolf
> Reviewed-by: Eric Blake
> Reviewed-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
t do it here.
>
> This changes the output for iotest 036 (to the better, in my opinion),
> so the reference output needs to be changed accordingly.
>
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
it, too.
>
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
tribution is naturally unambiguous). Furthermore, as of a future
> patch, bdrv_get_device_name(bs) will always return the empty string
> before bdrv_open_inherit() returns.
>
> Therefore, just dropping that information seems to be the best course of
> action.
>
> Signed-off-by: Max Re
On Tue 10 Nov 2015 04:44:20 AM CET, Max Reitz wrote:
> Its only caller is blk_new_open(), so we can just inline it there. Since
> bdrv_new_root() is only a wrapper around bdrv_new(), we can just use
> bdrv_new() instead.
>
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
On Tue 10 Nov 2015 04:44:21 AM CET, Max Reitz wrote:
> It is unused now, so we may just as well drop it.
>
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
s() which in turn assumes that no frozen
> bitmaps are attached to the BDS).
>
> In addition, being called only in bdrv_delete() means that we can drop
> bdrv_close()'s forward declaration at the top of block.c.
>
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
return statement:
bs = bdrv_lookup_bs(reference, reference, errp);
if (bs) {
bdrv_ref(bs);
}
return bs;
but I'm fine either way.
Reviewed-by: Alberto Garcia
Berto
ing 'ret' anymore there's a
"ret = total_size" line earlier in this function that is useless now.
Other than that,
Reviewed-by: Alberto Garcia
Berto
re already filtered out. Works much better this
> way.
>
> Signed-off-by: Kevin Wolf
> Reviewed-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
> Reviewed-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
On Mon 23 Nov 2015 04:59:57 PM CET, Kevin Wolf wrote:
> Just reopening the children (as block.c does now) is enough.
>
> Signed-off-by: Kevin Wolf
Reviewed-by: Alberto Garcia
Berto
On Mon 11 Jan 2016 06:42:38 AM CET, Fam Zheng wrote:
> The implicit casting from unsigned int to double changes negative
> values into large positive numbers, whereas explicitly casting to
> signed integer first will let us catch the invalid value and report
> error correctly:
>
> $ qemu-syst
On Wed 13 Jan 2016 01:52:30 AM CET, Fam Zheng wrote:
> +echo === Catching nagative throttling values ===
s/nagative/negative/
(there are several of these in the patch)
You could also test the upper limits now.
Berto
On Wed 13 Jan 2016 01:52:29 AM CET, Fam Zheng wrote:
> The implicit casting from unsigned int to double changes negative values
> into large positive numbers and accepts them. We should instead print
> an error.
>
> Check the number range so this case is catched and reported.
I still don't know
On Wed 13 Jan 2016 12:02:00 PM CET, Fam Zheng wrote:
>> > Check the number range so this case is catched and reported.
>>
>> I still don't know why qemu_opt_get_number() convert silently
>> negative numbers into positive ones, shouldn't it just fail with an
>> "invalid parameter" error?
>
> Becau
u-stable
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
{insert,remove}-medium (for tray-less devices only).
>
> Reported-by: Peter Maydell
> Cc: qemu-stable
> Signed-off-by: Max Reitz
Reviewed-by: Alberto Garcia
Berto
On Tue 12 Jan 2016 04:47:54 PM CET, Max Reitz wrote:
> Signed-off-by: Max Reitz
> ---
> block/qapi.c | 2 +-
> tests/qemu-iotests/067.out | 4
> 2 files changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/block/qapi.c b/block/qapi.c
> index 58d3975..12a0f25 100644
> --- a
On Mon 18 Jan 2016 02:09:22 AM CET, Fam Zheng wrote:
>> > -error_setg(errp, "bps/iops/maxs values must be 0 or greater");
>> > +error_setg(errp, "bps/iops/max values must be within [0, %" PRId64
>> > + ")", (int64_t)THROTTLE_VALUE_MAX);
>>
>> I think that s
w that you're at it, you could also check that 0 and 1000
_do_ work.
Either way,
Reviewed-by: Alberto Garcia
Berto
Now the negative values are silently converted to a huge positive number
> because we are doing implicit casting from uint64_t to double. Fix it and add
> a
> test case (this was once fixed in 7d81c1413c9 but regressed when the block
> device option parsing code was changed).
Series
Reviewed-by: Alberto Garcia
Berto
On Fri 25 Dec 2015 10:22:55 AM CET, Changlong Xie wrote:
> @@ -875,9 +878,9 @@ static int quorum_open(BlockDriverState *bs, QDict
> *options, int flags,
> ret = -EINVAL;
> goto exit;
> }
> -if (s->num_children < 2) {
> +if (s->num_children < 1) {
> error_set
On Thu 21 Jan 2016 02:54:10 AM CET, Wen Congyang wrote:
>>> @@ -875,9 +878,9 @@ static int quorum_open(BlockDriverState *bs, QDict
>>> *options, int flags,
>>> ret = -EINVAL;
>>> goto exit;
>>> }
>>> -if (s->num_children < 2) {
>>> +if (s->num_children < 1) {
>>>
>> > We do however have translations for a few simple strings for the GTK+
>> > menu items, so in order to run QEMU using the C locale, and yet have a
>> > translated UI let's use setlocale() for LC_MESSAGES only.
>> >
>> Not sure why I noticed it only now and if it's related to any recent
>> pac
On Thu 17 Dec 2015 01:50:08 AM CET, John Snow wrote:
> In working through a prototype to enable multiple block jobs. A few
> problem spots in our API compatibility become apparent.
>
> In a nutshell, old Blockjobs rely on the "device" to identify the job,
> which implies:
>
> 1) A job is always at
On Mon 21 Dec 2015 08:40:26 PM CET, John Snow wrote:
> However, better flexibility also plays a part. Say we have two devices:
>
> [drive0]: [X] --> [Y] --> [Z]
> [drive1]: [A] --> [B]
>
> In theory, we should be able to commit Z into Y into X while we
> simultaneously perform a backup from X to A
The caller does not need to set it, and this will allow us to refactor
this function later.
Signed-off-by: Alberto Garcia
Reviewed-by: Kevin Wolf
Reviewed-by: Stefan Hajnoczi
---
blockdev.c | 4 +---
include/qemu/throttle.h | 2 +-
tests/test-throttle.c | 12
The caller does not need to set it, and this will allow us to refactor
this function later.
Signed-off-by: Alberto Garcia
Reviewed-by: Kevin Wolf
Reviewed-by: Stefan Hajnoczi
---
blockdev.c | 4 +---
include/qemu/throttle.h | 2 +-
tests/test-throttle.c | 2 +-
util/throttle.c
This patch adds a new test that checks that the burst settings
('iops_max', 'iops_max_length', etc.) of the throttling code work as
expected.
Signed-off-by: Alberto Garcia
---
tests/qemu-iotests/093 | 65 --
tests/qemu-iotests
This test simulates an I/O burst for more than two seconds and checks
that it works as expected.
Signed-off-by: Alberto Garcia
Reviewed-by: Stefan Hajnoczi
---
tests/test-throttle.c | 22 ++
1 file changed, 22 insertions(+)
diff --git a/tests/test-throttle.c b/tests/test
.
Signed-off-by: Alberto Garcia
Reviewed-by: Kevin Wolf
Reviewed-by: Stefan Hajnoczi
---
blockdev.c | 4 ++--
include/qemu/throttle.h | 2 ++
tests/test-throttle.c | 28 +---
util/throttle.c | 10 ++
4 files changed, 31 insertions(+), 13
f the throttling
configuration.
This patch ensures that the value of bucket.avg is valid when setting
bucket.max.
Signed-off-by: Alberto Garcia
Reviewed-by: Kevin Wolf
Reviewed-by: Stefan Hajnoczi
---
tests/test-throttle.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tests/test-throttle.c b/
This patch adds the new bps_*_max_length and iops_*_max_length
parameters to the BlockDeviceInfo struct.
Signed-off-by: Alberto Garcia
Reviewed-by: Stefan Hajnoczi
---
block/qapi.c | 20
qapi/block-core.json | 39 +--
2 files
This function is only used internally in throttle.c
Signed-off-by: Alberto Garcia
Reviewed-by: Kevin Wolf
Reviewed-by: Stefan Hajnoczi
---
include/qemu/throttle.h | 6 --
util/throttle.c | 8
2 files changed, 4 insertions(+), 10 deletions(-)
diff --git a/include/qemu
itial version
Alberto Garcia (17):
throttle: Make throttle_compute_timer() static
throttle: Make throttle_conflicting() set errp
throttle: Make throttle_max_is_missing_limit() set errp
throttle: Make throttle_is_valid() set errp
throttle: Set always an average value when setting a maximum
Signed-off-by: Alberto Garcia
---
qapi/block-core.json | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/qapi/block-core.json b/qapi/block-core.json
index fbbc709..9bf1b22 100644
--- a/qapi/block-core.json
+++ b/qapi/block-core.json
@@ -1321,7 +1321,7 @@
#
# @iops: total I/O
This patch adds all the throttling.*-max-length command-line
parameters to define the length of the burst periods.
Signed-off-by: Alberto Garcia
Reviewed-by: Stefan Hajnoczi
---
blockdev.c | 37 +
1 file changed, 37 insertions(+)
diff --git a/blockdev.c b
Signed-off-by: Alberto Garcia
---
docs/throttle.txt | 252 ++
1 file changed, 252 insertions(+)
create mode 100644 docs/throttle.txt
diff --git a/docs/throttle.txt b/docs/throttle.txt
new file mode 100644
index 000..28204e4
--- /dev/null
There's no need to keep throttle_conflicting(), throttle_is_valid()
and throttle_max_is_missing_limit() as separate functions, so this
patch merges all three into one.
As a consequence, check_throttle_config() becomes redundant and can be
replaced with throttle_is_valid().
Signed-off-by: Al
This patch expands test_leak_bucket() to check that burst_level leaks
correctly.
Signed-off-by: Alberto Garcia
Reviewed-by: Stefan Hajnoczi
---
tests/test-throttle.c | 16
1 file changed, 16 insertions(+)
diff --git a/tests/test-throttle.c b/tests/test-throttle.c
index
Signed-off-by: Alberto Garcia
---
MAINTAINERS | 9 +
1 file changed, 9 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index 02710f8..c2f2dd7 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1276,6 +1276,15 @@ S: Maintained
F: include/qemu/sockets.h
F: util/qemu-sockets.c
This patch adds the new bps_*_max_length and iops_*_max_length
parameters to the block_set_io_throttle command.
Signed-off-by: Alberto Garcia
---
blockdev.c | 31 +++
hmp.c| 12
qapi/block-core.json | 51
This patch adds support for burst periods to the throttling code.
With this feature the user can keep performing bursts as defined by
the LeakyBucket.max rate for a configurable period of time.
Signed-off-by: Alberto Garcia
Reviewed-by: Stefan Hajnoczi
---
include/qemu/throttle.h | 41
The caller does not need to set it, and this will allow us to refactor
this function later.
Signed-off-by: Alberto Garcia
Reviewed-by: Kevin Wolf
Reviewed-by: Stefan Hajnoczi
---
blockdev.c | 4 +---
include/qemu/throttle.h | 2 +-
tests/test-throttle.c | 6 +++---
util
On Tue 16 Feb 2016 03:15:44 AM CET, Changlong Xie
wrote:
> If quorum has two children(A, B). A do flush sucessfully, but B flush
> failed. We MUST choice A as winner rather than just pick anyone of
> them. Otherwise the filesystem of guest will become read-only with
> following errors:
>
> end_r
On Fri 19 Feb 2016 09:26:53 AM CET, Wen Congyang wrote:
>>> If quorum has two children(A, B). A do flush sucessfully, but B
>>> flush failed. We MUST choice A as winner rather than just pick
>>> anyone of them. Otherwise the filesystem of guest will become
>>> read-only with following errors:
>>
On Sat 20 Feb 2016 03:28:03 PM CET, Max Reitz wrote:
>> That said, I'm not very convinced of the current logics of the Quorum
>> flush code either, so it's not even a problem with your patch... it
>> seems to me that the code should follow the same logics as in the
>> read/write case: if the numb
On Mon 22 Feb 2016 02:31:30 PM CET, Alberto Garcia wrote:
>> Anyway, regardless of that, if we do take the threshold into account,
>> we should not use the exact error value for voting but just whether
>> an error occurred or not. If all but one children fail to flush (all
>&g
401 - 500 of 3600 matches
Mail list logo