Revision 1d45f8b5 nbd.h
b/nbd.h | ||
---|---|---|
42 | 42 |
NBD_CMD_DISC = 2 |
43 | 43 |
}; |
44 | 44 |
|
45 |
#define NBD_DEFAULT_PORT 10809 |
|
46 |
|
|
45 | 47 |
size_t nbd_wr_sync(int fd, void *buffer, size_t size, bool do_read); |
46 | 48 |
int tcp_socket_outgoing(const char *address, uint16_t port); |
47 | 49 |
int tcp_socket_incoming(const char *address, uint16_t port); |
... | ... | |
49 | 51 |
int unix_socket_incoming(const char *path); |
50 | 52 |
|
51 | 53 |
int nbd_negotiate(int csock, off_t size); |
52 |
int nbd_receive_negotiate(int csock, off_t *size, size_t *blocksize); |
|
54 |
int nbd_receive_negotiate(int csock, const char *name, uint32_t *flags, |
|
55 |
off_t *size, size_t *blocksize); |
|
53 | 56 |
int nbd_init(int fd, int csock, off_t size, size_t blocksize); |
54 | 57 |
int nbd_send_request(int csock, struct nbd_request *request); |
55 | 58 |
int nbd_receive_reply(int csock, struct nbd_reply *reply); |
Also available in: Unified diff