From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36036) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b8us5-0001yB-Pg for qemu-devel@nongnu.org; Fri, 03 Jun 2016 15:35:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b8us3-0000Lr-SV for qemu-devel@nongnu.org; Fri, 03 Jun 2016 15:35:04 -0400 References: <1464974478-23598-1-git-send-email-kwolf@redhat.com> <1464974478-23598-4-git-send-email-kwolf@redhat.com> From: Eric Blake Message-ID: <5751DBDF.1070709@redhat.com> Date: Fri, 3 Jun 2016 13:34:55 -0600 MIME-Version: 1.0 In-Reply-To: <1464974478-23598-4-git-send-email-kwolf@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="CKLpGcTqxkotp5mwT8QMQw1C6SIbBolXl" Subject: Re: [Qemu-devel] [PATCH 3/5] qcow2: Make copy_sectors() byte based List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf , qemu-block@nongnu.org Cc: jsnow@redhat.com, qemu-devel@nongnu.org, mreitz@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --CKLpGcTqxkotp5mwT8QMQw1C6SIbBolXl Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 06/03/2016 11:21 AM, Kevin Wolf wrote: > This will allow copy on write operations where the overwritten part of > the cluster is not aligned to sector boundaries. >=20 > Signed-off-by: Kevin Wolf > --- > block/qcow2-cluster.c | 37 +++++++++++++++++-------------------- > 1 file changed, 17 insertions(+), 20 deletions(-) >=20 > diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c > index 9fb7f9f..5d04eb7 100644 > --- a/block/qcow2-cluster.c > +++ b/block/qcow2-cluster.c > @@ -391,21 +391,17 @@ int qcow2_encrypt_sectors(BDRVQcow2State *s, int6= 4_t sector_num, > } > =20 > static int coroutine_fn copy_sectors(BlockDriverState *bs, > - uint64_t start_sect, > + uint64_t src_cluster_offset, > uint64_t cluster_offset, > - int n_start, int n_end) > + int offset_in_cluster, > + int bytes) Do we still want this named copy_sectors(), now that it can copy a sub-sector (well, when not encrypted)? Otherwise, Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --CKLpGcTqxkotp5mwT8QMQw1C6SIbBolXl Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJXUdvfAAoJEKeha0olJ0Nq55IH/jiV/qfvhygLQL+xbUbYTl3q iUgizWT0VN9PI044zsq+e+Bn2sUp1S3f5D9gHjnkuj427Q5UlPLYWkhXfvie1hcE TQVKXaz9UnDc7i8oIvYpmAB11vQTn3G0yGQUBSRoMZd/tPv9F3LmlQ+yjxxTTUKJ WBPAxNvvFdedKoys6h19baMBN0LB4wG/mdh/TYOt87Neg6/S5JLPOP4Qp025i0x1 E06A8ZiEGCN3asupmteZRJl+CA98kJV5xwTWqdvxOtLs3V+mr09ONHKfgNkkckid VSqsx/Np3xlFhoZl6pUie6DBLEb4qneHRmPIA+DnOPayhxppY2Eds6RCAgfTINU= =XEx6 -----END PGP SIGNATURE----- --CKLpGcTqxkotp5mwT8QMQw1C6SIbBolXl--