qemu-e2k/include
Vladimir Sementsov-Ogievskiy 7e032df0ea block/block-copy: add ratelimit to block-copy
We are going to directly use one async block-copy operation for backup
job, so we need rate limiter.

We want to maintain current backup behavior: only background copying is
limited and copy-before-write operations only participate in limit
calculation. Therefore we need one rate limiter for block-copy state
and boolean flag for block-copy call state for actual limitation.

Note, that we can't just calculate each chunk in limiter after
successful copying: it will not save us from starting a lot of async
sub-requests which will exceed limit too much. Instead let's use the
following scheme on sub-request creation:
1. If at the moment limit is not exceeded, create the request and
account it immediately.
2. If at the moment limit is already exceeded, drop create sub-request
and handle limit instead (by sleep).
With this approach we'll never exceed the limit more than by one
sub-request (which pretty much matches current backup behavior).

Note also, that if there is in-flight block-copy async call,
block_copy_kick() should be used after set-speed to apply new setup
faster. For that block_copy_kick() published in this patch.

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Message-Id: <20210116214705.822267-7-vsementsov@virtuozzo.com>
Signed-off-by: Max Reitz <mreitz@redhat.com>
2021-01-26 14:36:37 +01:00
..
authz authz: Fix Lesser GPL version number 2020-10-29 09:57:37 +00:00
block block/block-copy: add ratelimit to block-copy 2021-01-26 14:36:37 +01:00
chardev chardev: do not use machine_init_done 2020-12-15 12:51:51 -05:00
crypto
disas disas: Push const down through host disassembly 2021-01-07 05:09:42 -10:00
exec accel/tcg: Restrict cpu_io_recompile() from other accelerators 2021-01-23 12:13:00 -10:00
fpu
hw hw/sd: sd.h: Cosmetic change of using spaces 2021-01-24 20:11:05 +01:00
io io: Document qmp oob suitability of qio_channel_shutdown and io_shutdown 2021-01-13 10:21:17 +01:00
libdecnumber
migration migration: Replace migration's JSON writer by the general one 2020-12-19 10:39:16 +01:00
monitor sev: add sev-inject-launch-secret 2020-12-10 17:33:17 -05:00
net net: checksum: Introduce fine control over checksum type 2021-01-25 17:04:56 +08:00
qapi qobject: Make QString immutable 2020-12-19 10:39:41 +01:00
qemu SD/MMC patches 2021-01-25 11:52:00 +00:00
qom
scsi scsi/utils: Add INVALID_PARAM_VALUE sense code definition 2021-01-22 14:51:35 +01:00
standard-headers Update linux headers to 5.11-rc2 2021-01-21 11:19:45 +01:00
sysemu whpx: move internal definitions to whpx-internal.h 2021-01-12 12:38:03 +01:00
tcg tcg: Restart code generation when we run out of temps 2021-01-24 08:03:27 -10:00
ui vnc: support "-vnc help" 2021-01-23 15:55:07 -05:00
user
elf.h target-arm queue: 2020-10-29 11:40:04 +00:00
glib-compat.h glib-compat: add g_unix_get_passwd_entry_qemu() 2020-11-02 19:52:08 -06:00
qemu-common.h vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
qemu-io.h
trace-tcg.h