From: Eric Blake <eblake@redhat.com>
To: Alex Bligh <alex@alex.org.uk>, Wouter Verhelst <w@uter.be>
Cc: "nbd-general@lists.sourceforge.net"
<nbd-general@lists.sourceforge.net>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH 1/2] proto.md: Clearly set out NBDMAGIC is the actual value
Date: Thu, 31 Mar 2016 13:08:55 -0600 [thread overview]
Message-ID: <56FD75C7.107@redhat.com> (raw)
In-Reply-To: <1459448124-52318-1-git-send-email-alex@alex.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1597 bytes --]
On 03/31/2016 12:15 PM, Alex Bligh wrote:
> Clearly set out NBDMAGIC, not the name of a constant equal to
> some value. Set out the value in hex as well.
>
> Signed-off-by: Alex Bligh <alex@alex.org.uk>
> ---
> doc/proto.md | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/doc/proto.md b/doc/proto.md
> index c1e05c5..7994076 100644
> --- a/doc/proto.md
> +++ b/doc/proto.md
> @@ -67,7 +67,7 @@ newstyle negotiation.
>
> #### Oldstyle negotiation
>
> -S: 64 bits, `NBDMAGIC` (also known as the `INIT_PASSWD`)
> +S: 64 bits, `0x4e42444d41474943` (ASCII '`NBDMAGIC`') (also known as the `INIT_PASSWD`)
> S: 64 bits, `0x00420281861253` (`cliserv_magic`, a magic number)
> S: 64 bits, size of the export in bytes (unsigned)
> S: 32 bits, flags
> @@ -96,7 +96,7 @@ production purposes.
>
> The initial few exchanges in newstyle negotiation look as follows:
>
> -S: 64 bits, `NBDMAGIC` (as in the old style handshake)
> +S: 64 bits, `0x4e42444d41474943` (ASCII '`NBDMAGIC`') (as in the old style handshake)
Markdown doesn't care, but the rest of this file is less than 80
columns, making this a long line. You can wrap it (see how I wrapped
the line regarding 124 bytes of zeroes in response to NBD_OPT_EXPORT_NAME).
> S: 64 bits, `0x49484156454F5054` (note different magic number)
As long as we are spelling out ASCII counterpart, is it worth mentioning
that this is (ASCII `'IHAVEOPT'`)?
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 604 bytes --]
prev parent reply other threads:[~2016-03-31 19:09 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-31 18:15 [Qemu-devel] [PATCH 1/2] proto.md: Clearly set out NBDMAGIC is the actual value Alex Bligh
2016-03-31 19:08 ` Eric Blake [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=56FD75C7.107@redhat.com \
--to=eblake@redhat.com \
--cc=alex@alex.org.uk \
--cc=nbd-general@lists.sourceforge.net \
--cc=qemu-devel@nongnu.org \
--cc=w@uter.be \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.