From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38341) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1anTcw-0001Fv-I2 for qemu-devel@nongnu.org; Tue, 05 Apr 2016 12:14:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1anTct-0001PI-3d for qemu-devel@nongnu.org; Tue, 05 Apr 2016 12:14:50 -0400 Received: from mx1.redhat.com ([209.132.183.28]:46069) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1anTcs-0001PE-Re for qemu-devel@nongnu.org; Tue, 05 Apr 2016 12:14:47 -0400 References: <1459870219-15938-1-git-send-email-alex@alex.org.uk> From: Eric Blake Message-ID: <5703E474.8030906@redhat.com> Date: Tue, 5 Apr 2016 10:14:44 -0600 MIME-Version: 1.0 In-Reply-To: <1459870219-15938-1-git-send-email-alex@alex.org.uk> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="LkQFg3gPsNh5bkJMq6idutVLhdrLDhh9J" Subject: Re: [Qemu-devel] [PATCHv4] Improve the documentation of NBD_CMD_FLUSH and NBD_CMD_FLAG_FUA. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alex Bligh , Wouter Verhelst Cc: "nbd-general@lists.sourceforge.net" , "qemu-devel@nongnu.org" This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --LkQFg3gPsNh5bkJMq6idutVLhdrLDhh9J Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 04/05/2016 09:30 AM, Alex Bligh wrote: > Improve the documentation of NBD_CMD_FLUSH and NBD_CMD_FLAG_FUA. Specif= ically > the latter may be set on any command, and its semantics on commands oth= er > than NBD_CMD_WRITE need explaining. Further, explain how these relate t= o > reordering of commands. >=20 > Signed-off-by: Alex Bligh > --- > doc/proto.md | 59 ++++++++++++++++++++++++++++++++++++++++++++--------= ------- > 1 file changed, 44 insertions(+), 15 deletions(-) >=20 > =20 > -- bit 0, `NBD_CMD_FLAG_FUA`; valid during `NBD_CMD_WRITE` and > - `NBD_CMD_WRITE_ZEROES` commands. SHOULD be set to 1 if the client r= equires > - "Force Unit Access" mode of operation. MUST NOT be set unless trans= mission > - flags included `NBD_FLAG_SEND_FUA`. > +- bit 0, `NBD_CMD_FLAG_FUA`; This flag is valid for all commands, prov= ided > + `NBD_FLAG_SEND_FUA` has been negotiated, in which case the server MU= ST > + accept all commands with this bit set (even by ignoring the bit). Th= e > + client SHOULD NOT set this bit unless the command has the potential = of > + writing data (current commands are `NBD_CMD_WRITE`, `NBD_CMD_WRITE_Z= EROES` > + and `NBD_CMD_TRIM`), however note that existing clients are known to= set this > + bit on other commands. Subject to that, and provided `NBD_FLAG_SEND_= FUA` > + is negotiated, the client MAY set this bit on all, no or some comman= ds > + as it wishes (see the section on Ordering of messages and writes for= > + details). If the server receives a command with `NBD_CMD_FLAG_FUA` > + set it MUST NOT send its reply to that command until all write > + operations (if any) associated with that command command have been s/command command/command/ > + completed and persisted to non-volatile storage. If the command does= > + not in fact write data (for instance on an `NBD_CMD_TRIM` in a situa= tion > + where the command as a whole is ignored), the server MAY ignore this= bit > + being set on such a command. With the duplicate word removed, Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --LkQFg3gPsNh5bkJMq6idutVLhdrLDhh9J 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/ iQEcBAEBCAAGBQJXA+R1AAoJEKeha0olJ0NqSu0H+wdmI45mncGJi916OPLWzIuB F9sPGR7ZgT42dtGA7WhsY7dEkCKa1hX96mkj9C8CQHULGEc4mLvZ4tOHE84Asn05 gvWugtyA3VkyO6IeB9mu8yebkX4NInKYZVTg+O3p6L0TVbTc9zmOEMwramBEFY2V vFAGdC2VxDuIrCgBUtS9GAGkCqbWVJ/KIZTKFEumUIbCnDVWW0ZHvaIIrWnaPE2e PppBTgwh5iuLKy1axKgr/L1n6ve9P0hp3en6M+NRqV+4Fr8cYlxHNIw4dvPg7KBi zMvq3WyPgrNmlUj+SLi1SyPSLr3u2ah9OYPyPz/nDjM3e49g60LHLqZ+jgxqrb8= =mOKN -----END PGP SIGNATURE----- --LkQFg3gPsNh5bkJMq6idutVLhdrLDhh9J--