- 08 6月, 2016 22 次提交
-
-
由 Fam Zheng 提交于
This is sometimes a useful value we should count in. Signed-off-by: NFam Zheng <famz@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Peter Lieven 提交于
at least bdrv_co_preadv/pwritev expect this. Signed-off-by: NPeter Lieven <pl@kamp.de> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Kevin Wolf 提交于
This creates a new BlockBackend for copying data from an images to the migration stream on the source host. All I/O for block migration goes through BlockBackend now. Signed-off-by: NKevin Wolf <kwolf@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Kevin Wolf 提交于
This converts the loading part of block migration to use BlockBackend interfaces rather than accessing the BlockDriverState directly. Note that this takes a lazy shortcut. We should really use a separate BlockBackend that is configured for the migration rather than for the guest (e.g. writethrough caching is unnecessary) and holds its own reference to the BlockDriverState, but the impact isn't that big and we didn't have a separate migration reference before either, so it must be good enough, I guess... Signed-off-by: NKevin Wolf <kwolf@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Eric Blake 提交于
Now that all drivers have been converted to a byte interface, we no longer need a sector interface. Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. Signed-off-by: NEric Blake <eblake@redhat.com> [ kwolf: Fixed up trace_paio_submit_co() call for qiov == NULL ] Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. Kill an abuse of the comma operator while at it (fortunately, the semantics were still right). Also, the test for requests not aligned to clusters should be applied always, not just when a backing file is present. Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step on our continuing quest to switch to byte-based interfaces. As this is the first byte-based iscsi interface, convert is_request_lun_aligned() into two versions, one for sectors and one for bytes. Also, change from outright -EINVAL failure on an unaligned request, to instead failing with -ENOTSUP to trigger a read-modify-write fallback, particularly since the block layer should be honoring bs->request_alignment to avoid -EINVAL on read/write requests. Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Rename to bdrv_pwrite_zeroes() to let the compiler ensure we cater to the updated semantics. Do the same for bdrv_co_write_zeroes(). Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Update bdrv_co_do_write_zeroes() to be byte-based, and select between the new byte-based bdrv_co_pwrite_zeroes() or the old bdrv_co_write_zeroes(). The next patches will convert drivers, then remove the old interface. Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Another step towards removing sector-based interfaces: convert the maximum write and minimum alignment values from sectors to bytes. Rename the variables to let the compiler check that all users are converted to the new semantics. The maximum remains an int as long as BDRV_REQUEST_MAX_SECTORS is constrained by INT_MAX (this means that we can't even support a 2G write_zeroes, but just under it) - changing operation lengths to unsigned or to 64-bits is a much bigger audit, and debatable if we even want to do it (since at the core, a 32-bit platform will still have ssize_t as its underlying limit on write()). Meanwhile, alignment is changed to 'uint32_t', since it makes no sense to have an alignment larger than the maximum write, and less painful to use an unsigned type with well-defined behavior in bit operations than to have to worry about what happens if a driver mistakenly supplies a negative alignment. Add an assert that no one was trying to use sectors to get a write zeroes larger than 2G, and therefore that a later conversion to bytes won't be impacted by keeping the limit at 32 bits. Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
If hardware does not advertise a minimum zero/discard alignment, we still want to guarantee that the block layer will align requests to our blocks, rather than the arbitrary 512-byte BDRV sector size. Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
is_zero_cluster() and is_zero_cluster_top_locked() are used only by qcow2_co_write_zeroes(). The former is too broad (we don't care if the sectors we are about to overwrite are non-zero, only that all other sectors in the cluster are zero), so it needs to be called up to twice but with smaller limits - rename it along with adding the neeeded parameter. The latter can be inlined for more compact code. The testsuite change shows that we now have a sparser top file when an unaligned write_zeroes overwrites the only portion of the backing file with data. Based on a patch proposal by Denis V. Lunev. CC: Denis V. Lunev <den@openvz.org> Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NDenis V. Lunev <den@openvz.org> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Eric Blake 提交于
Add another test to 154, showing that we currently allocate a data cluster in the top layer if any sector of the backing file was allocated. The next patch will optimize this case. Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Denis V. Lunev 提交于
This patch follows guidelines of all other tracepoints in qcow2, like ones in qcow2_co_writev. I think that they should dump values in the same quantities or be changed all together. Signed-off-by: NDenis V. Lunev <den@openvz.org> CC: Eric Blake <eblake@redhat.com> CC: Kevin Wolf <kwolf@redhat.com> Message-Id: <1463476543-3087-4-git-send-email-den@openvz.org> [eblake: typo fix in commit message] Signed-off-by: NEric Blake <eblake@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Denis V. Lunev 提交于
Unaligned requests will occupy only one cluster. This is true since the previous commit. Simplify the code taking this consideration into account. In other words, the caller is now buggy if it ever passes us an unaligned request that crosses cluster boundaries (the only requests that can cross boundaries will be aligned). There are no other changes so far. Signed-off-by: NDenis V. Lunev <den@openvz.org> Reviewed-by: NEric Blake <eblake@redhat.com> CC: Eric Blake <eblake@redhat.com> CC: Kevin Wolf <kwolf@redhat.com> Message-Id: <1463476543-3087-3-git-send-email-den@openvz.org> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
由 Denis V. Lunev 提交于
We should split requests even if they are less than write_zeroes_alignment. For example we can have the following request: offset 62k size 4k write_zeroes_alignment 64k The original code sent 1 request covering 2 qcow2 clusters, and resulted in both clusters being allocated. But by splitting the request, we can cater to the case where one of the two clusters can be zeroed as a whole, for only 1 cluster allocated after the operation. Signed-off-by: NDenis V. Lunev <den@openvz.org> CC: Eric Blake <eblake@redhat.com> CC: Kevin Wolf <kwolf@redhat.com> Message-Id: <1463476543-3087-2-git-send-email-den@openvz.org> [eblake: Avoid exceeding nb_sectors, hoist alignment checks out of loop, and update testsuite to show that patch works] Signed-off-by: NEric Blake <eblake@redhat.com> Reviewed-by: NFam Zheng <famz@redhat.com> Signed-off-by: NKevin Wolf <kwolf@redhat.com>
-
- 07 6月, 2016 18 次提交
-
-
由 Peter Maydell 提交于
trivial patches for 2016-06-07 # gpg: Signature made Tue 07 Jun 2016 16:20:52 BST # gpg: using RSA key 0xBEE59D74A4C3D7DB # gpg: Good signature from "Michael Tokarev <mjt@tls.msk.ru>" # gpg: aka "Michael Tokarev <mjt@corpit.ru>" # gpg: aka "Michael Tokarev <mjt@debian.org>" * remotes/mjt/tags/pull-trivial-patches-2016-06-07: (51 commits) hbitmap: Use DIV_ROUND_UP qemu-timer: Use DIV_ROUND_UP linux-user: Use DIV_ROUND_UP slirp: Use DIV_ROUND_UP usb: Use DIV_ROUND_UP rocker: Use DIV_ROUND_UP SPICE: Use DIV_ROUND_UP audio: Use DIV_ROUND_UP xen: Use DIV_ROUND_UP crypto: Use DIV_ROUND_UP block: Use DIV_ROUND_UP qed: Use DIV_ROUND_UP qcow/qcow2: Use DIV_ROUND_UP parallels: Use DIV_ROUND_UP coccinelle: use macro DIV_ROUND_UP instead of (((n) + (d) - 1) /(d)) thunk: Rename args and fields in host-target bitmask conversion code thunk: Drop unused NO_THUNK_TYPE_SIZE guards qemu-common.h: Drop WORDS_ALIGNED define host-utils: Prefer 'false' for bool type docs/multi-thread-compression: Fix wrong command string ... Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NJohn Snow <jsnow@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Riku Voipio <riku.voipio@iki.fi> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Samuel Thibault <samuel.thibault@ens-lyon.org> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Acked-by: NSamuel Thibault <samuel.thibault@ens-lyon.org> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Scott Feldman <sfeldma@gmail.com> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Stefano Stabellini <sstabellini@kernel.org> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NStefano Stabellini <sstabellini@kernel.org> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: Daniel P. Berrange <berrange@redhat.com> Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NDaniel P. Berrange <berrange@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Laurent Vivier 提交于
sample from http://coccinellery.org/Signed-off-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Peter Maydell 提交于
The target_to_host_bitmask() and host_to_target_bitmask() functions and the associated struct bitmask_transtbl are completely generic, but for historical reasons the target related fields and parameters are named 'x86' and the host related fields are named 'alpha'. Rename them to 'target' and 'host'. Signed-off-by: NPeter Maydell <peter.maydell@linaro.org> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-
由 Peter Maydell 提交于
The thunk_type_size_array() and thunk_type_align_array() functions are only provided if NO_THUNK_TYPE_SIZE is not defined. However nothing in the codebase defines that, and so in fact these functions are always present. Drop the unnecessary #ifdefs. (Over a decade ago thunk.h used to be included by some softmmu files, which defined NO_THUNK_TYPE_SIZE, but these includes are long gone; see for instance commit f193c797.) Signed-off-by: NPeter Maydell <peter.maydell@linaro.org> Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
-