]> git.ipfire.org Git - thirdparty/qemu.git/commit
mirror: Only mirror granularity-aligned chunks
authorMax Reitz <mreitz@redhat.com>
Mon, 5 Aug 2019 15:33:08 +0000 (17:33 +0200)
committerMax Reitz <mreitz@redhat.com>
Tue, 6 Aug 2019 11:17:25 +0000 (13:17 +0200)
commit9adc1cb49af8d4e54f57980b1eed5c0a4b2dafa6
treee29390ef616214a461ab982c319dbce173e6a332
parent8a9cb864086269af14bbd13f395472703cf99f8c
mirror: Only mirror granularity-aligned chunks

In write-blocking mode, all writes to the top node directly go to the
target.  We must only mirror chunks of data that are aligned to the
job's granularity, because that is how the dirty bitmap works.
Therefore, the request alignment for writes must be the job's
granularity (in write-blocking mode).

Unfortunately, this forces all reads and writes to have the same
granularity (we only need this alignment for writes to the target, not
the source), but that is something to be fixed another time.

Cc: qemu-stable@nongnu.org
Signed-off-by: Max Reitz <mreitz@redhat.com>
Message-id: 20190805153308.2657-1-mreitz@redhat.com
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Fixes: d06107ade0ce74dc39739bac80de84b51ec18546
Signed-off-by: Max Reitz <mreitz@redhat.com>
block/mirror.c