mars/mars_if.h

51 lines
884 B
C
Raw Normal View History

2010-06-14 14:27:40 +00:00
// (c) 2010 Thomas Schoebel-Theuer / 1&1 Internet AG
2011-03-07 10:27:38 +00:00
#ifndef MARS_IF_H
#define MARS_IF_H
2010-06-20 18:55:34 +00:00
2010-12-10 17:40:20 +00:00
#include <linux/semaphore.h>
2010-07-05 15:56:58 +00:00
#define HT_SHIFT 6 //????
#define MARS_MAX_SEGMENT_SIZE (1U << (9+HT_SHIFT))
2010-12-10 17:40:20 +00:00
#define MAX_BIO 8
2011-03-07 10:27:38 +00:00
struct if_mref_aspect {
2010-12-15 12:13:18 +00:00
GENERIC_ASPECT(mref);
2010-12-10 17:40:20 +00:00
//struct list_head tmp_head;
struct list_head plug_head;
int maxlen;
int bio_count;
#if 1
int xxx;
int yyy;
#endif
struct page *orig_page;
struct bio *orig_bio[MAX_BIO];
2010-08-08 14:02:54 +00:00
struct generic_callback cb;
2011-03-07 10:27:38 +00:00
struct if_input *input;
2010-07-23 11:55:18 +00:00
};
2011-03-07 10:27:38 +00:00
struct if_input {
MARS_INPUT(if);
2010-12-10 17:40:20 +00:00
struct list_head plug_anchor;
2010-06-14 14:27:40 +00:00
struct request_queue *q;
struct gendisk *disk;
struct block_device *bdev;
2010-06-18 11:44:14 +00:00
spinlock_t req_lock;
2010-12-10 17:40:20 +00:00
struct semaphore kick_sem;
2010-08-05 15:54:48 +00:00
struct generic_object_layout mref_object_layout;
2010-06-14 14:27:40 +00:00
};
2011-03-07 10:27:38 +00:00
struct if_output {
MARS_OUTPUT(if);
2010-06-14 14:27:40 +00:00
};
2011-03-07 10:27:38 +00:00
struct if_brick {
MARS_BRICK(if);
struct if_output hidden_output;
2010-08-10 17:39:30 +00:00
};
2011-03-07 10:27:38 +00:00
MARS_TYPES(if);
2010-06-20 18:55:34 +00:00
#endif