diff options
author | Eric Blake <eblake@redhat.com> | 2016-10-14 13:33:07 -0500 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2016-11-02 09:28:55 +0100 |
commit | ed2dd91267a813e4ac5619a2fb53f55c005fcfa6 (patch) | |
tree | 1bacc4a9c5fd760451ab5ee028405990c52dad0c /include/block/nbd.h | |
parent | 10676b81a9a69e9660fc203e3fe7d61a80ef1089 (diff) |
nbd: Rename struct nbd_request and nbd_reply
Our coding convention prefers CamelCase names, and we already
have other existing structs with NBDFoo naming. Let's be
consistent, before later patches add even more structs.
Signed-off-by: Eric Blake <eblake@redhat.com>
Message-Id: <1476469998-28592-6-git-send-email-eblake@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'include/block/nbd.h')
-rw-r--r-- | include/block/nbd.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/include/block/nbd.h b/include/block/nbd.h index 5fe2670fdb..a33581b6a9 100644 --- a/include/block/nbd.h +++ b/include/block/nbd.h @@ -29,18 +29,20 @@ /* Note: these are _NOT_ the same as the network representation of an NBD * request and reply! */ -struct nbd_request { +struct NBDRequest { uint64_t handle; uint64_t from; uint32_t len; uint16_t flags; uint16_t type; }; +typedef struct NBDRequest NBDRequest; -struct nbd_reply { +struct NBDReply { uint64_t handle; uint32_t error; }; +typedef struct NBDReply NBDReply; /* Transmission (export) flags: sent from server to client during handshake, but describe what will happen during transmission */ @@ -101,8 +103,8 @@ int nbd_receive_negotiate(QIOChannel *ioc, const char *name, uint16_t *flags, QIOChannel **outioc, off_t *size, Error **errp); int nbd_init(int fd, QIOChannelSocket *sioc, uint16_t flags, off_t size); -ssize_t nbd_send_request(QIOChannel *ioc, struct nbd_request *request); -ssize_t nbd_receive_reply(QIOChannel *ioc, struct nbd_reply *reply); +ssize_t nbd_send_request(QIOChannel *ioc, NBDRequest *request); +ssize_t nbd_receive_reply(QIOChannel *ioc, NBDReply *reply); int nbd_client(int fd); int nbd_disconnect(int fd); |