diff options
Diffstat (limited to 'common/dnbd.h')
-rw-r--r-- | common/dnbd.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/common/dnbd.h b/common/dnbd.h new file mode 100644 index 0000000..eb8de33 --- /dev/null +++ b/common/dnbd.h @@ -0,0 +1,18 @@ +#define DNBD_MAJOR 43 +#define MAX_DNBD 32 + +struct dnbd_device { + int flags; + int harderror; /* Code of hard error */ + struct socket * sock; + struct file * file; /* If == NULL, device is not ready, yet */ + int magic; + spinlock_t queue_lock; + struct list_head queue_head;/* Requests are added here... */ + struct semaphore tx_lock; + struct gendisk *disk; + int blksize; + u64 bytesize; +}; + +typedef struct dnbd_device dnbd_device_t; |