[PATCH] qcow2: Explicit mention of padding bytes

Eric Blake posted 1 patch 11 months, 2 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20230522184631.47211-1-eblake@redhat.com
Maintainers: Kevin Wolf <kwolf@redhat.com>, Hanna Reitz <hreitz@redhat.com>
There is a newer version of this series
docs/interop/qcow2.txt | 1 +
1 file changed, 1 insertion(+)
[PATCH] qcow2: Explicit mention of padding bytes
Posted by Eric Blake 11 months, 2 weeks ago
Although we already covered the need for padding bytes with our
changes in commit 3ae3fcfa, commit 66fcbca5 (both v5.0.0) added one
byte and relied on the rest of the text for implicitly covering 7
padding bytes.  For consistency with other parts of the header (such
as the header extension format listing padding from n - m, or the
snapshot table entry listing variable padding), we might as well call
out the remaining 7 bytes as padding until such time (as any) as they
gain another meaning.

Signed-off-by: Eric Blake <eblake@redhat.com>
CC: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
---

Spring cleaning my old branches.

v3: reviving an old patch; v2 was:
https://lists.gnu.org/archive/html/qemu-devel/2020-04/msg00687.html
---
 docs/interop/qcow2.txt | 1 +
 1 file changed, 1 insertion(+)

diff --git a/docs/interop/qcow2.txt b/docs/interop/qcow2.txt
index e7f036c286b..2c4618375ad 100644
--- a/docs/interop/qcow2.txt
+++ b/docs/interop/qcow2.txt
@@ -226,6 +226,7 @@ version 2.
                     <https://www.zlib.net/> in QEMU. However, clusters with the
                     deflate compression type do not have zlib headers.

+        105 - 111:  Padding, contents defined below.

 === Header padding ===

-- 
2.40.1
Re: [PATCH] qcow2: Explicit mention of padding bytes
Posted by Vladimir Sementsov-Ogievskiy 11 months, 2 weeks ago
On 22.05.23 21:46, Eric Blake wrote:
> Although we already covered the need for padding bytes with our
> changes in commit 3ae3fcfa, commit 66fcbca5 (both v5.0.0) added one
> byte and relied on the rest of the text for implicitly covering 7
> padding bytes.  For consistency with other parts of the header (such
> as the header extension format listing padding from n - m, or the
> snapshot table entry listing variable padding), we might as well call
> out the remaining 7 bytes as padding until such time (as any) as they
> gain another meaning.
> 
> Signed-off-by: Eric Blake <eblake@redhat.com>
> CC: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>

Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>

> ---
> 
> Spring cleaning my old branches.
> 
> v3: reviving an old patch; v2 was:
> https://lists.gnu.org/archive/html/qemu-devel/2020-04/msg00687.html
> ---
>   docs/interop/qcow2.txt | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/docs/interop/qcow2.txt b/docs/interop/qcow2.txt
> index e7f036c286b..2c4618375ad 100644
> --- a/docs/interop/qcow2.txt
> +++ b/docs/interop/qcow2.txt
> @@ -226,6 +226,7 @@ version 2.
>                       <https://www.zlib.net/> in QEMU. However, clusters with the
>                       deflate compression type do not have zlib headers.
> 
> +        105 - 111:  Padding, contents defined below.
> 


-- 
Best regards,
Vladimir
Re: [PATCH] qcow2: Explicit mention of padding bytes
Posted by Eric Blake 11 months, 1 week ago
On Mon, May 22, 2023 at 11:26:03PM +0300, Vladimir Sementsov-Ogievskiy wrote:
> On 22.05.23 21:46, Eric Blake wrote:
> > Although we already covered the need for padding bytes with our
> > changes in commit 3ae3fcfa, commit 66fcbca5 (both v5.0.0) added one
> > byte and relied on the rest of the text for implicitly covering 7
> > padding bytes.  For consistency with other parts of the header (such
> > as the header extension format listing padding from n - m, or the
> > snapshot table entry listing variable padding), we might as well call
> > out the remaining 7 bytes as padding until such time (as any) as they
> > gain another meaning.
> > 
> > Signed-off-by: Eric Blake <eblake@redhat.com>
> > CC: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
> 
> Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>

Not strictly related to NBD, but I'll pick it up since I'm about to do a pull request.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org