3 #include <linux/lustre_lib.h>
4 #include <linux/lustre_idl.h>
8 #define LASSERT(cond) if (!(cond)) { printf("failed " #cond "\n"); ret = 1; }
9 #define LASSERTF(cond, fmt, arg) if (!(cond)) { printf("failed '" #cond "'" fmt, arg);ret = 1;}
13 void lustre_assert_wire_constants(void);
17 lustre_assert_wire_constants();
20 printf("wire constants OK\n");
25 void lustre_assert_wire_constants(void)
27 /* Wire protocol assertions generated by 'wirecheck'
28 * running on Linux localhost.localdomain 2.6.12-1.1372_FC3 #1 Fri Jul 15 00:59:10 EDT 2005 i
29 * with gcc version 3.4.3 20050227 (Red Hat 3.4.3-22.fc3) */
33 LASSERTF(PTLRPC_MSG_MAGIC == 0x0BD00BD0," found %lld\n",
34 (long long)PTLRPC_MSG_MAGIC);
35 LASSERTF(PTLRPC_MSG_VERSION == 0x00000003," found %lld\n",
36 (long long)PTLRPC_MSG_VERSION);
37 LASSERTF(PTL_RPC_MSG_REQUEST == 4711, " found %llu\n",
38 (unsigned long long)PTL_RPC_MSG_REQUEST);
39 LASSERTF(PTL_RPC_MSG_ERR == 4712, " found %llu\n",
40 (unsigned long long)PTL_RPC_MSG_ERR);
41 LASSERTF(PTL_RPC_MSG_REPLY == 4713, " found %llu\n",
42 (unsigned long long)PTL_RPC_MSG_REPLY);
43 LASSERTF(MSG_LAST_REPLAY == 1, " found %llu\n",
44 (unsigned long long)MSG_LAST_REPLAY);
45 LASSERTF(MSG_RESENT == 2, " found %llu\n",
46 (unsigned long long)MSG_RESENT);
47 LASSERTF(MSG_REPLAY == 4, " found %llu\n",
48 (unsigned long long)MSG_REPLAY);
49 LASSERTF(MSG_CONNECT_RECOVERING == 1, " found %llu\n",
50 (unsigned long long)MSG_CONNECT_RECOVERING);
51 LASSERTF(MSG_CONNECT_RECONNECT == 2, " found %llu\n",
52 (unsigned long long)MSG_CONNECT_RECONNECT);
53 LASSERTF(MSG_CONNECT_REPLAYABLE == 4, " found %llu\n",
54 (unsigned long long)MSG_CONNECT_REPLAYABLE);
55 LASSERTF(OST_REPLY == 0, " found %llu\n",
56 (unsigned long long)OST_REPLY);
57 LASSERTF(OST_GETATTR == 1, " found %llu\n",
58 (unsigned long long)OST_GETATTR);
59 LASSERTF(OST_SETATTR == 2, " found %llu\n",
60 (unsigned long long)OST_SETATTR);
61 LASSERTF(OST_READ == 3, " found %llu\n",
62 (unsigned long long)OST_READ);
63 LASSERTF(OST_WRITE == 4, " found %llu\n",
64 (unsigned long long)OST_WRITE);
65 LASSERTF(OST_CREATE == 5, " found %llu\n",
66 (unsigned long long)OST_CREATE);
67 LASSERTF(OST_DESTROY == 6, " found %llu\n",
68 (unsigned long long)OST_DESTROY);
69 LASSERTF(OST_GET_INFO == 7, " found %llu\n",
70 (unsigned long long)OST_GET_INFO);
71 LASSERTF(OST_CONNECT == 8, " found %llu\n",
72 (unsigned long long)OST_CONNECT);
73 LASSERTF(OST_DISCONNECT == 9, " found %llu\n",
74 (unsigned long long)OST_DISCONNECT);
75 LASSERTF(OST_PUNCH == 10, " found %llu\n",
76 (unsigned long long)OST_PUNCH);
77 LASSERTF(OST_OPEN == 11, " found %llu\n",
78 (unsigned long long)OST_OPEN);
79 LASSERTF(OST_CLOSE == 12, " found %llu\n",
80 (unsigned long long)OST_CLOSE);
81 LASSERTF(OST_STATFS == 13, " found %llu\n",
82 (unsigned long long)OST_STATFS);
83 LASSERTF(OST_SAN_READ == 14, " found %llu\n",
84 (unsigned long long)OST_SAN_READ);
85 LASSERTF(OST_SAN_WRITE == 15, " found %llu\n",
86 (unsigned long long)OST_SAN_WRITE);
87 LASSERTF(OST_SYNC == 16, " found %llu\n",
88 (unsigned long long)OST_SYNC);
89 LASSERTF(OST_LAST_OPC == 18, " found %llu\n",
90 (unsigned long long)OST_LAST_OPC);
91 LASSERTF(OBD_OBJECT_EOF == 0xffffffffffffffffULL," found %lld\n",
92 (long long)OBD_OBJECT_EOF);
93 LASSERTF(OST_REQ_HAS_OA1 == 1, " found %llu\n",
94 (unsigned long long)OST_REQ_HAS_OA1);
95 LASSERTF(MDS_GETATTR == 33, " found %llu\n",
96 (unsigned long long)MDS_GETATTR);
97 LASSERTF(MDS_GETATTR_LOCK == 34, " found %llu\n",
98 (unsigned long long)MDS_GETATTR_LOCK);
99 LASSERTF(MDS_CLOSE == 35, " found %llu\n",
100 (unsigned long long)MDS_CLOSE);
101 LASSERTF(MDS_REINT == 36, " found %llu\n",
102 (unsigned long long)MDS_REINT);
103 LASSERTF(MDS_READPAGE == 37, " found %llu\n",
104 (unsigned long long)MDS_READPAGE);
105 LASSERTF(MDS_CONNECT == 38, " found %llu\n",
106 (unsigned long long)MDS_CONNECT);
107 LASSERTF(MDS_DISCONNECT == 39, " found %llu\n",
108 (unsigned long long)MDS_DISCONNECT);
109 LASSERTF(MDS_GETSTATUS == 40, " found %llu\n",
110 (unsigned long long)MDS_GETSTATUS);
111 LASSERTF(MDS_STATFS == 41, " found %llu\n",
112 (unsigned long long)MDS_STATFS);
113 LASSERTF(MDS_PIN == 42, " found %llu\n",
114 (unsigned long long)MDS_PIN);
115 LASSERTF(MDS_UNPIN == 43, " found %llu\n",
116 (unsigned long long)MDS_UNPIN);
117 LASSERTF(MDS_SYNC == 44, " found %llu\n",
118 (unsigned long long)MDS_SYNC);
119 LASSERTF(MDS_DONE_WRITING == 45, " found %llu\n",
120 (unsigned long long)MDS_DONE_WRITING);
121 LASSERTF(MDS_ACCESS_CHECK == 46, " found %llu\n",
122 (unsigned long long)MDS_ACCESS_CHECK);
123 LASSERTF(MDS_PARSE_ID == 47, " found %llu\n",
124 (unsigned long long)MDS_PARSE_ID);
125 LASSERTF(MDS_LAST_OPC == 48, " found %llu\n",
126 (unsigned long long)MDS_LAST_OPC);
127 LASSERTF(REINT_SETATTR == 1, " found %llu\n",
128 (unsigned long long)REINT_SETATTR);
129 LASSERTF(REINT_CREATE == 2, " found %llu\n",
130 (unsigned long long)REINT_CREATE);
131 LASSERTF(REINT_LINK == 3, " found %llu\n",
132 (unsigned long long)REINT_LINK);
133 LASSERTF(REINT_UNLINK == 4, " found %llu\n",
134 (unsigned long long)REINT_UNLINK);
135 LASSERTF(REINT_RENAME == 5, " found %llu\n",
136 (unsigned long long)REINT_RENAME);
137 LASSERTF(REINT_OPEN == 7, " found %llu\n",
138 (unsigned long long)REINT_OPEN);
139 LASSERTF(REINT_MAX == 9, " found %llu\n",
140 (unsigned long long)REINT_MAX);
141 LASSERTF(DISP_IT_EXECD == 1, " found %llu\n",
142 (unsigned long long)DISP_IT_EXECD);
143 LASSERTF(DISP_LOOKUP_EXECD == 2, " found %llu\n",
144 (unsigned long long)DISP_LOOKUP_EXECD);
145 LASSERTF(DISP_LOOKUP_NEG == 4, " found %llu\n",
146 (unsigned long long)DISP_LOOKUP_NEG);
147 LASSERTF(DISP_LOOKUP_POS == 8, " found %llu\n",
148 (unsigned long long)DISP_LOOKUP_POS);
149 LASSERTF(DISP_OPEN_CREATE == 16, " found %llu\n",
150 (unsigned long long)DISP_OPEN_CREATE);
151 LASSERTF(DISP_OPEN_OPEN == 32, " found %llu\n",
152 (unsigned long long)DISP_OPEN_OPEN);
153 LASSERTF(MDS_STATUS_CONN == 1, " found %llu\n",
154 (unsigned long long)MDS_STATUS_CONN);
155 LASSERTF(MDS_STATUS_LOV == 2, " found %llu\n",
156 (unsigned long long)MDS_STATUS_LOV);
157 LASSERTF(MDS_OPEN_HAS_EA == 1073741824, " found %llu\n",
158 (unsigned long long)MDS_OPEN_HAS_EA);
159 LASSERTF(LDLM_ENQUEUE == 101, " found %llu\n",
160 (unsigned long long)LDLM_ENQUEUE);
161 LASSERTF(LDLM_CONVERT == 102, " found %llu\n",
162 (unsigned long long)LDLM_CONVERT);
163 LASSERTF(LDLM_CANCEL == 103, " found %llu\n",
164 (unsigned long long)LDLM_CANCEL);
165 LASSERTF(LDLM_BL_CALLBACK == 104, " found %llu\n",
166 (unsigned long long)LDLM_BL_CALLBACK);
167 LASSERTF(LDLM_CP_CALLBACK == 105, " found %llu\n",
168 (unsigned long long)LDLM_CP_CALLBACK);
169 LASSERTF(LDLM_FLK_DEADLOCK_CHK == 107, " found %llu\n",
170 (unsigned long long)LDLM_FLK_DEADLOCK_CHK);
171 LASSERTF(LDLM_LAST_OPC == 108, " found %llu\n",
172 (unsigned long long)LDLM_LAST_OPC);
173 LASSERTF(LCK_EX == 1, " found %llu\n",
174 (unsigned long long)LCK_EX);
175 LASSERTF(LCK_PW == 2, " found %llu\n",
176 (unsigned long long)LCK_PW);
177 LASSERTF(LCK_PR == 4, " found %llu\n",
178 (unsigned long long)LCK_PR);
179 LASSERTF(LCK_CW == 8, " found %llu\n",
180 (unsigned long long)LCK_CW);
181 LASSERTF(LCK_CR == 16, " found %llu\n",
182 (unsigned long long)LCK_CR);
183 LASSERTF(LCK_NL == 32, " found %llu\n",
184 (unsigned long long)LCK_NL);
185 LASSERTF(PTLBD_QUERY == 200, " found %llu\n",
186 (unsigned long long)PTLBD_QUERY);
187 LASSERTF(PTLBD_READ == 201, " found %llu\n",
188 (unsigned long long)PTLBD_READ);
189 LASSERTF(PTLBD_WRITE == 202, " found %llu\n",
190 (unsigned long long)PTLBD_WRITE);
191 LASSERTF(PTLBD_FLUSH == 203, " found %llu\n",
192 (unsigned long long)PTLBD_FLUSH);
193 LASSERTF(PTLBD_CONNECT == 204, " found %llu\n",
194 (unsigned long long)PTLBD_CONNECT);
195 LASSERTF(PTLBD_DISCONNECT == 205, " found %llu\n",
196 (unsigned long long)PTLBD_DISCONNECT);
197 LASSERTF(PTLBD_LAST_OPC == 206, " found %llu\n",
198 (unsigned long long)PTLBD_LAST_OPC);
199 LASSERTF(MGMT_CONNECT == 250, " found %llu\n",
200 (unsigned long long)MGMT_CONNECT);
201 LASSERTF(MGMT_DISCONNECT == 251, " found %llu\n",
202 (unsigned long long)MGMT_DISCONNECT);
203 LASSERTF(MGMT_EXCEPTION == 252, " found %llu\n",
204 (unsigned long long)MGMT_EXCEPTION);
205 LASSERTF(OBD_PING == 400, " found %llu\n",
206 (unsigned long long)OBD_PING);
207 LASSERTF(OBD_LOG_CANCEL == 401, " found %llu\n",
208 (unsigned long long)OBD_LOG_CANCEL);
209 LASSERTF(OBD_LAST_OPC == 402, " found %llu\n",
210 (unsigned long long)OBD_LAST_OPC);
211 /* Sizes and Offsets */
214 /* Checks for struct lustre_handle */
215 LASSERTF((int)sizeof(struct lustre_handle) == 8, " found %llu\n",
216 (unsigned long long)(int)sizeof(struct lustre_handle));
217 LASSERTF((int)offsetof(struct lustre_handle, cookie) == 0, " found %llu\n",
218 (unsigned long long)(int)offsetof(struct lustre_handle, cookie));
219 LASSERTF((int)sizeof(((struct lustre_handle *)0)->cookie) == 8, " found %llu\n",
220 (unsigned long long)(int)sizeof(((struct lustre_handle *)0)->cookie));
222 /* Checks for struct lustre_msg */
223 LASSERTF((int)sizeof(struct lustre_msg) == 64, " found %llu\n",
224 (unsigned long long)(int)sizeof(struct lustre_msg));
225 LASSERTF((int)offsetof(struct lustre_msg, handle) == 0, " found %llu\n",
226 (unsigned long long)(int)offsetof(struct lustre_msg, handle));
227 LASSERTF((int)sizeof(((struct lustre_msg *)0)->handle) == 8, " found %llu\n",
228 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->handle));
229 LASSERTF((int)offsetof(struct lustre_msg, magic) == 8, " found %llu\n",
230 (unsigned long long)(int)offsetof(struct lustre_msg, magic));
231 LASSERTF((int)sizeof(((struct lustre_msg *)0)->magic) == 4, " found %llu\n",
232 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->magic));
233 LASSERTF((int)offsetof(struct lustre_msg, type) == 12, " found %llu\n",
234 (unsigned long long)(int)offsetof(struct lustre_msg, type));
235 LASSERTF((int)sizeof(((struct lustre_msg *)0)->type) == 4, " found %llu\n",
236 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->type));
237 LASSERTF((int)offsetof(struct lustre_msg, version) == 16, " found %llu\n",
238 (unsigned long long)(int)offsetof(struct lustre_msg, version));
239 LASSERTF((int)sizeof(((struct lustre_msg *)0)->version) == 4, " found %llu\n",
240 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->version));
241 LASSERTF((int)offsetof(struct lustre_msg, opc) == 20, " found %llu\n",
242 (unsigned long long)(int)offsetof(struct lustre_msg, opc));
243 LASSERTF((int)sizeof(((struct lustre_msg *)0)->opc) == 4, " found %llu\n",
244 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->opc));
245 LASSERTF((int)offsetof(struct lustre_msg, last_xid) == 24, " found %llu\n",
246 (unsigned long long)(int)offsetof(struct lustre_msg, last_xid));
247 LASSERTF((int)sizeof(((struct lustre_msg *)0)->last_xid) == 8, " found %llu\n",
248 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->last_xid));
249 LASSERTF((int)offsetof(struct lustre_msg, last_committed) == 32, " found %llu\n",
250 (unsigned long long)(int)offsetof(struct lustre_msg, last_committed));
251 LASSERTF((int)sizeof(((struct lustre_msg *)0)->last_committed) == 8, " found %llu\n",
252 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->last_committed));
253 LASSERTF((int)offsetof(struct lustre_msg, transno) == 40, " found %llu\n",
254 (unsigned long long)(int)offsetof(struct lustre_msg, transno));
255 LASSERTF((int)sizeof(((struct lustre_msg *)0)->transno) == 8, " found %llu\n",
256 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->transno));
257 LASSERTF((int)offsetof(struct lustre_msg, status) == 48, " found %llu\n",
258 (unsigned long long)(int)offsetof(struct lustre_msg, status));
259 LASSERTF((int)sizeof(((struct lustre_msg *)0)->status) == 4, " found %llu\n",
260 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->status));
261 LASSERTF((int)offsetof(struct lustre_msg, flags) == 52, " found %llu\n",
262 (unsigned long long)(int)offsetof(struct lustre_msg, flags));
263 LASSERTF((int)sizeof(((struct lustre_msg *)0)->flags) == 4, " found %llu\n",
264 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->flags));
265 LASSERTF((int)offsetof(struct lustre_msg, bufcount) == 60, " found %llu\n",
266 (unsigned long long)(int)offsetof(struct lustre_msg, bufcount));
267 LASSERTF((int)sizeof(((struct lustre_msg *)0)->bufcount) == 4, " found %llu\n",
268 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->bufcount));
269 LASSERTF((int)offsetof(struct lustre_msg, buflens[7]) == 92, " found %llu\n",
270 (unsigned long long)(int)offsetof(struct lustre_msg, buflens[7]));
271 LASSERTF((int)sizeof(((struct lustre_msg *)0)->buflens[7]) == 4, " found %llu\n",
272 (unsigned long long)(int)sizeof(((struct lustre_msg *)0)->buflens[7]));
274 /* Checks for struct obdo */
275 LASSERTF((int)sizeof(struct obdo) == 204, " found %llu\n",
276 (unsigned long long)(int)sizeof(struct obdo));
277 LASSERTF((int)offsetof(struct obdo, o_id) == 0, " found %llu\n",
278 (unsigned long long)(int)offsetof(struct obdo, o_id));
279 LASSERTF((int)sizeof(((struct obdo *)0)->o_id) == 8, " found %llu\n",
280 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_id));
281 LASSERTF((int)offsetof(struct obdo, o_gr) == 8, " found %llu\n",
282 (unsigned long long)(int)offsetof(struct obdo, o_gr));
283 LASSERTF((int)sizeof(((struct obdo *)0)->o_gr) == 8, " found %llu\n",
284 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_gr));
285 LASSERTF((int)offsetof(struct obdo, o_atime) == 32, " found %llu\n",
286 (unsigned long long)(int)offsetof(struct obdo, o_atime));
287 LASSERTF((int)sizeof(((struct obdo *)0)->o_atime) == 8, " found %llu\n",
288 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_atime));
289 LASSERTF((int)offsetof(struct obdo, o_mtime) == 24, " found %llu\n",
290 (unsigned long long)(int)offsetof(struct obdo, o_mtime));
291 LASSERTF((int)sizeof(((struct obdo *)0)->o_mtime) == 8, " found %llu\n",
292 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_mtime));
293 LASSERTF((int)offsetof(struct obdo, o_ctime) == 40, " found %llu\n",
294 (unsigned long long)(int)offsetof(struct obdo, o_ctime));
295 LASSERTF((int)sizeof(((struct obdo *)0)->o_ctime) == 8, " found %llu\n",
296 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_ctime));
297 LASSERTF((int)offsetof(struct obdo, o_size) == 16, " found %llu\n",
298 (unsigned long long)(int)offsetof(struct obdo, o_size));
299 LASSERTF((int)sizeof(((struct obdo *)0)->o_size) == 8, " found %llu\n",
300 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_size));
301 LASSERTF((int)offsetof(struct obdo, o_blocks) == 48, " found %llu\n",
302 (unsigned long long)(int)offsetof(struct obdo, o_blocks));
303 LASSERTF((int)sizeof(((struct obdo *)0)->o_blocks) == 8, " found %llu\n",
304 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_blocks));
305 LASSERTF((int)offsetof(struct obdo, o_grant) == 56, " found %llu\n",
306 (unsigned long long)(int)offsetof(struct obdo, o_grant));
307 LASSERTF((int)sizeof(((struct obdo *)0)->o_grant) == 8, " found %llu\n",
308 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_grant));
309 LASSERTF((int)offsetof(struct obdo, o_blksize) == 64, " found %llu\n",
310 (unsigned long long)(int)offsetof(struct obdo, o_blksize));
311 LASSERTF((int)sizeof(((struct obdo *)0)->o_blksize) == 4, " found %llu\n",
312 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_blksize));
313 LASSERTF((int)offsetof(struct obdo, o_mode) == 68, " found %llu\n",
314 (unsigned long long)(int)offsetof(struct obdo, o_mode));
315 LASSERTF((int)sizeof(((struct obdo *)0)->o_mode) == 4, " found %llu\n",
316 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_mode));
317 LASSERTF((int)offsetof(struct obdo, o_uid) == 72, " found %llu\n",
318 (unsigned long long)(int)offsetof(struct obdo, o_uid));
319 LASSERTF((int)sizeof(((struct obdo *)0)->o_uid) == 4, " found %llu\n",
320 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_uid));
321 LASSERTF((int)offsetof(struct obdo, o_gid) == 76, " found %llu\n",
322 (unsigned long long)(int)offsetof(struct obdo, o_gid));
323 LASSERTF((int)sizeof(((struct obdo *)0)->o_gid) == 4, " found %llu\n",
324 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_gid));
325 LASSERTF((int)offsetof(struct obdo, o_flags) == 80, " found %llu\n",
326 (unsigned long long)(int)offsetof(struct obdo, o_flags));
327 LASSERTF((int)sizeof(((struct obdo *)0)->o_flags) == 4, " found %llu\n",
328 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_flags));
329 LASSERTF((int)offsetof(struct obdo, o_nlink) == 84, " found %llu\n",
330 (unsigned long long)(int)offsetof(struct obdo, o_nlink));
331 LASSERTF((int)sizeof(((struct obdo *)0)->o_nlink) == 4, " found %llu\n",
332 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_nlink));
333 LASSERTF((int)offsetof(struct obdo, o_generation) == 88, " found %llu\n",
334 (unsigned long long)(int)offsetof(struct obdo, o_generation));
335 LASSERTF((int)sizeof(((struct obdo *)0)->o_generation) == 4, " found %llu\n",
336 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_generation));
337 LASSERTF((int)offsetof(struct obdo, o_valid) == 92, " found %llu\n",
338 (unsigned long long)(int)offsetof(struct obdo, o_valid));
339 LASSERTF((int)sizeof(((struct obdo *)0)->o_valid) == 8, " found %llu\n",
340 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_valid));
341 LASSERTF((int)offsetof(struct obdo, o_misc) == 100, " found %llu\n",
342 (unsigned long long)(int)offsetof(struct obdo, o_misc));
343 LASSERTF((int)sizeof(((struct obdo *)0)->o_misc) == 4, " found %llu\n",
344 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_misc));
345 LASSERTF((int)offsetof(struct obdo, o_easize) == 104, " found %llu\n",
346 (unsigned long long)(int)offsetof(struct obdo, o_easize));
347 LASSERTF((int)sizeof(((struct obdo *)0)->o_easize) == 4, " found %llu\n",
348 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_easize));
349 LASSERTF((int)offsetof(struct obdo, o_mds) == 108, " found %llu\n",
350 (unsigned long long)(int)offsetof(struct obdo, o_mds));
351 LASSERTF((int)sizeof(((struct obdo *)0)->o_mds) == 4, " found %llu\n",
352 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_mds));
353 LASSERTF((int)offsetof(struct obdo, o_mds) == 108, " found %llu\n",
354 (unsigned long long)(int)offsetof(struct obdo, o_mds));
355 LASSERTF((int)sizeof(((struct obdo *)0)->o_mds) == 4, " found %llu\n",
356 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_mds));
357 LASSERTF((int)offsetof(struct obdo, o_fsuid) == 120, " found %llu\n",
358 (unsigned long long)(int)offsetof(struct obdo, o_fsuid));
359 LASSERTF((int)sizeof(((struct obdo *)0)->o_fsuid) == 4, " found %llu\n",
360 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_fsuid));
361 LASSERTF((int)offsetof(struct obdo, o_inline) == 124, " found %llu\n",
362 (unsigned long long)(int)offsetof(struct obdo, o_inline));
363 LASSERTF((int)sizeof(((struct obdo *)0)->o_inline) == 80, " found %llu\n",
364 (unsigned long long)(int)sizeof(((struct obdo *)0)->o_inline));
365 LASSERTF(OBD_MD_FLID == 1, " found %llu\n",
366 (unsigned long long)OBD_MD_FLID);
367 LASSERTF(OBD_MD_FLATIME == 2, " found %llu\n",
368 (unsigned long long)OBD_MD_FLATIME);
369 LASSERTF(OBD_MD_FLMTIME == 4, " found %llu\n",
370 (unsigned long long)OBD_MD_FLMTIME);
371 LASSERTF(OBD_MD_FLCTIME == 8, " found %llu\n",
372 (unsigned long long)OBD_MD_FLCTIME);
373 LASSERTF(OBD_MD_FLSIZE == 16, " found %llu\n",
374 (unsigned long long)OBD_MD_FLSIZE);
375 LASSERTF(OBD_MD_FLBLOCKS == 32, " found %llu\n",
376 (unsigned long long)OBD_MD_FLBLOCKS);
377 LASSERTF(OBD_MD_FLBLKSZ == 64, " found %llu\n",
378 (unsigned long long)OBD_MD_FLBLKSZ);
379 LASSERTF(OBD_MD_FLMODE == 128, " found %llu\n",
380 (unsigned long long)OBD_MD_FLMODE);
381 LASSERTF(OBD_MD_FLTYPE == 256, " found %llu\n",
382 (unsigned long long)OBD_MD_FLTYPE);
383 LASSERTF(OBD_MD_FLUID == 512, " found %llu\n",
384 (unsigned long long)OBD_MD_FLUID);
385 LASSERTF(OBD_MD_FLGID == 1024, " found %llu\n",
386 (unsigned long long)OBD_MD_FLGID);
387 LASSERTF(OBD_MD_FLFLAGS == 2048, " found %llu\n",
388 (unsigned long long)OBD_MD_FLFLAGS);
389 LASSERTF(OBD_MD_FLNLINK == 8192, " found %llu\n",
390 (unsigned long long)OBD_MD_FLNLINK);
391 LASSERTF(OBD_MD_FLGENER == 16384, " found %llu\n",
392 (unsigned long long)OBD_MD_FLGENER);
393 LASSERTF(OBD_MD_FLINLINE == 32768, " found %llu\n",
394 (unsigned long long)OBD_MD_FLINLINE);
395 LASSERTF(OBD_MD_FLRDEV == 65536, " found %llu\n",
396 (unsigned long long)OBD_MD_FLRDEV);
397 LASSERTF(OBD_MD_FLEASIZE == 131072, " found %llu\n",
398 (unsigned long long)OBD_MD_FLEASIZE);
399 LASSERTF(OBD_MD_LINKNAME == 262144, " found %llu\n",
400 (unsigned long long)OBD_MD_LINKNAME);
401 LASSERTF(OBD_MD_FLHANDLE == 524288, " found %llu\n",
402 (unsigned long long)OBD_MD_FLHANDLE);
403 LASSERTF(OBD_MD_FLCKSUM == 1048576, " found %llu\n",
404 (unsigned long long)OBD_MD_FLCKSUM);
405 LASSERTF(OBD_MD_FLQOS == 2097152, " found %llu\n",
406 (unsigned long long)OBD_MD_FLQOS);
407 LASSERTF(OBD_MD_FLOSCOPQ == 4194304, " found %llu\n",
408 (unsigned long long)OBD_MD_FLOSCOPQ);
409 LASSERTF(OBD_MD_FLCOOKIE == 8388608, " found %llu\n",
410 (unsigned long long)OBD_MD_FLCOOKIE);
411 LASSERTF(OBD_MD_FLGROUP == 16777216, " found %llu\n",
412 (unsigned long long)OBD_MD_FLGROUP);
413 LASSERTF(OBD_FL_INLINEDATA == 1, " found %llu\n",
414 (unsigned long long)OBD_FL_INLINEDATA);
415 LASSERTF(OBD_FL_OBDMDEXISTS == 2, " found %llu\n",
416 (unsigned long long)OBD_FL_OBDMDEXISTS);
417 LASSERTF(OBD_FL_DELORPHAN == 4, " found %llu\n",
418 (unsigned long long)OBD_FL_DELORPHAN);
419 LASSERTF(OBD_FL_NORPC == 8, " found %llu\n",
420 (unsigned long long)OBD_FL_NORPC);
421 LASSERTF(OBD_FL_IDONLY == 16, " found %llu\n",
422 (unsigned long long)OBD_FL_IDONLY);
423 LASSERTF(OBD_FL_RECREATE_OBJS == 32, " found %llu\n",
424 (unsigned long long)OBD_FL_RECREATE_OBJS);
426 /* Checks for struct lov_mds_md_v1 */
427 LASSERTF((int)sizeof(struct lov_mds_md_v1) == 32, " found %llu\n",
428 (unsigned long long)(int)sizeof(struct lov_mds_md_v1));
429 LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_magic) == 0, " found %llu\n",
430 (unsigned long long)(int)offsetof(struct lov_mds_md_v1, lmm_magic));
431 LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_magic) == 4, " found %llu\n",
432 (unsigned long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_magic));
433 LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_pattern) == 4, " found %llu\n",
434 (unsigned long long)(int)offsetof(struct lov_mds_md_v1, lmm_pattern));
435 LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_pattern) == 4, " found %llu\n",
436 (unsigned long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_pattern));
437 LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_object_id) == 8, " found %llu\n",
438 (unsigned long long)(int)offsetof(struct lov_mds_md_v1, lmm_object_id));
439 LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_id) == 8, " found %llu\n",
440 (unsigned long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_id));
441 LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_object_gr) == 16, " found %llu\n",
442 (unsigned long long)(int)offsetof(struct lov_mds_md_v1, lmm_object_gr));
443 LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_gr) == 8, " found %llu\n",
444 (unsigned long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_gr));
445 LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_stripe_size) == 24, " found %llu\n",
446 (unsigned long long)(int)offsetof(struct lov_mds_md_v1, lmm_stripe_size));
447 LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_stripe_size) == 4, " found %llu\n",
448 (unsigned long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_stripe_size));
449 LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_stripe_count) == 28, " found %llu\n",
450 (unsigned long long)(int)offsetof(struct lov_mds_md_v1, lmm_stripe_count));
451 LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_stripe_count) == 4, " found %llu\n",
452 (unsigned long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_stripe_count));
453 LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_objects) == 32, " found %llu\n",
454 (unsigned long long)(int)offsetof(struct lov_mds_md_v1, lmm_objects));
455 LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_objects) == 0, " found %llu\n",
456 (unsigned long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_objects));
458 /* Checks for struct lov_ost_data_v1 */
459 LASSERTF((int)sizeof(struct lov_ost_data_v1) == 24, " found %llu\n",
460 (unsigned long long)(int)sizeof(struct lov_ost_data_v1));
461 LASSERTF((int)offsetof(struct lov_ost_data_v1, l_object_id) == 0, " found %llu\n",
462 (unsigned long long)(int)offsetof(struct lov_ost_data_v1, l_object_id));
463 LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_id) == 8, " found %llu\n",
464 (unsigned long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_id));
465 LASSERTF((int)offsetof(struct lov_ost_data_v1, l_object_gr) == 8, " found %llu\n",
466 (unsigned long long)(int)offsetof(struct lov_ost_data_v1, l_object_gr));
467 LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_gr) == 8, " found %llu\n",
468 (unsigned long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_gr));
469 LASSERTF((int)offsetof(struct lov_ost_data_v1, l_ost_gen) == 16, " found %llu\n",
470 (unsigned long long)(int)offsetof(struct lov_ost_data_v1, l_ost_gen));
471 LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_ost_gen) == 4, " found %llu\n",
472 (unsigned long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_ost_gen));
473 LASSERTF((int)offsetof(struct lov_ost_data_v1, l_ost_idx) == 20, " found %llu\n",
474 (unsigned long long)(int)offsetof(struct lov_ost_data_v1, l_ost_idx));
475 LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_ost_idx) == 4, " found %llu\n",
476 (unsigned long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_ost_idx));
477 LASSERTF(LOV_MAGIC_V0 == 198183888, " found %llu\n",
478 (unsigned long long)LOV_MAGIC_V0);
479 LASSERTF(LOV_MAGIC_V1 == 198249424, " found %llu\n",
480 (unsigned long long)LOV_MAGIC_V1);
481 LASSERTF(LOV_PATTERN_RAID0 == 1, " found %llu\n",
482 (unsigned long long)LOV_PATTERN_RAID0);
483 LASSERTF(LOV_PATTERN_RAID1 == 2, " found %llu\n",
484 (unsigned long long)LOV_PATTERN_RAID1);
486 /* Checks for struct obd_statfs */
487 LASSERTF((int)sizeof(struct obd_statfs) == 144, " found %llu\n",
488 (unsigned long long)(int)sizeof(struct obd_statfs));
489 LASSERTF((int)offsetof(struct obd_statfs, os_type) == 0, " found %llu\n",
490 (unsigned long long)(int)offsetof(struct obd_statfs, os_type));
491 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_type) == 8, " found %llu\n",
492 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_type));
493 LASSERTF((int)offsetof(struct obd_statfs, os_blocks) == 8, " found %llu\n",
494 (unsigned long long)(int)offsetof(struct obd_statfs, os_blocks));
495 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_blocks) == 8, " found %llu\n",
496 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_blocks));
497 LASSERTF((int)offsetof(struct obd_statfs, os_bfree) == 16, " found %llu\n",
498 (unsigned long long)(int)offsetof(struct obd_statfs, os_bfree));
499 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_bfree) == 8, " found %llu\n",
500 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_bfree));
501 LASSERTF((int)offsetof(struct obd_statfs, os_bavail) == 24, " found %llu\n",
502 (unsigned long long)(int)offsetof(struct obd_statfs, os_bavail));
503 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_bavail) == 8, " found %llu\n",
504 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_bavail));
505 LASSERTF((int)offsetof(struct obd_statfs, os_ffree) == 40, " found %llu\n",
506 (unsigned long long)(int)offsetof(struct obd_statfs, os_ffree));
507 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_ffree) == 8, " found %llu\n",
508 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_ffree));
509 LASSERTF((int)offsetof(struct obd_statfs, os_fsid) == 48, " found %llu\n",
510 (unsigned long long)(int)offsetof(struct obd_statfs, os_fsid));
511 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_fsid) == 40, " found %llu\n",
512 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_fsid));
513 LASSERTF((int)offsetof(struct obd_statfs, os_bsize) == 88, " found %llu\n",
514 (unsigned long long)(int)offsetof(struct obd_statfs, os_bsize));
515 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_bsize) == 4, " found %llu\n",
516 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_bsize));
517 LASSERTF((int)offsetof(struct obd_statfs, os_namelen) == 92, " found %llu\n",
518 (unsigned long long)(int)offsetof(struct obd_statfs, os_namelen));
519 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_namelen) == 4, " found %llu\n",
520 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_namelen));
521 LASSERTF((int)offsetof(struct obd_statfs, os_spare) == 104, " found %llu\n",
522 (unsigned long long)(int)offsetof(struct obd_statfs, os_spare));
523 LASSERTF((int)sizeof(((struct obd_statfs *)0)->os_spare) == 40, " found %llu\n",
524 (unsigned long long)(int)sizeof(((struct obd_statfs *)0)->os_spare));
526 /* Checks for struct obd_ioobj */
527 LASSERTF((int)sizeof(struct obd_ioobj) == 24, " found %llu\n",
528 (unsigned long long)(int)sizeof(struct obd_ioobj));
529 LASSERTF((int)offsetof(struct obd_ioobj, ioo_id) == 0, " found %llu\n",
530 (unsigned long long)(int)offsetof(struct obd_ioobj, ioo_id));
531 LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_id) == 8, " found %llu\n",
532 (unsigned long long)(int)sizeof(((struct obd_ioobj *)0)->ioo_id));
533 LASSERTF((int)offsetof(struct obd_ioobj, ioo_gr) == 8, " found %llu\n",
534 (unsigned long long)(int)offsetof(struct obd_ioobj, ioo_gr));
535 LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_gr) == 8, " found %llu\n",
536 (unsigned long long)(int)sizeof(((struct obd_ioobj *)0)->ioo_gr));
537 LASSERTF((int)offsetof(struct obd_ioobj, ioo_type) == 16, " found %llu\n",
538 (unsigned long long)(int)offsetof(struct obd_ioobj, ioo_type));
539 LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_type) == 4, " found %llu\n",
540 (unsigned long long)(int)sizeof(((struct obd_ioobj *)0)->ioo_type));
541 LASSERTF((int)offsetof(struct obd_ioobj, ioo_bufcnt) == 20, " found %llu\n",
542 (unsigned long long)(int)offsetof(struct obd_ioobj, ioo_bufcnt));
543 LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_bufcnt) == 4, " found %llu\n",
544 (unsigned long long)(int)sizeof(((struct obd_ioobj *)0)->ioo_bufcnt));
546 /* Checks for struct niobuf_remote */
547 LASSERTF((int)sizeof(struct niobuf_remote) == 16, " found %llu\n",
548 (unsigned long long)(int)sizeof(struct niobuf_remote));
549 LASSERTF((int)offsetof(struct niobuf_remote, offset) == 0, " found %llu\n",
550 (unsigned long long)(int)offsetof(struct niobuf_remote, offset));
551 LASSERTF((int)sizeof(((struct niobuf_remote *)0)->offset) == 8, " found %llu\n",
552 (unsigned long long)(int)sizeof(((struct niobuf_remote *)0)->offset));
553 LASSERTF((int)offsetof(struct niobuf_remote, len) == 8, " found %llu\n",
554 (unsigned long long)(int)offsetof(struct niobuf_remote, len));
555 LASSERTF((int)sizeof(((struct niobuf_remote *)0)->len) == 4, " found %llu\n",
556 (unsigned long long)(int)sizeof(((struct niobuf_remote *)0)->len));
557 LASSERTF((int)offsetof(struct niobuf_remote, flags) == 12, " found %llu\n",
558 (unsigned long long)(int)offsetof(struct niobuf_remote, flags));
559 LASSERTF((int)sizeof(((struct niobuf_remote *)0)->flags) == 4, " found %llu\n",
560 (unsigned long long)(int)sizeof(((struct niobuf_remote *)0)->flags));
561 LASSERTF(OBD_BRW_READ == 1, " found %llu\n",
562 (unsigned long long)OBD_BRW_READ);
563 LASSERTF(OBD_BRW_WRITE == 2, " found %llu\n",
564 (unsigned long long)OBD_BRW_WRITE);
565 LASSERTF(OBD_BRW_SYNC == 8, " found %llu\n",
566 (unsigned long long)OBD_BRW_SYNC);
567 LASSERTF(OBD_BRW_FROM_GRANT == 32, " found %llu\n",
568 (unsigned long long)OBD_BRW_FROM_GRANT);
570 /* Checks for struct ost_body */
571 LASSERTF((int)sizeof(struct ost_body) == 204, " found %llu\n",
572 (unsigned long long)(int)sizeof(struct ost_body));
573 LASSERTF((int)offsetof(struct ost_body, oa) == 0, " found %llu\n",
574 (unsigned long long)(int)offsetof(struct ost_body, oa));
575 LASSERTF((int)sizeof(((struct ost_body *)0)->oa) == 204, " found %llu\n",
576 (unsigned long long)(int)sizeof(((struct ost_body *)0)->oa));
578 /* Checks for struct lustre_stc */
579 LASSERTF((int)sizeof(struct lustre_stc) == 16, " found %llu\n",
580 (unsigned long long)(int)sizeof(struct lustre_stc));
581 LASSERTF((int)offsetof(struct lustre_stc, u.e3s.l3s_ino) == 0, " found %llu\n",
582 (unsigned long long)(int)offsetof(struct lustre_stc, u.e3s.l3s_ino));
583 LASSERTF((int)sizeof(((struct lustre_stc *)0)->u.e3s.l3s_ino) == 8, " found %llu\n",
584 (unsigned long long)(int)sizeof(((struct lustre_stc *)0)->u.e3s.l3s_ino));
585 LASSERTF((int)offsetof(struct lustre_stc, u.e3s.l3s_gen) == 8, " found %llu\n",
586 (unsigned long long)(int)offsetof(struct lustre_stc, u.e3s.l3s_gen));
587 LASSERTF((int)sizeof(((struct lustre_stc *)0)->u.e3s.l3s_gen) == 4, " found %llu\n",
588 (unsigned long long)(int)sizeof(((struct lustre_stc *)0)->u.e3s.l3s_gen));
589 LASSERTF((int)offsetof(struct lustre_stc, u.e3s.l3s_type) == 12, " found %llu\n",
590 (unsigned long long)(int)offsetof(struct lustre_stc, u.e3s.l3s_type));
591 LASSERTF((int)sizeof(((struct lustre_stc *)0)->u.e3s.l3s_type) == 4, " found %llu\n",
592 (unsigned long long)(int)sizeof(((struct lustre_stc *)0)->u.e3s.l3s_type));
594 /* Checks for struct mds_status_req */
595 LASSERTF((int)sizeof(struct mds_status_req) == 8, " found %llu\n",
596 (unsigned long long)(int)sizeof(struct mds_status_req));
597 LASSERTF((int)offsetof(struct mds_status_req, flags) == 0, " found %llu\n",
598 (unsigned long long)(int)offsetof(struct mds_status_req, flags));
599 LASSERTF((int)sizeof(((struct mds_status_req *)0)->flags) == 4, " found %llu\n",
600 (unsigned long long)(int)sizeof(((struct mds_status_req *)0)->flags));
601 LASSERTF((int)offsetof(struct mds_status_req, repbuf) == 4, " found %llu\n",
602 (unsigned long long)(int)offsetof(struct mds_status_req, repbuf));
603 LASSERTF((int)sizeof(((struct mds_status_req *)0)->repbuf) == 4, " found %llu\n",
604 (unsigned long long)(int)sizeof(((struct mds_status_req *)0)->repbuf));
606 /* Checks for struct mds_body */
607 LASSERTF((int)sizeof(struct mds_body) == 152, " found %llu\n",
608 (unsigned long long)(int)sizeof(struct mds_body));
609 LASSERTF((int)offsetof(struct mds_body, id1) == 0, " found %llu\n",
610 (unsigned long long)(int)offsetof(struct mds_body, id1));
611 LASSERTF((int)sizeof(((struct mds_body *)0)->id1) == 32, " found %llu\n",
612 (unsigned long long)(int)sizeof(((struct mds_body *)0)->id1));
613 LASSERTF((int)offsetof(struct mds_body, id2) == 32, " found %llu\n",
614 (unsigned long long)(int)offsetof(struct mds_body, id2));
615 LASSERTF((int)sizeof(((struct mds_body *)0)->id2) == 32, " found %llu\n",
616 (unsigned long long)(int)sizeof(((struct mds_body *)0)->id2));
617 LASSERTF((int)offsetof(struct mds_body, handle) == 64, " found %llu\n",
618 (unsigned long long)(int)offsetof(struct mds_body, handle));
619 LASSERTF((int)sizeof(((struct mds_body *)0)->handle) == 8, " found %llu\n",
620 (unsigned long long)(int)sizeof(((struct mds_body *)0)->handle));
621 LASSERTF((int)offsetof(struct mds_body, size) == 72, " found %llu\n",
622 (unsigned long long)(int)offsetof(struct mds_body, size));
623 LASSERTF((int)sizeof(((struct mds_body *)0)->size) == 8, " found %llu\n",
624 (unsigned long long)(int)sizeof(((struct mds_body *)0)->size));
625 LASSERTF((int)offsetof(struct mds_body, blocks) == 80, " found %llu\n",
626 (unsigned long long)(int)offsetof(struct mds_body, blocks));
627 LASSERTF((int)sizeof(((struct mds_body *)0)->blocks) == 8, " found %llu\n",
628 (unsigned long long)(int)sizeof(((struct mds_body *)0)->blocks));
629 LASSERTF((int)offsetof(struct mds_body, io_epoch) == 88, " found %llu\n",
630 (unsigned long long)(int)offsetof(struct mds_body, io_epoch));
631 LASSERTF((int)sizeof(((struct mds_body *)0)->io_epoch) == 8, " found %llu\n",
632 (unsigned long long)(int)sizeof(((struct mds_body *)0)->io_epoch));
633 LASSERTF((int)offsetof(struct mds_body, valid) == 96, " found %llu\n",
634 (unsigned long long)(int)offsetof(struct mds_body, valid));
635 LASSERTF((int)sizeof(((struct mds_body *)0)->valid) == 8, " found %llu\n",
636 (unsigned long long)(int)sizeof(((struct mds_body *)0)->valid));
637 LASSERTF((int)offsetof(struct mds_body, mode) == 112, " found %llu\n",
638 (unsigned long long)(int)offsetof(struct mds_body, mode));
639 LASSERTF((int)sizeof(((struct mds_body *)0)->mode) == 4, " found %llu\n",
640 (unsigned long long)(int)sizeof(((struct mds_body *)0)->mode));
641 LASSERTF((int)offsetof(struct mds_body, uid) == 116, " found %llu\n",
642 (unsigned long long)(int)offsetof(struct mds_body, uid));
643 LASSERTF((int)sizeof(((struct mds_body *)0)->uid) == 4, " found %llu\n",
644 (unsigned long long)(int)sizeof(((struct mds_body *)0)->uid));
645 LASSERTF((int)offsetof(struct mds_body, gid) == 120, " found %llu\n",
646 (unsigned long long)(int)offsetof(struct mds_body, gid));
647 LASSERTF((int)sizeof(((struct mds_body *)0)->gid) == 4, " found %llu\n",
648 (unsigned long long)(int)sizeof(((struct mds_body *)0)->gid));
649 LASSERTF((int)offsetof(struct mds_body, mtime) == 124, " found %llu\n",
650 (unsigned long long)(int)offsetof(struct mds_body, mtime));
651 LASSERTF((int)sizeof(((struct mds_body *)0)->mtime) == 4, " found %llu\n",
652 (unsigned long long)(int)sizeof(((struct mds_body *)0)->mtime));
653 LASSERTF((int)offsetof(struct mds_body, ctime) == 128, " found %llu\n",
654 (unsigned long long)(int)offsetof(struct mds_body, ctime));
655 LASSERTF((int)sizeof(((struct mds_body *)0)->ctime) == 4, " found %llu\n",
656 (unsigned long long)(int)sizeof(((struct mds_body *)0)->ctime));
657 LASSERTF((int)offsetof(struct mds_body, atime) == 132, " found %llu\n",
658 (unsigned long long)(int)offsetof(struct mds_body, atime));
659 LASSERTF((int)sizeof(((struct mds_body *)0)->atime) == 4, " found %llu\n",
660 (unsigned long long)(int)sizeof(((struct mds_body *)0)->atime));
661 LASSERTF((int)offsetof(struct mds_body, flags) == 136, " found %llu\n",
662 (unsigned long long)(int)offsetof(struct mds_body, flags));
663 LASSERTF((int)sizeof(((struct mds_body *)0)->flags) == 4, " found %llu\n",
664 (unsigned long long)(int)sizeof(((struct mds_body *)0)->flags));
665 LASSERTF((int)offsetof(struct mds_body, rdev) == 140, " found %llu\n",
666 (unsigned long long)(int)offsetof(struct mds_body, rdev));
667 LASSERTF((int)sizeof(((struct mds_body *)0)->rdev) == 4, " found %llu\n",
668 (unsigned long long)(int)sizeof(((struct mds_body *)0)->rdev));
669 LASSERTF((int)offsetof(struct mds_body, nlink) == 144, " found %llu\n",
670 (unsigned long long)(int)offsetof(struct mds_body, nlink));
671 LASSERTF((int)sizeof(((struct mds_body *)0)->nlink) == 4, " found %llu\n",
672 (unsigned long long)(int)sizeof(((struct mds_body *)0)->nlink));
673 LASSERTF((int)offsetof(struct mds_body, eadatasize) == 148, " found %llu\n",
674 (unsigned long long)(int)offsetof(struct mds_body, eadatasize));
675 LASSERTF((int)sizeof(((struct mds_body *)0)->eadatasize) == 4, " found %llu\n",
676 (unsigned long long)(int)sizeof(((struct mds_body *)0)->eadatasize));
677 LASSERTF(FMODE_READ == 1, " found %llu\n",
678 (unsigned long long)FMODE_READ);
679 LASSERTF(FMODE_WRITE == 2, " found %llu\n",
680 (unsigned long long)FMODE_WRITE);
681 LASSERTF(FMODE_EXEC == 4, " found %llu\n",
682 (unsigned long long)FMODE_EXEC);
683 LASSERTF(MDS_OPEN_CREAT == 64, " found %llu\n",
684 (unsigned long long)MDS_OPEN_CREAT);
685 LASSERTF(MDS_OPEN_EXCL == 128, " found %llu\n",
686 (unsigned long long)MDS_OPEN_EXCL);
687 LASSERTF(MDS_OPEN_TRUNC == 512, " found %llu\n",
688 (unsigned long long)MDS_OPEN_TRUNC);
689 LASSERTF(MDS_OPEN_APPEND == 1024, " found %llu\n",
690 (unsigned long long)MDS_OPEN_APPEND);
691 LASSERTF(MDS_OPEN_SYNC == 4096, " found %llu\n",
692 (unsigned long long)MDS_OPEN_SYNC);
693 LASSERTF(MDS_OPEN_DIRECTORY == 65536, " found %llu\n",
694 (unsigned long long)MDS_OPEN_DIRECTORY);
695 LASSERTF(MDS_OPEN_DELAY_CREATE == 16777216, " found %llu\n",
696 (unsigned long long)MDS_OPEN_DELAY_CREATE);
697 LASSERTF(MDS_OPEN_HAS_EA == 1073741824, " found %llu\n",
698 (unsigned long long)MDS_OPEN_HAS_EA);
700 /* Checks for struct mds_rec_setattr */
701 LASSERTF((int)sizeof(struct mds_rec_setattr) == 92, " found %llu\n",
702 (unsigned long long)(int)sizeof(struct mds_rec_setattr));
703 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_opcode) == 0, " found %llu\n",
704 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_opcode));
705 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_opcode) == 4, " found %llu\n",
706 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_opcode));
707 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_valid) == 8, " found %llu\n",
708 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_valid));
709 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_valid) == 4, " found %llu\n",
710 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_valid));
711 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_id) == 12, " found %llu\n",
712 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_id));
713 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_id) == 32, " found %llu\n",
714 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_id));
715 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_mode) == 44, " found %llu\n",
716 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_mode));
717 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_mode) == 4, " found %llu\n",
718 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_mode));
719 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_uid) == 48, " found %llu\n",
720 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_uid));
721 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_uid) == 4, " found %llu\n",
722 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_uid));
723 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_gid) == 52, " found %llu\n",
724 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_gid));
725 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_gid) == 4, " found %llu\n",
726 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_gid));
727 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_attr_flags) == 56, " found %llu\n",
728 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_attr_flags));
729 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_attr_flags) == 4, " found %llu\n",
730 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_attr_flags));
731 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_size) == 60, " found %llu\n",
732 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_size));
733 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_size) == 8, " found %llu\n",
734 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_size));
735 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_atime) == 68, " found %llu\n",
736 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_atime));
737 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_atime) == 8, " found %llu\n",
738 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_atime));
739 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_mtime) == 76, " found %llu\n",
740 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_mtime));
741 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_mtime) == 8, " found %llu\n",
742 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_mtime));
743 LASSERTF((int)offsetof(struct mds_rec_setattr, sa_ctime) == 84, " found %llu\n",
744 (unsigned long long)(int)offsetof(struct mds_rec_setattr, sa_ctime));
745 LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_ctime) == 8, " found %llu\n",
746 (unsigned long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_ctime));
748 /* Checks for struct mds_rec_create */
749 LASSERTF((int)sizeof(struct mds_rec_create) == 120, " found %llu\n",
750 (unsigned long long)(int)sizeof(struct mds_rec_create));
751 LASSERTF((int)offsetof(struct mds_rec_create, cr_opcode) == 0, " found %llu\n",
752 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_opcode));
753 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_opcode) == 4, " found %llu\n",
754 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_opcode));
755 LASSERTF((int)offsetof(struct mds_rec_create, cr_flags) == 4, " found %llu\n",
756 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_flags));
757 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_flags) == 4, " found %llu\n",
758 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_flags));
759 LASSERTF((int)offsetof(struct mds_rec_create, cr_mode) == 8, " found %llu\n",
760 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_mode));
761 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_mode) == 4, " found %llu\n",
762 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_mode));
763 LASSERTF((int)offsetof(struct mds_rec_create, cr_padding) == 12, " found %llu\n",
764 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_padding));
765 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_padding) == 4, " found %llu\n",
766 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_padding));
767 LASSERTF((int)offsetof(struct mds_rec_create, cr_id) == 16, " found %llu\n",
768 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_id));
769 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_id) == 32, " found %llu\n",
770 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_id));
771 LASSERTF((int)offsetof(struct mds_rec_create, cr_replayid) == 48, " found %llu\n",
772 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_replayid));
773 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_replayid) == 32, " found %llu\n",
774 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_replayid));
775 LASSERTF((int)offsetof(struct mds_rec_create, cr_time) == 80, " found %llu\n",
776 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_time));
777 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_time) == 8, " found %llu\n",
778 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_time));
779 LASSERTF((int)offsetof(struct mds_rec_create, cr_rdev) == 88, " found %llu\n",
780 (unsigned long long)(int)offsetof(struct mds_rec_create, cr_rdev));
781 LASSERTF((int)sizeof(((struct mds_rec_create *)0)->cr_rdev) == 8, " found %llu\n",
782 (unsigned long long)(int)sizeof(((struct mds_rec_create *)0)->cr_rdev));
784 /* Checks for struct mds_rec_link */
785 LASSERTF((int)sizeof(struct mds_rec_link) == 84, " found %llu\n",
786 (unsigned long long)(int)sizeof(struct mds_rec_link));
787 LASSERTF((int)offsetof(struct mds_rec_link, lk_opcode) == 0, " found %llu\n",
788 (unsigned long long)(int)offsetof(struct mds_rec_link, lk_opcode));
789 LASSERTF((int)sizeof(((struct mds_rec_link *)0)->lk_opcode) == 4, " found %llu\n",
790 (unsigned long long)(int)sizeof(((struct mds_rec_link *)0)->lk_opcode));
791 LASSERTF((int)offsetof(struct mds_rec_link, lk_padding) == 8, " found %llu\n",
792 (unsigned long long)(int)offsetof(struct mds_rec_link, lk_padding));
793 LASSERTF((int)sizeof(((struct mds_rec_link *)0)->lk_padding) == 4, " found %llu\n",
794 (unsigned long long)(int)sizeof(((struct mds_rec_link *)0)->lk_padding));
795 LASSERTF((int)offsetof(struct mds_rec_link, lk_id1) == 12, " found %llu\n",
796 (unsigned long long)(int)offsetof(struct mds_rec_link, lk_id1));
797 LASSERTF((int)sizeof(((struct mds_rec_link *)0)->lk_id1) == 32, " found %llu\n",
798 (unsigned long long)(int)sizeof(((struct mds_rec_link *)0)->lk_id1));
799 LASSERTF((int)offsetof(struct mds_rec_link, lk_id2) == 44, " found %llu\n",
800 (unsigned long long)(int)offsetof(struct mds_rec_link, lk_id2));
801 LASSERTF((int)sizeof(((struct mds_rec_link *)0)->lk_id2) == 32, " found %llu\n",
802 (unsigned long long)(int)sizeof(((struct mds_rec_link *)0)->lk_id2));
803 LASSERTF((int)offsetof(struct mds_rec_link, lk_time) == 76, " found %llu\n",
804 (unsigned long long)(int)offsetof(struct mds_rec_link, lk_time));
805 LASSERTF((int)sizeof(((struct mds_rec_link *)0)->lk_time) == 8, " found %llu\n",
806 (unsigned long long)(int)sizeof(((struct mds_rec_link *)0)->lk_time));
808 /* Checks for struct mds_rec_unlink */
809 LASSERTF((int)sizeof(struct mds_rec_unlink) == 84, " found %llu\n",
810 (unsigned long long)(int)sizeof(struct mds_rec_unlink));
811 LASSERTF((int)offsetof(struct mds_rec_unlink, ul_opcode) == 0, " found %llu\n",
812 (unsigned long long)(int)offsetof(struct mds_rec_unlink, ul_opcode));
813 LASSERTF((int)sizeof(((struct mds_rec_unlink *)0)->ul_opcode) == 4, " found %llu\n",
814 (unsigned long long)(int)sizeof(((struct mds_rec_unlink *)0)->ul_opcode));
815 LASSERTF((int)offsetof(struct mds_rec_unlink, ul_mode) == 8, " found %llu\n",
816 (unsigned long long)(int)offsetof(struct mds_rec_unlink, ul_mode));
817 LASSERTF((int)sizeof(((struct mds_rec_unlink *)0)->ul_mode) == 4, " found %llu\n",
818 (unsigned long long)(int)sizeof(((struct mds_rec_unlink *)0)->ul_mode));
819 LASSERTF((int)offsetof(struct mds_rec_unlink, ul_id1) == 12, " found %llu\n",
820 (unsigned long long)(int)offsetof(struct mds_rec_unlink, ul_id1));
821 LASSERTF((int)sizeof(((struct mds_rec_unlink *)0)->ul_id1) == 32, " found %llu\n",
822 (unsigned long long)(int)sizeof(((struct mds_rec_unlink *)0)->ul_id1));
823 LASSERTF((int)offsetof(struct mds_rec_unlink, ul_id2) == 44, " found %llu\n",
824 (unsigned long long)(int)offsetof(struct mds_rec_unlink, ul_id2));
825 LASSERTF((int)sizeof(((struct mds_rec_unlink *)0)->ul_id2) == 32, " found %llu\n",
826 (unsigned long long)(int)sizeof(((struct mds_rec_unlink *)0)->ul_id2));
827 LASSERTF((int)offsetof(struct mds_rec_unlink, ul_time) == 76, " found %llu\n",
828 (unsigned long long)(int)offsetof(struct mds_rec_unlink, ul_time));
829 LASSERTF((int)sizeof(((struct mds_rec_unlink *)0)->ul_time) == 8, " found %llu\n",
830 (unsigned long long)(int)sizeof(((struct mds_rec_unlink *)0)->ul_time));
832 /* Checks for struct mds_rec_rename */
833 LASSERTF((int)sizeof(struct mds_rec_rename) == 84, " found %llu\n",
834 (unsigned long long)(int)sizeof(struct mds_rec_rename));
835 LASSERTF((int)offsetof(struct mds_rec_rename, rn_opcode) == 0, " found %llu\n",
836 (unsigned long long)(int)offsetof(struct mds_rec_rename, rn_opcode));
837 LASSERTF((int)sizeof(((struct mds_rec_rename *)0)->rn_opcode) == 4, " found %llu\n",
838 (unsigned long long)(int)sizeof(((struct mds_rec_rename *)0)->rn_opcode));
839 LASSERTF((int)offsetof(struct mds_rec_rename, rn_padding) == 8, " found %llu\n",
840 (unsigned long long)(int)offsetof(struct mds_rec_rename, rn_padding));
841 LASSERTF((int)sizeof(((struct mds_rec_rename *)0)->rn_padding) == 4, " found %llu\n",
842 (unsigned long long)(int)sizeof(((struct mds_rec_rename *)0)->rn_padding));
843 LASSERTF((int)offsetof(struct mds_rec_rename, rn_id1) == 12, " found %llu\n",
844 (unsigned long long)(int)offsetof(struct mds_rec_rename, rn_id1));
845 LASSERTF((int)sizeof(((struct mds_rec_rename *)0)->rn_id1) == 32, " found %llu\n",
846 (unsigned long long)(int)sizeof(((struct mds_rec_rename *)0)->rn_id1));
847 LASSERTF((int)offsetof(struct mds_rec_rename, rn_id2) == 44, " found %llu\n",
848 (unsigned long long)(int)offsetof(struct mds_rec_rename, rn_id2));
849 LASSERTF((int)sizeof(((struct mds_rec_rename *)0)->rn_id2) == 32, " found %llu\n",
850 (unsigned long long)(int)sizeof(((struct mds_rec_rename *)0)->rn_id2));
851 LASSERTF((int)offsetof(struct mds_rec_rename, rn_time) == 76, " found %llu\n",
852 (unsigned long long)(int)offsetof(struct mds_rec_rename, rn_time));
853 LASSERTF((int)sizeof(((struct mds_rec_rename *)0)->rn_time) == 8, " found %llu\n",
854 (unsigned long long)(int)sizeof(((struct mds_rec_rename *)0)->rn_time));
856 /* Checks for struct lov_desc */
857 LASSERTF((int)sizeof(struct lov_desc) == 72, " found %llu\n",
858 (unsigned long long)(int)sizeof(struct lov_desc));
859 LASSERTF((int)offsetof(struct lov_desc, ld_tgt_count) == 0, " found %llu\n",
860 (unsigned long long)(int)offsetof(struct lov_desc, ld_tgt_count));
861 LASSERTF((int)sizeof(((struct lov_desc *)0)->ld_tgt_count) == 4, " found %llu\n",
862 (unsigned long long)(int)sizeof(((struct lov_desc *)0)->ld_tgt_count));
863 LASSERTF((int)offsetof(struct lov_desc, ld_active_tgt_count) == 4, " found %llu\n",
864 (unsigned long long)(int)offsetof(struct lov_desc, ld_active_tgt_count));
865 LASSERTF((int)sizeof(((struct lov_desc *)0)->ld_active_tgt_count) == 4, " found %llu\n",
866 (unsigned long long)(int)sizeof(((struct lov_desc *)0)->ld_active_tgt_count));
867 LASSERTF((int)offsetof(struct lov_desc, ld_default_stripe_count) == 8, " found %llu\n",
868 (unsigned long long)(int)offsetof(struct lov_desc, ld_default_stripe_count));
869 LASSERTF((int)sizeof(((struct lov_desc *)0)->ld_default_stripe_count) == 4, " found %llu\n",
870 (unsigned long long)(int)sizeof(((struct lov_desc *)0)->ld_default_stripe_count));
871 LASSERTF((int)offsetof(struct lov_desc, ld_pattern) == 12, " found %llu\n",
872 (unsigned long long)(int)offsetof(struct lov_desc, ld_pattern));
873 LASSERTF((int)sizeof(((struct lov_desc *)0)->ld_pattern) == 4, " found %llu\n",
874 (unsigned long long)(int)sizeof(((struct lov_desc *)0)->ld_pattern));
875 LASSERTF((int)offsetof(struct lov_desc, ld_default_stripe_size) == 16, " found %llu\n",
876 (unsigned long long)(int)offsetof(struct lov_desc, ld_default_stripe_size));
877 LASSERTF((int)sizeof(((struct lov_desc *)0)->ld_default_stripe_size) == 8, " found %llu\n",
878 (unsigned long long)(int)sizeof(((struct lov_desc *)0)->ld_default_stripe_size));
879 LASSERTF((int)offsetof(struct lov_desc, ld_default_stripe_offset) == 24, " found %llu\n",
880 (unsigned long long)(int)offsetof(struct lov_desc, ld_default_stripe_offset));
881 LASSERTF((int)sizeof(((struct lov_desc *)0)->ld_default_stripe_offset) == 8, " found %llu\n",
882 (unsigned long long)(int)sizeof(((struct lov_desc *)0)->ld_default_stripe_offset));
883 LASSERTF((int)offsetof(struct lov_desc, ld_uuid) == 32, " found %llu\n",
884 (unsigned long long)(int)offsetof(struct lov_desc, ld_uuid));
885 LASSERTF((int)sizeof(((struct lov_desc *)0)->ld_uuid) == 40, " found %llu\n",
886 (unsigned long long)(int)sizeof(((struct lov_desc *)0)->ld_uuid));
888 /* Checks for struct ldlm_res_id */
889 LASSERTF((int)sizeof(struct ldlm_res_id) == 32, " found %llu\n",
890 (unsigned long long)(int)sizeof(struct ldlm_res_id));
891 LASSERTF((int)offsetof(struct ldlm_res_id, name[4]) == 32, " found %llu\n",
892 (unsigned long long)(int)offsetof(struct ldlm_res_id, name[4]));
893 LASSERTF((int)sizeof(((struct ldlm_res_id *)0)->name[4]) == 8, " found %llu\n",
894 (unsigned long long)(int)sizeof(((struct ldlm_res_id *)0)->name[4]));
896 /* Checks for struct ldlm_extent */
897 LASSERTF((int)sizeof(struct ldlm_extent) == 24, " found %llu\n",
898 (unsigned long long)(int)sizeof(struct ldlm_extent));
899 LASSERTF((int)offsetof(struct ldlm_extent, start) == 0, " found %llu\n",
900 (unsigned long long)(int)offsetof(struct ldlm_extent, start));
901 LASSERTF((int)sizeof(((struct ldlm_extent *)0)->start) == 8, " found %llu\n",
902 (unsigned long long)(int)sizeof(((struct ldlm_extent *)0)->start));
903 LASSERTF((int)offsetof(struct ldlm_extent, end) == 8, " found %llu\n",
904 (unsigned long long)(int)offsetof(struct ldlm_extent, end));
905 LASSERTF((int)sizeof(((struct ldlm_extent *)0)->end) == 8, " found %llu\n",
906 (unsigned long long)(int)sizeof(((struct ldlm_extent *)0)->end));
907 LASSERTF((int)offsetof(struct ldlm_extent, gid) == 16, " found %llu\n",
908 (unsigned long long)(int)offsetof(struct ldlm_extent, gid));
909 LASSERTF((int)sizeof(((struct ldlm_extent *)0)->gid) == 8, " found %llu\n",
910 (unsigned long long)(int)sizeof(((struct ldlm_extent *)0)->gid));
912 /* Checks for struct ldlm_flock */
913 LASSERTF((int)sizeof(struct ldlm_flock) == 40, " found %llu\n",
914 (unsigned long long)(int)sizeof(struct ldlm_flock));
915 LASSERTF((int)offsetof(struct ldlm_flock, start) == 0, " found %llu\n",
916 (unsigned long long)(int)offsetof(struct ldlm_flock, start));
917 LASSERTF((int)sizeof(((struct ldlm_flock *)0)->start) == 8, " found %llu\n",
918 (unsigned long long)(int)sizeof(((struct ldlm_flock *)0)->start));
919 LASSERTF((int)offsetof(struct ldlm_flock, end) == 8, " found %llu\n",
920 (unsigned long long)(int)offsetof(struct ldlm_flock, end));
921 LASSERTF((int)sizeof(((struct ldlm_flock *)0)->end) == 8, " found %llu\n",
922 (unsigned long long)(int)sizeof(((struct ldlm_flock *)0)->end));
923 LASSERTF((int)offsetof(struct ldlm_flock, pid) == 16, " found %llu\n",
924 (unsigned long long)(int)offsetof(struct ldlm_flock, pid));
925 LASSERTF((int)sizeof(((struct ldlm_flock *)0)->pid) == 8, " found %llu\n",
926 (unsigned long long)(int)sizeof(((struct ldlm_flock *)0)->pid));
927 LASSERTF((int)offsetof(struct ldlm_flock, nid) == 24, " found %llu\n",
928 (unsigned long long)(int)offsetof(struct ldlm_flock, nid));
929 LASSERTF((int)sizeof(((struct ldlm_flock *)0)->nid) == 8, " found %llu\n",
930 (unsigned long long)(int)sizeof(((struct ldlm_flock *)0)->nid));
931 LASSERTF((int)offsetof(struct ldlm_flock, blocking_pid) == 32, " found %llu\n",
932 (unsigned long long)(int)offsetof(struct ldlm_flock, blocking_pid));
933 LASSERTF((int)sizeof(((struct ldlm_flock *)0)->blocking_pid) == 8, " found %llu\n",
934 (unsigned long long)(int)sizeof(((struct ldlm_flock *)0)->blocking_pid));
935 LASSERTF((int)offsetof(struct ldlm_flock, blocking_nid) == 40, " found %llu\n",
936 (unsigned long long)(int)offsetof(struct ldlm_flock, blocking_nid));
937 LASSERTF((int)sizeof(((struct ldlm_flock *)0)->blocking_nid) == 8, " found %llu\n",
938 (unsigned long long)(int)sizeof(((struct ldlm_flock *)0)->blocking_nid));
940 /* Checks for struct ldlm_intent */
941 LASSERTF((int)sizeof(struct ldlm_intent) == 8, " found %llu\n",
942 (unsigned long long)(int)sizeof(struct ldlm_intent));
943 LASSERTF((int)offsetof(struct ldlm_intent, opc) == 0, " found %llu\n",
944 (unsigned long long)(int)offsetof(struct ldlm_intent, opc));
945 LASSERTF((int)sizeof(((struct ldlm_intent *)0)->opc) == 8, " found %llu\n",
946 (unsigned long long)(int)sizeof(((struct ldlm_intent *)0)->opc));
948 /* Checks for struct ldlm_resource_desc */
949 LASSERTF((int)sizeof(struct ldlm_resource_desc) == 40, " found %llu\n",
950 (unsigned long long)(int)sizeof(struct ldlm_resource_desc));
951 LASSERTF((int)offsetof(struct ldlm_resource_desc, lr_type) == 0, " found %llu\n",
952 (unsigned long long)(int)offsetof(struct ldlm_resource_desc, lr_type));
953 LASSERTF((int)sizeof(((struct ldlm_resource_desc *)0)->lr_type) == 4, " found %llu\n",
954 (unsigned long long)(int)sizeof(((struct ldlm_resource_desc *)0)->lr_type));
955 LASSERTF((int)offsetof(struct ldlm_resource_desc, lr_name) == 8, " found %llu\n",
956 (unsigned long long)(int)offsetof(struct ldlm_resource_desc, lr_name));
957 LASSERTF((int)sizeof(((struct ldlm_resource_desc *)0)->lr_name) == 32, " found %llu\n",
958 (unsigned long long)(int)sizeof(((struct ldlm_resource_desc *)0)->lr_name));
960 /* Checks for struct ldlm_lock_desc */
961 LASSERTF((int)sizeof(struct ldlm_lock_desc) == 88, " found %llu\n",
962 (unsigned long long)(int)sizeof(struct ldlm_lock_desc));
963 LASSERTF((int)offsetof(struct ldlm_lock_desc, l_resource) == 0, " found %llu\n",
964 (unsigned long long)(int)offsetof(struct ldlm_lock_desc, l_resource));
965 LASSERTF((int)sizeof(((struct ldlm_lock_desc *)0)->l_resource) == 40, " found %llu\n",
966 (unsigned long long)(int)sizeof(((struct ldlm_lock_desc *)0)->l_resource));
967 LASSERTF((int)offsetof(struct ldlm_lock_desc, l_req_mode) == 40, " found %llu\n",
968 (unsigned long long)(int)offsetof(struct ldlm_lock_desc, l_req_mode));
969 LASSERTF((int)sizeof(((struct ldlm_lock_desc *)0)->l_req_mode) == 4, " found %llu\n",
970 (unsigned long long)(int)sizeof(((struct ldlm_lock_desc *)0)->l_req_mode));
971 LASSERTF((int)offsetof(struct ldlm_lock_desc, l_granted_mode) == 44, " found %llu\n",
972 (unsigned long long)(int)offsetof(struct ldlm_lock_desc, l_granted_mode));
973 LASSERTF((int)sizeof(((struct ldlm_lock_desc *)0)->l_granted_mode) == 4, " found %llu\n",
974 (unsigned long long)(int)sizeof(((struct ldlm_lock_desc *)0)->l_granted_mode));
975 LASSERTF((int)offsetof(struct ldlm_lock_desc, l_policy_data) == 48, " found %llu\n",
976 (unsigned long long)(int)offsetof(struct ldlm_lock_desc, l_policy_data));
977 LASSERTF((int)sizeof(((struct ldlm_lock_desc *)0)->l_policy_data) == 40, " found %llu\n",
978 (unsigned long long)(int)sizeof(((struct ldlm_lock_desc *)0)->l_policy_data));
980 /* Checks for struct ldlm_request */
981 LASSERTF((int)sizeof(struct ldlm_request) == 112, " found %llu\n",
982 (unsigned long long)(int)sizeof(struct ldlm_request));
983 LASSERTF((int)offsetof(struct ldlm_request, lock_flags) == 0, " found %llu\n",
984 (unsigned long long)(int)offsetof(struct ldlm_request, lock_flags));
985 LASSERTF((int)sizeof(((struct ldlm_request *)0)->lock_flags) == 4, " found %llu\n",
986 (unsigned long long)(int)sizeof(((struct ldlm_request *)0)->lock_flags));
987 LASSERTF((int)offsetof(struct ldlm_request, lock_desc) == 8, " found %llu\n",
988 (unsigned long long)(int)offsetof(struct ldlm_request, lock_desc));
989 LASSERTF((int)sizeof(((struct ldlm_request *)0)->lock_desc) == 88, " found %llu\n",
990 (unsigned long long)(int)sizeof(((struct ldlm_request *)0)->lock_desc));
991 LASSERTF((int)offsetof(struct ldlm_request, lock_handle1) == 96, " found %llu\n",
992 (unsigned long long)(int)offsetof(struct ldlm_request, lock_handle1));
993 LASSERTF((int)sizeof(((struct ldlm_request *)0)->lock_handle1) == 8, " found %llu\n",
994 (unsigned long long)(int)sizeof(((struct ldlm_request *)0)->lock_handle1));
995 LASSERTF((int)offsetof(struct ldlm_request, lock_handle2) == 104, " found %llu\n",
996 (unsigned long long)(int)offsetof(struct ldlm_request, lock_handle2));
997 LASSERTF((int)sizeof(((struct ldlm_request *)0)->lock_handle2) == 8, " found %llu\n",
998 (unsigned long long)(int)sizeof(((struct ldlm_request *)0)->lock_handle2));
1000 /* Checks for struct ldlm_reply */
1001 LASSERTF((int)sizeof(struct ldlm_reply) == 120, " found %llu\n",
1002 (unsigned long long)(int)sizeof(struct ldlm_reply));
1003 LASSERTF((int)offsetof(struct ldlm_reply, lock_flags) == 0, " found %llu\n",
1004 (unsigned long long)(int)offsetof(struct ldlm_reply, lock_flags));
1005 LASSERTF((int)sizeof(((struct ldlm_reply *)0)->lock_flags) == 4, " found %llu\n",
1006 (unsigned long long)(int)sizeof(((struct ldlm_reply *)0)->lock_flags));
1007 LASSERTF((int)offsetof(struct ldlm_request, lock_desc) == 8, " found %llu\n",
1008 (unsigned long long)(int)offsetof(struct ldlm_request, lock_desc));
1009 LASSERTF((int)sizeof(((struct ldlm_request *)0)->lock_desc) == 88, " found %llu\n",
1010 (unsigned long long)(int)sizeof(((struct ldlm_request *)0)->lock_desc));
1011 LASSERTF((int)offsetof(struct ldlm_reply, lock_handle) == 96, " found %llu\n",
1012 (unsigned long long)(int)offsetof(struct ldlm_reply, lock_handle));
1013 LASSERTF((int)sizeof(((struct ldlm_reply *)0)->lock_handle) == 8, " found %llu\n",
1014 (unsigned long long)(int)sizeof(((struct ldlm_reply *)0)->lock_handle));
1015 LASSERTF((int)offsetof(struct ldlm_reply, lock_policy_res1) == 104, " found %llu\n",
1016 (unsigned long long)(int)offsetof(struct ldlm_reply, lock_policy_res1));
1017 LASSERTF((int)sizeof(((struct ldlm_reply *)0)->lock_policy_res1) == 8, " found %llu\n",
1018 (unsigned long long)(int)sizeof(((struct ldlm_reply *)0)->lock_policy_res1));
1019 LASSERTF((int)offsetof(struct ldlm_reply, lock_policy_res2) == 112, " found %llu\n",
1020 (unsigned long long)(int)offsetof(struct ldlm_reply, lock_policy_res2));
1021 LASSERTF((int)sizeof(((struct ldlm_reply *)0)->lock_policy_res2) == 8, " found %llu\n",
1022 (unsigned long long)(int)sizeof(((struct ldlm_reply *)0)->lock_policy_res2));
1024 /* Checks for struct ost_lvb */
1025 LASSERTF((int)sizeof(struct ost_lvb) == 40, " found %llu\n",
1026 (unsigned long long)(int)sizeof(struct ost_lvb));
1027 LASSERTF((int)offsetof(struct ost_lvb, lvb_size) == 0, " found %llu\n",
1028 (unsigned long long)(int)offsetof(struct ost_lvb, lvb_size));
1029 LASSERTF((int)sizeof(((struct ost_lvb *)0)->lvb_size) == 8, " found %llu\n",
1030 (unsigned long long)(int)sizeof(((struct ost_lvb *)0)->lvb_size));
1031 LASSERTF((int)offsetof(struct ost_lvb, lvb_mtime) == 8, " found %llu\n",
1032 (unsigned long long)(int)offsetof(struct ost_lvb, lvb_mtime));
1033 LASSERTF((int)sizeof(((struct ost_lvb *)0)->lvb_mtime) == 8, " found %llu\n",
1034 (unsigned long long)(int)sizeof(((struct ost_lvb *)0)->lvb_mtime));
1035 LASSERTF((int)offsetof(struct ost_lvb, lvb_atime) == 16, " found %llu\n",
1036 (unsigned long long)(int)offsetof(struct ost_lvb, lvb_atime));
1037 LASSERTF((int)sizeof(((struct ost_lvb *)0)->lvb_atime) == 8, " found %llu\n",
1038 (unsigned long long)(int)sizeof(((struct ost_lvb *)0)->lvb_atime));
1039 LASSERTF((int)offsetof(struct ost_lvb, lvb_ctime) == 24, " found %llu\n",
1040 (unsigned long long)(int)offsetof(struct ost_lvb, lvb_ctime));
1041 LASSERTF((int)sizeof(((struct ost_lvb *)0)->lvb_ctime) == 8, " found %llu\n",
1042 (unsigned long long)(int)sizeof(((struct ost_lvb *)0)->lvb_ctime));
1043 LASSERTF((int)offsetof(struct ost_lvb, lvb_blocks) == 32, " found %llu\n",
1044 (unsigned long long)(int)offsetof(struct ost_lvb, lvb_blocks));
1045 LASSERTF((int)sizeof(((struct ost_lvb *)0)->lvb_blocks) == 8, " found %llu\n",
1046 (unsigned long long)(int)sizeof(((struct ost_lvb *)0)->lvb_blocks));
1048 /* Checks for struct ptlbd_op */
1049 LASSERTF((int)sizeof(struct ptlbd_op) == 12, " found %llu\n",
1050 (unsigned long long)(int)sizeof(struct ptlbd_op));
1051 LASSERTF((int)offsetof(struct ptlbd_op, op_cmd) == 0, " found %llu\n",
1052 (unsigned long long)(int)offsetof(struct ptlbd_op, op_cmd));
1053 LASSERTF((int)sizeof(((struct ptlbd_op *)0)->op_cmd) == 2, " found %llu\n",
1054 (unsigned long long)(int)sizeof(((struct ptlbd_op *)0)->op_cmd));
1055 LASSERTF((int)offsetof(struct ptlbd_op, op_lun) == 2, " found %llu\n",
1056 (unsigned long long)(int)offsetof(struct ptlbd_op, op_lun));
1057 LASSERTF((int)sizeof(((struct ptlbd_op *)0)->op_lun) == 2, " found %llu\n",
1058 (unsigned long long)(int)sizeof(((struct ptlbd_op *)0)->op_lun));
1059 LASSERTF((int)offsetof(struct ptlbd_op, op_niob_cnt) == 4, " found %llu\n",
1060 (unsigned long long)(int)offsetof(struct ptlbd_op, op_niob_cnt));
1061 LASSERTF((int)sizeof(((struct ptlbd_op *)0)->op_niob_cnt) == 2, " found %llu\n",
1062 (unsigned long long)(int)sizeof(((struct ptlbd_op *)0)->op_niob_cnt));
1063 LASSERTF((int)offsetof(struct ptlbd_op, op__padding) == 6, " found %llu\n",
1064 (unsigned long long)(int)offsetof(struct ptlbd_op, op__padding));
1065 LASSERTF((int)sizeof(((struct ptlbd_op *)0)->op__padding) == 2, " found %llu\n",
1066 (unsigned long long)(int)sizeof(((struct ptlbd_op *)0)->op__padding));
1067 LASSERTF((int)offsetof(struct ptlbd_op, op_block_cnt) == 8, " found %llu\n",
1068 (unsigned long long)(int)offsetof(struct ptlbd_op, op_block_cnt));
1069 LASSERTF((int)sizeof(((struct ptlbd_op *)0)->op_block_cnt) == 4, " found %llu\n",
1070 (unsigned long long)(int)sizeof(((struct ptlbd_op *)0)->op_block_cnt));
1072 /* Checks for struct ptlbd_niob */
1073 LASSERTF((int)sizeof(struct ptlbd_niob) == 24, " found %llu\n",
1074 (unsigned long long)(int)sizeof(struct ptlbd_niob));
1075 LASSERTF((int)offsetof(struct ptlbd_niob, n_xid) == 0, " found %llu\n",
1076 (unsigned long long)(int)offsetof(struct ptlbd_niob, n_xid));
1077 LASSERTF((int)sizeof(((struct ptlbd_niob *)0)->n_xid) == 8, " found %llu\n",
1078 (unsigned long long)(int)sizeof(((struct ptlbd_niob *)0)->n_xid));
1079 LASSERTF((int)offsetof(struct ptlbd_niob, n_block_nr) == 8, " found %llu\n",
1080 (unsigned long long)(int)offsetof(struct ptlbd_niob, n_block_nr));
1081 LASSERTF((int)sizeof(((struct ptlbd_niob *)0)->n_block_nr) == 8, " found %llu\n",
1082 (unsigned long long)(int)sizeof(((struct ptlbd_niob *)0)->n_block_nr));
1083 LASSERTF((int)offsetof(struct ptlbd_niob, n_offset) == 16, " found %llu\n",
1084 (unsigned long long)(int)offsetof(struct ptlbd_niob, n_offset));
1085 LASSERTF((int)sizeof(((struct ptlbd_niob *)0)->n_offset) == 4, " found %llu\n",
1086 (unsigned long long)(int)sizeof(((struct ptlbd_niob *)0)->n_offset));
1087 LASSERTF((int)offsetof(struct ptlbd_niob, n_length) == 20, " found %llu\n",
1088 (unsigned long long)(int)offsetof(struct ptlbd_niob, n_length));
1089 LASSERTF((int)sizeof(((struct ptlbd_niob *)0)->n_length) == 4, " found %llu\n",
1090 (unsigned long long)(int)sizeof(((struct ptlbd_niob *)0)->n_length));
1092 /* Checks for struct ptlbd_rsp */
1093 LASSERTF((int)sizeof(struct ptlbd_rsp) == 4, " found %llu\n",
1094 (unsigned long long)(int)sizeof(struct ptlbd_rsp));
1095 LASSERTF((int)offsetof(struct ptlbd_rsp, r_status) == 0, " found %llu\n",
1096 (unsigned long long)(int)offsetof(struct ptlbd_rsp, r_status));
1097 LASSERTF((int)sizeof(((struct ptlbd_rsp *)0)->r_status) == 2, " found %llu\n",
1098 (unsigned long long)(int)sizeof(((struct ptlbd_rsp *)0)->r_status));
1099 LASSERTF((int)offsetof(struct ptlbd_rsp, r_error_cnt) == 2, " found %llu\n",
1100 (unsigned long long)(int)offsetof(struct ptlbd_rsp, r_error_cnt));
1101 LASSERTF((int)sizeof(((struct ptlbd_rsp *)0)->r_error_cnt) == 2, " found %llu\n",
1102 (unsigned long long)(int)sizeof(((struct ptlbd_rsp *)0)->r_error_cnt));
1104 /* Checks for struct llog_logid */
1105 LASSERTF((int)sizeof(struct llog_logid) == 20, " found %llu\n",
1106 (unsigned long long)(int)sizeof(struct llog_logid));
1107 LASSERTF((int)offsetof(struct llog_logid, lgl_oid) == 0, " found %llu\n",
1108 (unsigned long long)(int)offsetof(struct llog_logid, lgl_oid));
1109 LASSERTF((int)sizeof(((struct llog_logid *)0)->lgl_oid) == 8, " found %llu\n",
1110 (unsigned long long)(int)sizeof(((struct llog_logid *)0)->lgl_oid));
1111 LASSERTF((int)offsetof(struct llog_logid, lgl_ogr) == 8, " found %llu\n",
1112 (unsigned long long)(int)offsetof(struct llog_logid, lgl_ogr));
1113 LASSERTF((int)sizeof(((struct llog_logid *)0)->lgl_ogr) == 8, " found %llu\n",
1114 (unsigned long long)(int)sizeof(((struct llog_logid *)0)->lgl_ogr));
1115 LASSERTF((int)offsetof(struct llog_logid, lgl_ogen) == 16, " found %llu\n",
1116 (unsigned long long)(int)offsetof(struct llog_logid, lgl_ogen));
1117 LASSERTF((int)sizeof(((struct llog_logid *)0)->lgl_ogen) == 4, " found %llu\n",
1118 (unsigned long long)(int)sizeof(((struct llog_logid *)0)->lgl_ogen));
1119 LASSERTF(OST_SZ_REC == 274730752, " found %llu\n",
1120 (unsigned long long)OST_SZ_REC);
1121 LASSERTF(OST_RAID1_REC == 274731008, " found %llu\n",
1122 (unsigned long long)OST_RAID1_REC);
1123 LASSERTF(MDS_UNLINK_REC == 274801668, " found %llu\n",
1124 (unsigned long long)MDS_UNLINK_REC);
1125 LASSERTF(OBD_CFG_REC == 274857984, " found %llu\n",
1126 (unsigned long long)OBD_CFG_REC);
1127 LASSERTF(PTL_CFG_REC == 274923520, " found %llu\n",
1128 (unsigned long long)PTL_CFG_REC);
1129 LASSERTF(LLOG_GEN_REC == 274989056, " found %llu\n",
1130 (unsigned long long)LLOG_GEN_REC);
1131 LASSERTF(LLOG_HDR_MAGIC == 275010873, " found %llu\n",
1132 (unsigned long long)LLOG_HDR_MAGIC);
1133 LASSERTF(LLOG_LOGID_MAGIC == 275010875, " found %llu\n",
1134 (unsigned long long)LLOG_LOGID_MAGIC);
1136 /* Checks for struct llog_catid */
1137 LASSERTF((int)sizeof(struct llog_catid) == 32, " found %llu\n",
1138 (unsigned long long)(int)sizeof(struct llog_catid));
1139 LASSERTF((int)offsetof(struct llog_catid, lci_logid) == 0, " found %llu\n",
1140 (unsigned long long)(int)offsetof(struct llog_catid, lci_logid));
1141 LASSERTF((int)sizeof(((struct llog_catid *)0)->lci_logid) == 20, " found %llu\n",
1142 (unsigned long long)(int)sizeof(((struct llog_catid *)0)->lci_logid));
1144 /* Checks for struct llog_rec_hdr */
1145 LASSERTF((int)sizeof(struct llog_rec_hdr) == 16, " found %llu\n",
1146 (unsigned long long)(int)sizeof(struct llog_rec_hdr));
1147 LASSERTF((int)offsetof(struct llog_rec_hdr, lrh_len) == 0, " found %llu\n",
1148 (unsigned long long)(int)offsetof(struct llog_rec_hdr, lrh_len));
1149 LASSERTF((int)sizeof(((struct llog_rec_hdr *)0)->lrh_len) == 4, " found %llu\n",
1150 (unsigned long long)(int)sizeof(((struct llog_rec_hdr *)0)->lrh_len));
1151 LASSERTF((int)offsetof(struct llog_rec_hdr, lrh_index) == 4, " found %llu\n",
1152 (unsigned long long)(int)offsetof(struct llog_rec_hdr, lrh_index));
1153 LASSERTF((int)sizeof(((struct llog_rec_hdr *)0)->lrh_index) == 4, " found %llu\n",
1154 (unsigned long long)(int)sizeof(((struct llog_rec_hdr *)0)->lrh_index));
1155 LASSERTF((int)offsetof(struct llog_rec_hdr, lrh_type) == 8, " found %llu\n",
1156 (unsigned long long)(int)offsetof(struct llog_rec_hdr, lrh_type));
1157 LASSERTF((int)sizeof(((struct llog_rec_hdr *)0)->lrh_type) == 4, " found %llu\n",
1158 (unsigned long long)(int)sizeof(((struct llog_rec_hdr *)0)->lrh_type));
1160 /* Checks for struct llog_rec_tail */
1161 LASSERTF((int)sizeof(struct llog_rec_tail) == 8, " found %llu\n",
1162 (unsigned long long)(int)sizeof(struct llog_rec_tail));
1163 LASSERTF((int)offsetof(struct llog_rec_tail, lrt_len) == 0, " found %llu\n",
1164 (unsigned long long)(int)offsetof(struct llog_rec_tail, lrt_len));
1165 LASSERTF((int)sizeof(((struct llog_rec_tail *)0)->lrt_len) == 4, " found %llu\n",
1166 (unsigned long long)(int)sizeof(((struct llog_rec_tail *)0)->lrt_len));
1167 LASSERTF((int)offsetof(struct llog_rec_tail, lrt_index) == 4, " found %llu\n",
1168 (unsigned long long)(int)offsetof(struct llog_rec_tail, lrt_index));
1169 LASSERTF((int)sizeof(((struct llog_rec_tail *)0)->lrt_index) == 4, " found %llu\n",
1170 (unsigned long long)(int)sizeof(((struct llog_rec_tail *)0)->lrt_index));
1172 /* Checks for struct llog_logid_rec */
1173 LASSERTF((int)sizeof(struct llog_logid_rec) == 64, " found %llu\n",
1174 (unsigned long long)(int)sizeof(struct llog_logid_rec));
1175 LASSERTF((int)offsetof(struct llog_logid_rec, lid_hdr) == 0, " found %llu\n",
1176 (unsigned long long)(int)offsetof(struct llog_logid_rec, lid_hdr));
1177 LASSERTF((int)sizeof(((struct llog_logid_rec *)0)->lid_hdr) == 16, " found %llu\n",
1178 (unsigned long long)(int)sizeof(((struct llog_logid_rec *)0)->lid_hdr));
1179 LASSERTF((int)offsetof(struct llog_logid_rec, lid_id) == 16, " found %llu\n",
1180 (unsigned long long)(int)offsetof(struct llog_logid_rec, lid_id));
1181 LASSERTF((int)sizeof(((struct llog_logid_rec *)0)->lid_id) == 20, " found %llu\n",
1182 (unsigned long long)(int)sizeof(((struct llog_logid_rec *)0)->lid_id));
1183 LASSERTF((int)offsetof(struct llog_logid_rec, lid_tail) == 56, " found %llu\n",
1184 (unsigned long long)(int)offsetof(struct llog_logid_rec, lid_tail));
1185 LASSERTF((int)sizeof(((struct llog_logid_rec *)0)->lid_tail) == 8, " found %llu\n",
1186 (unsigned long long)(int)sizeof(((struct llog_logid_rec *)0)->lid_tail));
1188 /* Checks for struct llog_create_rec */
1189 LASSERTF((int)sizeof(struct llog_create_rec) == 72, " found %llu\n",
1190 (unsigned long long)(int)sizeof(struct llog_create_rec));
1191 LASSERTF((int)offsetof(struct llog_create_rec, lcr_hdr) == 0, " found %llu\n",
1192 (unsigned long long)(int)offsetof(struct llog_create_rec, lcr_hdr));
1193 LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_hdr) == 16, " found %llu\n",
1194 (unsigned long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_hdr));
1195 LASSERTF((int)offsetof(struct llog_create_rec, lcr_id) == 16, " found %llu\n",
1196 (unsigned long long)(int)offsetof(struct llog_create_rec, lcr_id));
1197 LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_id) == 32, " found %llu\n",
1198 (unsigned long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_id));
1199 LASSERTF((int)offsetof(struct llog_create_rec, lcr_oid) == 48, " found %llu\n",
1200 (unsigned long long)(int)offsetof(struct llog_create_rec, lcr_oid));
1201 LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_oid) == 8, " found %llu\n",
1202 (unsigned long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_oid));
1203 LASSERTF((int)offsetof(struct llog_create_rec, lcr_ogen) == 56, " found %llu\n",
1204 (unsigned long long)(int)offsetof(struct llog_create_rec, lcr_ogen));
1205 LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_ogen) == 4, " found %llu\n",
1206 (unsigned long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_ogen));
1208 /* Checks for struct llog_orphan_rec */
1209 LASSERTF((int)sizeof(struct llog_orphan_rec) == 40, " found %llu\n",
1210 (unsigned long long)(int)sizeof(struct llog_orphan_rec));
1211 LASSERTF((int)offsetof(struct llog_orphan_rec, lor_hdr) == 0, " found %llu\n",
1212 (unsigned long long)(int)offsetof(struct llog_orphan_rec, lor_hdr));
1213 LASSERTF((int)sizeof(((struct llog_orphan_rec *)0)->lor_hdr) == 16, " found %llu\n",
1214 (unsigned long long)(int)sizeof(((struct llog_orphan_rec *)0)->lor_hdr));
1215 LASSERTF((int)offsetof(struct llog_orphan_rec, lor_oid) == 16, " found %llu\n",
1216 (unsigned long long)(int)offsetof(struct llog_orphan_rec, lor_oid));
1217 LASSERTF((int)sizeof(((struct llog_orphan_rec *)0)->lor_oid) == 8, " found %llu\n",
1218 (unsigned long long)(int)sizeof(((struct llog_orphan_rec *)0)->lor_oid));
1219 LASSERTF((int)offsetof(struct llog_orphan_rec, lor_ogen) == 24, " found %llu\n",
1220 (unsigned long long)(int)offsetof(struct llog_orphan_rec, lor_ogen));
1221 LASSERTF((int)sizeof(((struct llog_orphan_rec *)0)->lor_ogen) == 4, " found %llu\n",
1222 (unsigned long long)(int)sizeof(((struct llog_orphan_rec *)0)->lor_ogen));
1223 LASSERTF((int)offsetof(struct llog_orphan_rec, lor_tail) == 32, " found %llu\n",
1224 (unsigned long long)(int)offsetof(struct llog_orphan_rec, lor_tail));
1225 LASSERTF((int)sizeof(((struct llog_orphan_rec *)0)->lor_tail) == 8, " found %llu\n",
1226 (unsigned long long)(int)sizeof(((struct llog_orphan_rec *)0)->lor_tail));
1228 /* Checks for struct llog_unlink_rec */
1229 LASSERTF((int)sizeof(struct llog_unlink_rec) == 40, " found %llu\n",
1230 (unsigned long long)(int)sizeof(struct llog_unlink_rec));
1231 LASSERTF((int)offsetof(struct llog_unlink_rec, lur_hdr) == 0, " found %llu\n",
1232 (unsigned long long)(int)offsetof(struct llog_unlink_rec, lur_hdr));
1233 LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_hdr) == 16, " found %llu\n",
1234 (unsigned long long)(int)sizeof(((struct llog_unlink_rec *)0)->lur_hdr));
1235 LASSERTF((int)offsetof(struct llog_unlink_rec, lur_oid) == 16, " found %llu\n",
1236 (unsigned long long)(int)offsetof(struct llog_unlink_rec, lur_oid));
1237 LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_oid) == 8, " found %llu\n",
1238 (unsigned long long)(int)sizeof(((struct llog_unlink_rec *)0)->lur_oid));
1239 LASSERTF((int)offsetof(struct llog_unlink_rec, lur_ogen) == 24, " found %llu\n",
1240 (unsigned long long)(int)offsetof(struct llog_unlink_rec, lur_ogen));
1241 LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_ogen) == 4, " found %llu\n",
1242 (unsigned long long)(int)sizeof(((struct llog_unlink_rec *)0)->lur_ogen));
1243 LASSERTF((int)offsetof(struct llog_unlink_rec, lur_tail) == 32, " found %llu\n",
1244 (unsigned long long)(int)offsetof(struct llog_unlink_rec, lur_tail));
1245 LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_tail) == 8, " found %llu\n",
1246 (unsigned long long)(int)sizeof(((struct llog_unlink_rec *)0)->lur_tail));
1248 /* Checks for struct llog_size_change_rec */
1249 LASSERTF((int)sizeof(struct llog_size_change_rec) == 64, " found %llu\n",
1250 (unsigned long long)(int)sizeof(struct llog_size_change_rec));
1251 LASSERTF((int)offsetof(struct llog_size_change_rec, lsc_hdr) == 0, " found %llu\n",
1252 (unsigned long long)(int)offsetof(struct llog_size_change_rec, lsc_hdr));
1253 LASSERTF((int)sizeof(((struct llog_size_change_rec *)0)->lsc_hdr) == 16, " found %llu\n",
1254 (unsigned long long)(int)sizeof(((struct llog_size_change_rec *)0)->lsc_hdr));
1255 LASSERTF((int)offsetof(struct llog_size_change_rec, lsc_id) == 16, " found %llu\n",
1256 (unsigned long long)(int)offsetof(struct llog_size_change_rec, lsc_id));
1257 LASSERTF((int)sizeof(((struct llog_size_change_rec *)0)->lsc_id) == 32, " found %llu\n",
1258 (unsigned long long)(int)sizeof(((struct llog_size_change_rec *)0)->lsc_id));
1259 LASSERTF((int)offsetof(struct llog_size_change_rec, lsc_io_epoch) == 48, " found %llu\n",
1260 (unsigned long long)(int)offsetof(struct llog_size_change_rec, lsc_io_epoch));
1261 LASSERTF((int)sizeof(((struct llog_size_change_rec *)0)->lsc_io_epoch) == 4, " found %llu\n",
1262 (unsigned long long)(int)sizeof(((struct llog_size_change_rec *)0)->lsc_io_epoch));
1263 LASSERTF((int)offsetof(struct llog_size_change_rec, lsc_tail) == 56, " found %llu\n",
1264 (unsigned long long)(int)offsetof(struct llog_size_change_rec, lsc_tail));
1265 LASSERTF((int)sizeof(((struct llog_size_change_rec *)0)->lsc_tail) == 8, " found %llu\n",
1266 (unsigned long long)(int)sizeof(((struct llog_size_change_rec *)0)->lsc_tail));
1268 /* Checks for struct llog_gen */
1269 LASSERTF((int)sizeof(struct llog_gen) == 16, " found %llu\n",
1270 (unsigned long long)(int)sizeof(struct llog_gen));
1271 LASSERTF((int)offsetof(struct llog_gen, mnt_cnt) == 0, " found %llu\n",
1272 (unsigned long long)(int)offsetof(struct llog_gen, mnt_cnt));
1273 LASSERTF((int)sizeof(((struct llog_gen *)0)->mnt_cnt) == 8, " found %llu\n",
1274 (unsigned long long)(int)sizeof(((struct llog_gen *)0)->mnt_cnt));
1275 LASSERTF((int)offsetof(struct llog_gen, conn_cnt) == 8, " found %llu\n",
1276 (unsigned long long)(int)offsetof(struct llog_gen, conn_cnt));
1277 LASSERTF((int)sizeof(((struct llog_gen *)0)->conn_cnt) == 8, " found %llu\n",
1278 (unsigned long long)(int)sizeof(((struct llog_gen *)0)->conn_cnt));
1280 /* Checks for struct llog_gen_rec */
1281 LASSERTF((int)sizeof(struct llog_gen_rec) == 40, " found %llu\n",
1282 (unsigned long long)(int)sizeof(struct llog_gen_rec));
1283 LASSERTF((int)offsetof(struct llog_gen_rec, lgr_hdr) == 0, " found %llu\n",
1284 (unsigned long long)(int)offsetof(struct llog_gen_rec, lgr_hdr));
1285 LASSERTF((int)sizeof(((struct llog_gen_rec *)0)->lgr_hdr) == 16, " found %llu\n",
1286 (unsigned long long)(int)sizeof(((struct llog_gen_rec *)0)->lgr_hdr));
1287 LASSERTF((int)offsetof(struct llog_gen_rec, lgr_gen) == 16, " found %llu\n",
1288 (unsigned long long)(int)offsetof(struct llog_gen_rec, lgr_gen));
1289 LASSERTF((int)sizeof(((struct llog_gen_rec *)0)->lgr_gen) == 16, " found %llu\n",
1290 (unsigned long long)(int)sizeof(((struct llog_gen_rec *)0)->lgr_gen));
1291 LASSERTF((int)offsetof(struct llog_gen_rec, lgr_tail) == 32, " found %llu\n",
1292 (unsigned long long)(int)offsetof(struct llog_gen_rec, lgr_tail));
1293 LASSERTF((int)sizeof(((struct llog_gen_rec *)0)->lgr_tail) == 8, " found %llu\n",
1294 (unsigned long long)(int)sizeof(((struct llog_gen_rec *)0)->lgr_tail));
1296 /* Checks for struct llog_log_hdr */
1297 LASSERTF((int)sizeof(struct llog_log_hdr) == 8192, " found %llu\n",
1298 (unsigned long long)(int)sizeof(struct llog_log_hdr));
1299 LASSERTF((int)offsetof(struct llog_log_hdr, llh_hdr) == 0, " found %llu\n",
1300 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_hdr));
1301 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_hdr) == 16, " found %llu\n",
1302 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_hdr));
1303 LASSERTF((int)offsetof(struct llog_log_hdr, llh_timestamp) == 16, " found %llu\n",
1304 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_timestamp));
1305 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_timestamp) == 8, " found %llu\n",
1306 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_timestamp));
1307 LASSERTF((int)offsetof(struct llog_log_hdr, llh_count) == 24, " found %llu\n",
1308 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_count));
1309 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_count) == 4, " found %llu\n",
1310 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_count));
1311 LASSERTF((int)offsetof(struct llog_log_hdr, llh_bitmap_offset) == 28, " found %llu\n",
1312 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_bitmap_offset));
1313 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_bitmap_offset) == 4, " found %llu\n",
1314 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_bitmap_offset));
1315 LASSERTF((int)offsetof(struct llog_log_hdr, llh_size) == 32, " found %llu\n",
1316 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_size));
1317 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_size) == 4, " found %llu\n",
1318 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_size));
1319 LASSERTF((int)offsetof(struct llog_log_hdr, llh_flags) == 36, " found %llu\n",
1320 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_flags));
1321 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_flags) == 4, " found %llu\n",
1322 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_flags));
1323 LASSERTF((int)offsetof(struct llog_log_hdr, llh_cat_idx) == 40, " found %llu\n",
1324 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_cat_idx));
1325 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_cat_idx) == 4, " found %llu\n",
1326 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_cat_idx));
1327 LASSERTF((int)offsetof(struct llog_log_hdr, llh_tgtuuid) == 44, " found %llu\n",
1328 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_tgtuuid));
1329 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_tgtuuid) == 40, " found %llu\n",
1330 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_tgtuuid));
1331 LASSERTF((int)offsetof(struct llog_log_hdr, llh_bitmap) == 88, " found %llu\n",
1332 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_bitmap));
1333 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_bitmap) == 8096, " found %llu\n",
1334 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_bitmap));
1335 LASSERTF((int)offsetof(struct llog_log_hdr, llh_tail) == 8184, " found %llu\n",
1336 (unsigned long long)(int)offsetof(struct llog_log_hdr, llh_tail));
1337 LASSERTF((int)sizeof(((struct llog_log_hdr *)0)->llh_tail) == 8, " found %llu\n",
1338 (unsigned long long)(int)sizeof(((struct llog_log_hdr *)0)->llh_tail));
1340 /* Checks for struct llog_cookie */
1341 LASSERTF((int)sizeof(struct llog_cookie) == 32, " found %llu\n",
1342 (unsigned long long)(int)sizeof(struct llog_cookie));
1343 LASSERTF((int)offsetof(struct llog_cookie, lgc_lgl) == 0, " found %llu\n",
1344 (unsigned long long)(int)offsetof(struct llog_cookie, lgc_lgl));
1345 LASSERTF((int)sizeof(((struct llog_cookie *)0)->lgc_lgl) == 20, " found %llu\n",
1346 (unsigned long long)(int)sizeof(((struct llog_cookie *)0)->lgc_lgl));
1347 LASSERTF((int)offsetof(struct llog_cookie, lgc_subsys) == 20, " found %llu\n",
1348 (unsigned long long)(int)offsetof(struct llog_cookie, lgc_subsys));
1349 LASSERTF((int)sizeof(((struct llog_cookie *)0)->lgc_subsys) == 4, " found %llu\n",
1350 (unsigned long long)(int)sizeof(((struct llog_cookie *)0)->lgc_subsys));
1351 LASSERTF((int)offsetof(struct llog_cookie, lgc_index) == 24, " found %llu\n",
1352 (unsigned long long)(int)offsetof(struct llog_cookie, lgc_index));
1353 LASSERTF((int)sizeof(((struct llog_cookie *)0)->lgc_index) == 4, " found %llu\n",
1354 (unsigned long long)(int)sizeof(((struct llog_cookie *)0)->lgc_index));
1356 /* Checks for struct llogd_body */
1357 LASSERTF((int)sizeof(struct llogd_body) == 48, " found %llu\n",
1358 (unsigned long long)(int)sizeof(struct llogd_body));
1359 LASSERTF((int)offsetof(struct llogd_body, lgd_logid) == 0, " found %llu\n",
1360 (unsigned long long)(int)offsetof(struct llogd_body, lgd_logid));
1361 LASSERTF((int)sizeof(((struct llogd_body *)0)->lgd_logid) == 20, " found %llu\n",
1362 (unsigned long long)(int)sizeof(((struct llogd_body *)0)->lgd_logid));
1363 LASSERTF((int)offsetof(struct llogd_body, lgd_ctxt_idx) == 20, " found %llu\n",
1364 (unsigned long long)(int)offsetof(struct llogd_body, lgd_ctxt_idx));
1365 LASSERTF((int)sizeof(((struct llogd_body *)0)->lgd_ctxt_idx) == 4, " found %llu\n",
1366 (unsigned long long)(int)sizeof(((struct llogd_body *)0)->lgd_ctxt_idx));
1367 LASSERTF((int)offsetof(struct llogd_body, lgd_llh_flags) == 24, " found %llu\n",
1368 (unsigned long long)(int)offsetof(struct llogd_body, lgd_llh_flags));
1369 LASSERTF((int)sizeof(((struct llogd_body *)0)->lgd_llh_flags) == 4, " found %llu\n",
1370 (unsigned long long)(int)sizeof(((struct llogd_body *)0)->lgd_llh_flags));
1371 LASSERTF((int)offsetof(struct llogd_body, lgd_index) == 28, " found %llu\n",
1372 (unsigned long long)(int)offsetof(struct llogd_body, lgd_index));
1373 LASSERTF((int)sizeof(((struct llogd_body *)0)->lgd_index) == 4, " found %llu\n",
1374 (unsigned long long)(int)sizeof(((struct llogd_body *)0)->lgd_index));
1375 LASSERTF((int)offsetof(struct llogd_body, lgd_saved_index) == 32, " found %llu\n",
1376 (unsigned long long)(int)offsetof(struct llogd_body, lgd_saved_index));
1377 LASSERTF((int)sizeof(((struct llogd_body *)0)->lgd_saved_index) == 4, " found %llu\n",
1378 (unsigned long long)(int)sizeof(((struct llogd_body *)0)->lgd_saved_index));
1379 LASSERTF((int)offsetof(struct llogd_body, lgd_len) == 36, " found %llu\n",
1380 (unsigned long long)(int)offsetof(struct llogd_body, lgd_len));
1381 LASSERTF((int)sizeof(((struct llogd_body *)0)->lgd_len) == 4, " found %llu\n",
1382 (unsigned long long)(int)sizeof(((struct llogd_body *)0)->lgd_len));
1383 LASSERTF((int)offsetof(struct llogd_body, lgd_cur_offset) == 40, " found %llu\n",
1384 (unsigned long long)(int)offsetof(struct llogd_body, lgd_cur_offset));
1385 LASSERTF((int)sizeof(((struct llogd_body *)0)->lgd_cur_offset) == 8, " found %llu\n",
1386 (unsigned long long)(int)sizeof(((struct llogd_body *)0)->lgd_cur_offset));
1387 LASSERTF(LLOG_ORIGIN_HANDLE_OPEN == 501, " found %llu\n",
1388 (unsigned long long)LLOG_ORIGIN_HANDLE_OPEN);
1389 LASSERTF(LLOG_ORIGIN_HANDLE_NEXT_BLOCK == 502, " found %llu\n",
1390 (unsigned long long)LLOG_ORIGIN_HANDLE_NEXT_BLOCK);
1391 LASSERTF(LLOG_ORIGIN_HANDLE_READ_HEADER == 503, " found %llu\n",
1392 (unsigned long long)LLOG_ORIGIN_HANDLE_READ_HEADER);
1393 LASSERTF(LLOG_ORIGIN_HANDLE_WRITE_REC == 504, " found %llu\n",
1394 (unsigned long long)LLOG_ORIGIN_HANDLE_WRITE_REC);
1395 LASSERTF(LLOG_ORIGIN_HANDLE_CLOSE == 505, " found %llu\n",
1396 (unsigned long long)LLOG_ORIGIN_HANDLE_CLOSE);
1397 LASSERTF(LLOG_ORIGIN_CONNECT == 506, " found %llu\n",
1398 (unsigned long long)LLOG_ORIGIN_CONNECT);
1399 LASSERTF(LLOG_CATINFO == 507, " found %llu\n",
1400 (unsigned long long)LLOG_CATINFO);
1402 /* Checks for struct llogd_conn_body */
1403 LASSERTF((int)sizeof(struct llogd_conn_body) == 40, " found %llu\n",
1404 (unsigned long long)(int)sizeof(struct llogd_conn_body));
1405 LASSERTF((int)offsetof(struct llogd_conn_body, lgdc_gen) == 0, " found %llu\n",
1406 (unsigned long long)(int)offsetof(struct llogd_conn_body, lgdc_gen));
1407 LASSERTF((int)sizeof(((struct llogd_conn_body *)0)->lgdc_gen) == 16, " found %llu\n",
1408 (unsigned long long)(int)sizeof(((struct llogd_conn_body *)0)->lgdc_gen));
1409 LASSERTF((int)offsetof(struct llogd_conn_body, lgdc_logid) == 16, " found %llu\n",
1410 (unsigned long long)(int)offsetof(struct llogd_conn_body, lgdc_logid));
1411 LASSERTF((int)sizeof(((struct llogd_conn_body *)0)->lgdc_logid) == 20, " found %llu\n",
1412 (unsigned long long)(int)sizeof(((struct llogd_conn_body *)0)->lgdc_logid));
1413 LASSERTF((int)offsetof(struct llogd_conn_body, lgdc_ctxt_idx) == 36, " found %llu\n",
1414 (unsigned long long)(int)offsetof(struct llogd_conn_body, lgdc_ctxt_idx));
1415 LASSERTF((int)sizeof(((struct llogd_conn_body *)0)->lgdc_ctxt_idx) == 4, " found %llu\n",
1416 (unsigned long long)(int)sizeof(((struct llogd_conn_body *)0)->lgdc_ctxt_idx));
1418 /* Checks for struct lustre_capa */
1419 LASSERTF((int)sizeof(struct lustre_capa) == 60, " found %llu\n",
1420 (unsigned long long)(int)sizeof(struct lustre_capa));
1421 LASSERTF((int)offsetof(struct lustre_capa, lc_uid) == 0, " found %llu\n",
1422 (unsigned long long)(int)offsetof(struct lustre_capa, lc_uid));
1423 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_uid) == 4, " found %llu\n",
1424 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_uid));
1425 LASSERTF((int)offsetof(struct lustre_capa, lc_op) == 8, " found %llu\n",
1426 (unsigned long long)(int)offsetof(struct lustre_capa, lc_op));
1427 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_op) == 4, " found %llu\n",
1428 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_op));
1429 LASSERTF((int)offsetof(struct lustre_capa, lc_ino) == 12, " found %llu\n",
1430 (unsigned long long)(int)offsetof(struct lustre_capa, lc_ino));
1431 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_ino) == 8, " found %llu\n",
1432 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_ino));
1433 LASSERTF((int)offsetof(struct lustre_capa, lc_mdsid) == 20, " found %llu\n",
1434 (unsigned long long)(int)offsetof(struct lustre_capa, lc_mdsid));
1435 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_mdsid) == 4, " found %llu\n",
1436 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_mdsid));
1437 LASSERTF((int)offsetof(struct lustre_capa, lc_keyid) == 24, " found %llu\n",
1438 (unsigned long long)(int)offsetof(struct lustre_capa, lc_keyid));
1439 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_keyid) == 4, " found %llu\n",
1440 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_keyid));
1441 LASSERTF((int)offsetof(struct lustre_capa, lc_expiry) == 28, " found %llu\n",
1442 (unsigned long long)(int)offsetof(struct lustre_capa, lc_expiry));
1443 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_expiry) == 8, " found %llu\n",
1444 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_expiry));
1445 LASSERTF((int)offsetof(struct lustre_capa, lc_flags) == 36, " found %llu\n",
1446 (unsigned long long)(int)offsetof(struct lustre_capa, lc_flags));
1447 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_flags) == 4, " found %llu\n",
1448 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_flags));
1449 LASSERTF((int)offsetof(struct lustre_capa, lc_hmac) == 40, " found %llu\n",
1450 (unsigned long long)(int)offsetof(struct lustre_capa, lc_hmac));
1451 LASSERTF((int)sizeof(((struct lustre_capa *)0)->lc_hmac) == 20, " found %llu\n",
1452 (unsigned long long)(int)sizeof(((struct lustre_capa *)0)->lc_hmac));
1454 /* Checks for struct lustre_capa_key */
1455 LASSERTF((int)sizeof(struct lustre_capa_key) == 36, " found %llu\n",
1456 (unsigned long long)(int)sizeof(struct lustre_capa_key));
1457 LASSERTF((int)offsetof(struct lustre_capa_key, lk_mdsid) == 0, " found %llu\n",
1458 (unsigned long long)(int)offsetof(struct lustre_capa_key, lk_mdsid));
1459 LASSERTF((int)sizeof(((struct lustre_capa_key *)0)->lk_mdsid) == 4, " found %llu\n",
1460 (unsigned long long)(int)sizeof(((struct lustre_capa_key *)0)->lk_mdsid));
1461 LASSERTF((int)offsetof(struct lustre_capa_key, lk_keyid) == 4, " found %llu\n",
1462 (unsigned long long)(int)offsetof(struct lustre_capa_key, lk_keyid));
1463 LASSERTF((int)sizeof(((struct lustre_capa_key *)0)->lk_keyid) == 4, " found %llu\n",
1464 (unsigned long long)(int)sizeof(((struct lustre_capa_key *)0)->lk_keyid));
1465 LASSERTF((int)offsetof(struct lustre_capa_key, lk_expiry) == 8, " found %llu\n",
1466 (unsigned long long)(int)offsetof(struct lustre_capa_key, lk_expiry));
1467 LASSERTF((int)sizeof(((struct lustre_capa_key *)0)->lk_expiry) == 8, " found %llu\n",
1468 (unsigned long long)(int)sizeof(((struct lustre_capa_key *)0)->lk_expiry));
1469 LASSERTF((int)offsetof(struct lustre_capa_key, lk_key) == 16, " found %llu\n",
1470 (unsigned long long)(int)offsetof(struct lustre_capa_key, lk_key));
1471 LASSERTF((int)sizeof(((struct lustre_capa_key *)0)->lk_key) == 20, " found %llu\n",
1472 (unsigned long long)(int)sizeof(((struct lustre_capa_key *)0)->lk_key));