From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39379) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDJVK-0006we-Lh for qemu-devel@nongnu.org; Mon, 19 Jan 2015 16:04:59 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YDJVH-0007J6-CW for qemu-devel@nongnu.org; Mon, 19 Jan 2015 16:04:58 -0500 Received: from mx1.redhat.com ([209.132.183.28]:58843) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDJVH-0007Iw-5R for qemu-devel@nongnu.org; Mon, 19 Jan 2015 16:04:55 -0500 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t0JL4qM7030724 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Mon, 19 Jan 2015 16:04:53 -0500 Message-ID: <54BD7173.7060901@redhat.com> Date: Mon, 19 Jan 2015 14:04:51 -0700 From: Eric Blake MIME-Version: 1.0 References: <1421700544-24635-1-git-send-email-mreitz@redhat.com> In-Reply-To: <1421700544-24635-1-git-send-email-mreitz@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="KDqwM0jrsnRS8oAR2KtSq7v5b7k4qxD85" Subject: Re: [Qemu-devel] [PATCH 0/2] qcow2: Add two more unalignment checks List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz , qemu-devel@nongnu.org Cc: Kevin Wolf , Stefan Hajnoczi This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --KDqwM0jrsnRS8oAR2KtSq7v5b7k4qxD85 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 01/19/2015 01:49 PM, Max Reitz wrote: > With the series adding unalignment checks and the series reworking the > zero cluster expansion code overlapping, the unalignment checks have no= t > been implemented in the latter code. >=20 > This series fixes it. >=20 > There are other places which would require unalignment checks, like the= > offsets of L1 tables, especially for snapshots; but because it would be= > best to add these checks in the function which reads the snapshot table= , > this would make images with broken snapshots completely unusable, which= > is something I opted to avoid for now. >=20 > Ideally, we need to make the qcow2 repair function repair such cases, > but until that is done there is not much we can do about them. What's the best repair? Read the data from the unaligned location, and write a fresh copy into a new aligned allocation? At any rate, I agree that repairing unaligned locations is harder than detecting them, so your series is fine as is. Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --KDqwM0jrsnRS8oAR2KtSq7v5b7k4qxD85 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJUvXFzAAoJEKeha0olJ0NqZDMH+wdnDySQI6DB3zyi4dCPxKQM zcAcEgpP08Ifb8iSJRosU4sfbgLGXZ0aff6Li1cOezEk8LSnqfoPNyFacx2JPqot U6DHbGvbA60Yz0OHTcvK7ieAwdMgRG5eZ9zJeSQStaQU8ASiLplH+0XG89bTorFP 0p2GFUc28fQwwiHgRTghRBK5gXdrOOjZk6wWwSIZ58TEGQfMZP1f394irDc2HqZ0 PTTHwE3cn5w9K6Fsmu+bRX7dw/qlCVKFR9LTfFGbOC4BNScNMUtPU909mnQLBvWy Weic15lQ0VJGlECRirYeJIvY2ZdYJL1s++gEKjvvdMBz0veAbOIqsfolvRH+B8A= =XPzi -----END PGP SIGNATURE----- --KDqwM0jrsnRS8oAR2KtSq7v5b7k4qxD85--