diff options
Diffstat (limited to 'fs/exofs/exofs.h')
-rw-r--r-- | fs/exofs/exofs.h | 24 |
1 files changed, 18 insertions, 6 deletions
diff --git a/fs/exofs/exofs.h b/fs/exofs/exofs.h index 13663da2b119..33c68568b338 100644 --- a/fs/exofs/exofs.h +++ b/fs/exofs/exofs.h | |||
@@ -55,12 +55,18 @@ | |||
55 | /* u64 has problems with printk this will cast it to unsigned long long */ | 55 | /* u64 has problems with printk this will cast it to unsigned long long */ |
56 | #define _LLU(x) (unsigned long long)(x) | 56 | #define _LLU(x) (unsigned long long)(x) |
57 | 57 | ||
58 | struct exofs_layout { | ||
59 | osd_id s_pid; /* partition ID of file system*/ | ||
60 | |||
61 | unsigned s_numdevs; /* Num of devices in array */ | ||
62 | struct osd_dev *s_ods[0]; /* Variable length */ | ||
63 | }; | ||
64 | |||
58 | /* | 65 | /* |
59 | * our extension to the in-memory superblock | 66 | * our extension to the in-memory superblock |
60 | */ | 67 | */ |
61 | struct exofs_sb_info { | 68 | struct exofs_sb_info { |
62 | struct exofs_fscb s_fscb; /* Written often, pre-allocate*/ | 69 | struct exofs_fscb s_fscb; /* Written often, pre-allocate*/ |
63 | osd_id s_pid; /* partition ID of file system*/ | ||
64 | int s_timeout; /* timeout for OSD operations */ | 70 | int s_timeout; /* timeout for OSD operations */ |
65 | uint64_t s_nextid; /* highest object ID used */ | 71 | uint64_t s_nextid; /* highest object ID used */ |
66 | uint32_t s_numfiles; /* number of files on fs */ | 72 | uint32_t s_numfiles; /* number of files on fs */ |
@@ -69,9 +75,14 @@ struct exofs_sb_info { | |||
69 | atomic_t s_curr_pending; /* number of pending commands */ | 75 | atomic_t s_curr_pending; /* number of pending commands */ |
70 | uint8_t s_cred[OSD_CAP_LEN]; /* credential for the fscb */ | 76 | uint8_t s_cred[OSD_CAP_LEN]; /* credential for the fscb */ |
71 | 77 | ||
72 | struct pnfs_osd_data_map data_map; /* Default raid to use */ | 78 | struct pnfs_osd_data_map data_map; /* Default raid to use |
73 | unsigned s_numdevs; /* Num of devices in array */ | 79 | * FIXME: Needed ? |
74 | struct osd_dev *s_ods[1]; /* Variable length, minimum 1 */ | 80 | */ |
81 | /* struct exofs_layout dir_layout;*/ /* Default dir layout */ | ||
82 | struct exofs_layout layout; /* Default files layout, | ||
83 | * contains the variable osd_dev | ||
84 | * array. Keep last */ | ||
85 | struct osd_dev *_min_one_dev[1]; /* Place holder for one dev */ | ||
75 | }; | 86 | }; |
76 | 87 | ||
77 | /* | 88 | /* |
@@ -101,7 +112,7 @@ struct exofs_io_state { | |||
101 | void *private; | 112 | void *private; |
102 | exofs_io_done_fn done; | 113 | exofs_io_done_fn done; |
103 | 114 | ||
104 | struct exofs_sb_info *sbi; | 115 | struct exofs_layout *layout; |
105 | struct osd_obj_id obj; | 116 | struct osd_obj_id obj; |
106 | u8 *cred; | 117 | u8 *cred; |
107 | 118 | ||
@@ -189,7 +200,8 @@ void exofs_make_credential(u8 cred_a[OSD_CAP_LEN], | |||
189 | int exofs_read_kern(struct osd_dev *od, u8 *cred, struct osd_obj_id *obj, | 200 | int exofs_read_kern(struct osd_dev *od, u8 *cred, struct osd_obj_id *obj, |
190 | u64 offset, void *p, unsigned length); | 201 | u64 offset, void *p, unsigned length); |
191 | 202 | ||
192 | int exofs_get_io_state(struct exofs_sb_info *sbi, struct exofs_io_state** ios); | 203 | int exofs_get_io_state(struct exofs_layout *layout, |
204 | struct exofs_io_state **ios); | ||
193 | void exofs_put_io_state(struct exofs_io_state *ios); | 205 | void exofs_put_io_state(struct exofs_io_state *ios); |
194 | 206 | ||
195 | int exofs_check_io(struct exofs_io_state *ios, u64 *resid); | 207 | int exofs_check_io(struct exofs_io_state *ios, u64 *resid); |