Go to the documentation of this file.
15 #ifndef _UAPILINUX_NBD_H
16 #define _UAPILINUX_NBD_H
18 #include <linux/types.h>
20 #define NBD_SET_SOCK _IO( 0xab, 0 )
21 #define NBD_SET_BLKSIZE _IO( 0xab, 1 )
22 #define NBD_SET_SIZE _IO( 0xab, 2 )
23 #define NBD_DO_IT _IO( 0xab, 3 )
24 #define NBD_CLEAR_SOCK _IO( 0xab, 4 )
25 #define NBD_CLEAR_QUE _IO( 0xab, 5 )
26 #define NBD_PRINT_DEBUG _IO( 0xab, 6 )
27 #define NBD_SET_SIZE_BLOCKS _IO( 0xab, 7 )
28 #define NBD_DISCONNECT _IO( 0xab, 8 )
29 #define NBD_SET_TIMEOUT _IO( 0xab, 9 )
30 #define NBD_SET_FLAGS _IO( 0xab, 10)
41 #define NBD_FLAG_HAS_FLAGS (1 << 0)
42 #define NBD_FLAG_READ_ONLY (1 << 1)
44 #define NBD_FLAG_SEND_TRIM (1 << 5)
46 #define nbd_cmd(req) ((req)->cmd[0])
52 #define NBD_REQUEST_MAGIC 0x25609513
53 #define NBD_REPLY_MAGIC 0x67446698