* [PULL 0/1] Block patches
@ 2020-03-17 15:18 Stefan Hajnoczi
2020-03-17 15:18 ` [PULL 1/1] block/io: fix bdrv_co_do_copy_on_readv Stefan Hajnoczi
2020-03-17 18:32 ` [PULL 0/1] Block patches Peter Maydell
0 siblings, 2 replies; 3+ messages in thread
From: Stefan Hajnoczi @ 2020-03-17 15:18 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Fam Zheng, qemu-block, Peter Maydell, Max Reitz,
Stefan Hajnoczi
The following changes since commit 61c265f0660ee476985808c8aa7915617c44fd53:
Merge remote-tracking branch 'remotes/dgilbert/tags/pull-migration-20200313a' into staging (2020-03-13 10:33:04 +0000)
are available in the Git repository at:
https://github.com/stefanha/qemu.git tags/block-pull-request
for you to fetch changes up to 4ab78b19189a81038e744728ed949d09aa477550:
block/io: fix bdrv_co_do_copy_on_readv (2020-03-16 11:46:11 +0000)
----------------------------------------------------------------
Pull request
----------------------------------------------------------------
Vladimir Sementsov-Ogievskiy (1):
block/io: fix bdrv_co_do_copy_on_readv
block/io.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--
2.24.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PULL 1/1] block/io: fix bdrv_co_do_copy_on_readv
2020-03-17 15:18 [PULL 0/1] Block patches Stefan Hajnoczi
@ 2020-03-17 15:18 ` Stefan Hajnoczi
2020-03-17 18:32 ` [PULL 0/1] Block patches Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Stefan Hajnoczi @ 2020-03-17 15:18 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Fam Zheng, Vladimir Sementsov-Ogievskiy, qemu-block,
Peter Maydell, qemu-stable, Max Reitz, Stefan Hajnoczi, John Snow
From: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Prior to 1143ec5ebf4 it was OK to qemu_iovec_from_buf() from aligned-up
buffer to original qiov, as qemu_iovec_from_buf() will stop at qiov end
anyway.
But after 1143ec5ebf4 we assume that bdrv_co_do_copy_on_readv works on
part of original qiov, defined by qiov_offset and bytes. So we must not
touch qiov behind qiov_offset+bytes bound. Fix it.
Cc: qemu-stable@nongnu.org # v4.2
Fixes: 1143ec5ebf4
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Message-id: 20200312081949.5350-1-vsementsov@virtuozzo.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
block/io.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/block/io.c b/block/io.c
index 7e4cb74cf4..aba67f66b9 100644
--- a/block/io.c
+++ b/block/io.c
@@ -1399,7 +1399,7 @@ static int coroutine_fn bdrv_co_do_copy_on_readv(BdrvChild *child,
if (!(flags & BDRV_REQ_PREFETCH)) {
qemu_iovec_from_buf(qiov, qiov_offset + progress,
bounce_buffer + skip_bytes,
- pnum - skip_bytes);
+ MIN(pnum - skip_bytes, bytes - progress));
}
} else if (!(flags & BDRV_REQ_PREFETCH)) {
/* Read directly into the destination */
--
2.24.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PULL 0/1] Block patches
2020-03-17 15:18 [PULL 0/1] Block patches Stefan Hajnoczi
2020-03-17 15:18 ` [PULL 1/1] block/io: fix bdrv_co_do_copy_on_readv Stefan Hajnoczi
@ 2020-03-17 18:32 ` Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2020-03-17 18:32 UTC (permalink / raw)
To: Stefan Hajnoczi
Cc: Kevin Wolf, Fam Zheng, QEMU Developers, Qemu-block, Max Reitz
On Tue, 17 Mar 2020 at 15:18, Stefan Hajnoczi <stefanha@redhat.com> wrote:
>
> The following changes since commit 61c265f0660ee476985808c8aa7915617c44fd53:
>
> Merge remote-tracking branch 'remotes/dgilbert/tags/pull-migration-20200313a' into staging (2020-03-13 10:33:04 +0000)
>
> are available in the Git repository at:
>
> https://github.com/stefanha/qemu.git tags/block-pull-request
>
> for you to fetch changes up to 4ab78b19189a81038e744728ed949d09aa477550:
>
> block/io: fix bdrv_co_do_copy_on_readv (2020-03-16 11:46:11 +0000)
>
> ----------------------------------------------------------------
> Pull request
>
> ----------------------------------------------------------------
Applied, thanks.
Please update the changelog at https://wiki.qemu.org/ChangeLog/5.0
for any user-visible changes.
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-03-17 18:34 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-03-17 15:18 [PULL 0/1] Block patches Stefan Hajnoczi
2020-03-17 15:18 ` [PULL 1/1] block/io: fix bdrv_co_do_copy_on_readv Stefan Hajnoczi
2020-03-17 18:32 ` [PULL 0/1] Block patches Peter Maydell
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).