Whamcloud - gitweb
LU-241 Support crc32c with hardware accelerated instruction as one of lustre checksums
[fs/lustre-release.git] / lustre / utils / wiretest.c
index debda52..79fca5c 100644 (file)
  * GPL HEADER END
  */
 /*
- * Copyright  2008 Sun Microsystems, Inc. All rights reserved
+ * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
  * Use is subject to license terms.
  */
 /*
+ * Copyright (c) 2011 Whamcloud, Inc.
+ */
+/*
  * This file is part of Lustre, http://www.lustre.org/
  * Lustre is a trademark of Sun Microsystems, Inc.
  */
@@ -62,8 +65,8 @@ void lustre_assert_wire_constants(void)
 {
         /* Wire protocol assertions generated by 'wirecheck'
          * (make -C lustre/utils newwiretest)
-         * running on Linux vl1 2.6.18-prep #2 SMP Wed Jul 22 20:53:11 CDT 2009 x86_64 x86_64 x86_64 
-         * with gcc version 4.1.2 20070626 (Red Hat 4.1.2-14) */
+         * running on Linux centos5.localhost 2.6.18-prep #3 SMP Mon Mar 22 08:28:01 EDT 2010 x86_64 
+         * with gcc version 4.1.2 20071124 (Red Hat 4.1.2-42) */
 
 
         /* Constants... */
@@ -407,7 +410,7 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)sizeof(((struct ptlrpc_body *)0)->pb_pre_versions[4]));
 
         /* Checks for struct obd_connect_data */
-        LASSERTF((int)sizeof(struct obd_connect_data) == 72, " found %lld\n",
+        LASSERTF((int)sizeof(struct obd_connect_data) == 192, " found %lld\n",
                  (long long)(int)sizeof(struct obd_connect_data));
         LASSERTF((int)offsetof(struct obd_connect_data, ocd_connect_flags) == 0, " found %lld\n",
                  (long long)(int)offsetof(struct obd_connect_data, ocd_connect_flags));
@@ -453,42 +456,66 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct obd_connect_data, ocd_cksum_types));
         LASSERTF((int)sizeof(((struct obd_connect_data *)0)->ocd_cksum_types) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct obd_connect_data *)0)->ocd_cksum_types));
-        LASSERTF((int)offsetof(struct obd_connect_data, padding1) == 56, " found %lld\n",
+        LASSERTF((int)offsetof(struct obd_connect_data, ocd_max_easize) == 56, " found %lld\n",
+                 (long long)(int)offsetof(struct obd_connect_data, ocd_max_easize));
+        LASSERTF((int)sizeof(((struct obd_connect_data *)0)->ocd_max_easize) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct obd_connect_data *)0)->ocd_max_easize));
+        LASSERTF((int)offsetof(struct obd_connect_data, padding) == 60, " found %lld\n",
+                 (long long)(int)offsetof(struct obd_connect_data, padding));
+        LASSERTF((int)sizeof(((struct obd_connect_data *)0)->padding) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct obd_connect_data *)0)->padding));
+        LASSERTF((int)offsetof(struct obd_connect_data, ocd_maxbytes) == 64, " found %lld\n",
+                 (long long)(int)offsetof(struct obd_connect_data, ocd_maxbytes));
+        LASSERTF((int)sizeof(((struct obd_connect_data *)0)->ocd_maxbytes) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct obd_connect_data *)0)->ocd_maxbytes));
+        LASSERTF((int)offsetof(struct obd_connect_data, padding1) == 72, " found %lld\n",
                  (long long)(int)offsetof(struct obd_connect_data, padding1));
         LASSERTF((int)sizeof(((struct obd_connect_data *)0)->padding1) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct obd_connect_data *)0)->padding1));
-        LASSERTF((int)offsetof(struct obd_connect_data, padding2) == 64, " found %lld\n",
+        LASSERTF((int)offsetof(struct obd_connect_data, padding2) == 80, " found %lld\n",
                  (long long)(int)offsetof(struct obd_connect_data, padding2));
         LASSERTF((int)sizeof(((struct obd_connect_data *)0)->padding2) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct obd_connect_data *)0)->padding2));
-        CLASSERT(OBD_CONNECT_RDONLY == 0x1ULL);
-        CLASSERT(OBD_CONNECT_INDEX == 0x2ULL);
-        CLASSERT(OBD_CONNECT_GRANT == 0x8ULL);
-        CLASSERT(OBD_CONNECT_SRVLOCK == 0x10ULL);
-        CLASSERT(OBD_CONNECT_VERSION == 0x20ULL);
-        CLASSERT(OBD_CONNECT_REQPORTAL == 0x40ULL);
-        CLASSERT(OBD_CONNECT_ACL == 0x80ULL);
-        CLASSERT(OBD_CONNECT_XATTR == 0x100ULL);
-        CLASSERT(OBD_CONNECT_REAL == 0x8000000ULL);
-        CLASSERT(OBD_CONNECT_CKSUM == 0x20000000ULL);
-        CLASSERT(OBD_CONNECT_TRUNCLOCK == 0x400ULL);
-        CLASSERT(OBD_CONNECT_IBITS == 0x1000ULL);
-        CLASSERT(OBD_CONNECT_JOIN == 0x2000ULL);
-        CLASSERT(OBD_CONNECT_ATTRFID == 0x4000ULL);
-        CLASSERT(OBD_CONNECT_NODEVOH == 0x8000ULL);
-        CLASSERT(OBD_CONNECT_RMT_CLIENT == 0x10000ULL);
-        CLASSERT(OBD_CONNECT_RMT_CLIENT_FORCE == 0x20000ULL);
-        CLASSERT(OBD_CONNECT_BRW_SIZE == 0x40000ULL);
-        CLASSERT(OBD_CONNECT_QUOTA64 == 0x80000ULL);
-        CLASSERT(OBD_CONNECT_MDS_CAPA == 0x100000ULL);
-        CLASSERT(OBD_CONNECT_OSS_CAPA == 0x200000ULL);
-        CLASSERT(OBD_CONNECT_MDS_MDS == 0x4000000ULL);
-        CLASSERT(OBD_CONNECT_SOM == 0x800000ULL);
-        CLASSERT(OBD_CONNECT_AT == 0x1000000ULL);
-        CLASSERT(OBD_CONNECT_CANCELSET == 0x400000ULL);
-        CLASSERT(OBD_CONNECT_LRU_RESIZE == 0x2000000ULL);
-        CLASSERT(OBD_CONNECT_VBR == 0x80000000ULL);
-        CLASSERT(OBD_CONNECT_SKIP_ORPHAN == 0x400000000ULL);
+        CLASSERT(OBD_CONNECT_RDONLY ==                    0x1ULL);
+        CLASSERT(OBD_CONNECT_INDEX ==                     0x2ULL);
+        CLASSERT(OBD_CONNECT_MDS ==                       0x4ULL);
+        CLASSERT(OBD_CONNECT_GRANT ==                     0x8ULL);
+        CLASSERT(OBD_CONNECT_SRVLOCK ==                  0x10ULL);
+        CLASSERT(OBD_CONNECT_VERSION ==                  0x20ULL);
+        CLASSERT(OBD_CONNECT_REQPORTAL ==                0x40ULL);
+        CLASSERT(OBD_CONNECT_ACL ==                      0x80ULL);
+        CLASSERT(OBD_CONNECT_XATTR ==                   0x100ULL);
+        CLASSERT(OBD_CONNECT_CROW ==                    0x200ULL);
+        CLASSERT(OBD_CONNECT_TRUNCLOCK ==               0x400ULL);
+        CLASSERT(OBD_CONNECT_TRANSNO ==                 0x800ULL);
+        CLASSERT(OBD_CONNECT_IBITS ==                  0x1000ULL);
+        CLASSERT(OBD_CONNECT_JOIN ==                   0x2000ULL);
+        CLASSERT(OBD_CONNECT_ATTRFID ==                0x4000ULL);
+        CLASSERT(OBD_CONNECT_NODEVOH ==                0x8000ULL);
+        CLASSERT(OBD_CONNECT_RMT_CLIENT ==            0x10000ULL);
+        CLASSERT(OBD_CONNECT_RMT_CLIENT_FORCE ==      0x20000ULL);
+        CLASSERT(OBD_CONNECT_BRW_SIZE ==              0x40000ULL);
+        CLASSERT(OBD_CONNECT_QUOTA64 ==               0x80000ULL);
+        CLASSERT(OBD_CONNECT_MDS_CAPA ==             0x100000ULL);
+        CLASSERT(OBD_CONNECT_OSS_CAPA ==             0x200000ULL);
+        CLASSERT(OBD_CONNECT_CANCELSET ==            0x400000ULL);
+        CLASSERT(OBD_CONNECT_SOM ==                  0x800000ULL);
+        CLASSERT(OBD_CONNECT_AT ==                  0x1000000ULL);
+        CLASSERT(OBD_CONNECT_LRU_RESIZE ==          0x2000000ULL);
+        CLASSERT(OBD_CONNECT_MDS_MDS ==             0x4000000ULL);
+        CLASSERT(OBD_CONNECT_REAL ==                0x8000000ULL);
+        CLASSERT(OBD_CONNECT_CHANGE_QS ==          0x10000000ULL);
+        CLASSERT(OBD_CONNECT_CKSUM ==              0x20000000ULL);
+        CLASSERT(OBD_CONNECT_FID ==                0x40000000ULL);
+        CLASSERT(OBD_CONNECT_VBR ==                0x80000000ULL);
+        CLASSERT(OBD_CONNECT_LOV_V3 ==            0x100000000ULL);
+        CLASSERT(OBD_CONNECT_GRANT_SHRINK ==      0x200000000ULL);
+        CLASSERT(OBD_CONNECT_SKIP_ORPHAN ==       0x400000000ULL);
+        CLASSERT(OBD_CONNECT_MAX_EASIZE ==        0x800000000ULL);
+        CLASSERT(OBD_CONNECT_FULL20 ==           0x1000000000ULL);
+        CLASSERT(OBD_CONNECT_LAYOUTLOCK ==       0x2000000000ULL);
+        CLASSERT(OBD_CONNECT_64BITHASH ==        0x4000000000ULL);
+        CLASSERT(OBD_CONNECT_MAXBYTES ==         0x8000000000ULL);
 
         /* Checks for struct obdo */
         LASSERTF((int)sizeof(struct obdo) == 208, " found %lld\n",
@@ -497,18 +524,18 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct obdo, o_valid));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_valid) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct obdo *)0)->o_valid));
-        LASSERTF((int)offsetof(struct obdo, o_id) == 8, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_id));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_id) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_id));
-        LASSERTF((int)offsetof(struct obdo, o_gr) == 16, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_gr));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_gr) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_gr));
-        LASSERTF((int)offsetof(struct obdo, o_fid) == 24, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_fid));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_fid) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_fid));
+        LASSERTF((int)offsetof(struct obdo, o_oi.oi_id) == 8, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_oi.oi_id));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_oi.oi_id) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_oi.oi_id));
+        LASSERTF((int)offsetof(struct obdo, o_oi.oi_seq) == 16, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_oi.oi_seq));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_oi.oi_seq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_oi.oi_seq));
+        LASSERTF((int)offsetof(struct obdo, o_parent_seq) == 24, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_parent_seq));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_parent_seq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_parent_seq));
         LASSERTF((int)offsetof(struct obdo, o_size) == 32, " found %lld\n",
                  (long long)(int)offsetof(struct obdo, o_size));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_size) == 8, " found %lld\n",
@@ -557,30 +584,26 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct obdo, o_nlink));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_nlink) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct obdo *)0)->o_nlink));
-        LASSERTF((int)offsetof(struct obdo, o_generation) == 104, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_generation));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_generation) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_generation));
+        LASSERTF((int)offsetof(struct obdo, o_parent_oid) == 104, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_parent_oid));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_parent_oid) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_parent_oid));
         LASSERTF((int)offsetof(struct obdo, o_misc) == 108, " found %lld\n",
                  (long long)(int)offsetof(struct obdo, o_misc));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_misc) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct obdo *)0)->o_misc));
-        LASSERTF((int)offsetof(struct obdo, o_easize) == 112, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_easize));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_easize) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_easize));
-        LASSERTF((int)offsetof(struct obdo, o_mds) == 116, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_mds));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_mds) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_mds));
+        LASSERTF((int)offsetof(struct obdo, o_ioepoch) == 112, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_ioepoch));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_ioepoch) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_ioepoch));
         LASSERTF((int)offsetof(struct obdo, o_stripe_idx) == 120, " found %lld\n",
                  (long long)(int)offsetof(struct obdo, o_stripe_idx));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_stripe_idx) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct obdo *)0)->o_stripe_idx));
-        LASSERTF((int)offsetof(struct obdo, o_padding_1) == 124, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_padding_1));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_padding_1) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_padding_1));
+        LASSERTF((int)offsetof(struct obdo, o_parent_ver) == 124, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_parent_ver));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_parent_ver) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_parent_ver));
         LASSERTF((int)offsetof(struct obdo, o_handle) == 128, " found %lld\n",
                  (long long)(int)offsetof(struct obdo, o_handle));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_handle) == 8, " found %lld\n",
@@ -589,10 +612,14 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct obdo, o_lcookie));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_lcookie) == 32, " found %lld\n",
                  (long long)(int)sizeof(((struct obdo *)0)->o_lcookie));
-        LASSERTF((int)offsetof(struct obdo, o_padding_2) == 168, " found %lld\n",
-                 (long long)(int)offsetof(struct obdo, o_padding_2));
-        LASSERTF((int)sizeof(((struct obdo *)0)->o_padding_2) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct obdo *)0)->o_padding_2));
+        LASSERTF((int)offsetof(struct obdo, o_uid_h) == 168, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_uid_h));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_uid_h) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_uid_h));
+        LASSERTF((int)offsetof(struct obdo, o_gid_h) == 172, " found %lld\n",
+                 (long long)(int)offsetof(struct obdo, o_gid_h));
+        LASSERTF((int)sizeof(((struct obdo *)0)->o_gid_h) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct obdo *)0)->o_gid_h));
         LASSERTF((int)offsetof(struct obdo, o_padding_3) == 176, " found %lld\n",
                  (long long)(int)offsetof(struct obdo, o_padding_3));
         LASSERTF((int)sizeof(((struct obdo *)0)->o_padding_3) == 8, " found %lld\n",
@@ -653,12 +680,16 @@ void lustre_assert_wire_constants(void)
         CLASSERT(OBD_FL_DEBUG_CHECK == 64);
         CLASSERT(OBD_FL_NO_USRQUOTA == 256);
         CLASSERT(OBD_FL_NO_GRPQUOTA == 512);
-        CLASSERT(OBD_FL_TRUNCLOCK == 2048);
+        CLASSERT(OBD_FL_SRVLOCK == 2048);
         CLASSERT(OBD_FL_CKSUM_CRC32 == 4096);
         CLASSERT(OBD_FL_CKSUM_ADLER == 8192);
+        CLASSERT(OBD_FL_CKSUM_CRC32C == 16384);
         CLASSERT(OBD_FL_SHRINK_GRANT == 131072);
+        CLASSERT(OBD_FL_MMAP == (0x00040000));
+        CLASSERT(OBD_FL_RECOV_RESEND == (0x00080000));
         CLASSERT(OBD_CKSUM_CRC32 == 1);
         CLASSERT(OBD_CKSUM_ADLER == 2);
+        CLASSERT(OBD_CKSUM_CRC32C == 4);
 
         /* Checks for struct lov_mds_md_v1 */
         LASSERTF((int)sizeof(struct lov_mds_md_v1) == 32, " found %lld\n",
@@ -675,10 +706,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct lov_mds_md_v1, lmm_object_id));
         LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_id) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_id));
-        LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_object_gr) == 16, " found %lld\n",
-                 (long long)(int)offsetof(struct lov_mds_md_v1, lmm_object_gr));
-        LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_gr) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_gr));
+        LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_object_seq) == 16, " found %lld\n",
+                 (long long)(int)offsetof(struct lov_mds_md_v1, lmm_object_seq));
+        LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_seq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_object_seq));
         LASSERTF((int)offsetof(struct lov_mds_md_v1, lmm_stripe_size) == 24, " found %lld\n",
                  (long long)(int)offsetof(struct lov_mds_md_v1, lmm_stripe_size));
         LASSERTF((int)sizeof(((struct lov_mds_md_v1 *)0)->lmm_stripe_size) == 4, " found %lld\n",
@@ -699,10 +730,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct lov_ost_data_v1, l_object_id));
         LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_id) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_id));
-        LASSERTF((int)offsetof(struct lov_ost_data_v1, l_object_gr) == 8, " found %lld\n",
-                 (long long)(int)offsetof(struct lov_ost_data_v1, l_object_gr));
-        LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_gr) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_gr));
+        LASSERTF((int)offsetof(struct lov_ost_data_v1, l_object_seq) == 8, " found %lld\n",
+                 (long long)(int)offsetof(struct lov_ost_data_v1, l_object_seq));
+        LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_seq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_seq));
         LASSERTF((int)offsetof(struct lov_ost_data_v1, l_ost_gen) == 16, " found %lld\n",
                  (long long)(int)offsetof(struct lov_ost_data_v1, l_ost_gen));
         LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_ost_gen) == 4, " found %lld\n",
@@ -732,10 +763,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct lov_mds_md_v3, lmm_object_id));
         LASSERTF((int)sizeof(((struct lov_mds_md_v3 *)0)->lmm_object_id) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct lov_mds_md_v3 *)0)->lmm_object_id));
-        LASSERTF((int)offsetof(struct lov_mds_md_v3, lmm_object_gr) == 16, " found %lld\n",
-                 (long long)(int)offsetof(struct lov_mds_md_v3, lmm_object_gr));
-        LASSERTF((int)sizeof(((struct lov_mds_md_v3 *)0)->lmm_object_gr) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct lov_mds_md_v3 *)0)->lmm_object_gr));
+        LASSERTF((int)offsetof(struct lov_mds_md_v3, lmm_object_seq) == 16, " found %lld\n",
+                 (long long)(int)offsetof(struct lov_mds_md_v3, lmm_object_seq));
+        LASSERTF((int)sizeof(((struct lov_mds_md_v3 *)0)->lmm_object_seq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct lov_mds_md_v3 *)0)->lmm_object_seq));
         LASSERTF((int)offsetof(struct lov_mds_md_v3, lmm_stripe_size) == 24, " found %lld\n",
                  (long long)(int)offsetof(struct lov_mds_md_v3, lmm_stripe_size));
         LASSERTF((int)sizeof(((struct lov_mds_md_v3 *)0)->lmm_stripe_size) == 4, " found %lld\n",
@@ -760,10 +791,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct lov_ost_data_v1, l_object_id));
         LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_id) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_id));
-        LASSERTF((int)offsetof(struct lov_ost_data_v1, l_object_gr) == 8, " found %lld\n",
-                 (long long)(int)offsetof(struct lov_ost_data_v1, l_object_gr));
-        LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_gr) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_gr));
+        LASSERTF((int)offsetof(struct lov_ost_data_v1, l_object_seq) == 8, " found %lld\n",
+                 (long long)(int)offsetof(struct lov_ost_data_v1, l_object_seq));
+        LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_seq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct lov_ost_data_v1 *)0)->l_object_seq));
         LASSERTF((int)offsetof(struct lov_ost_data_v1, l_ost_gen) == 16, " found %lld\n",
                  (long long)(int)offsetof(struct lov_ost_data_v1, l_ost_gen));
         LASSERTF((int)sizeof(((struct lov_ost_data_v1 *)0)->l_ost_gen) == 4, " found %lld\n",
@@ -861,10 +892,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct obd_ioobj, ioo_id));
         LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_id) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct obd_ioobj *)0)->ioo_id));
-        LASSERTF((int)offsetof(struct obd_ioobj, ioo_gr) == 8, " found %lld\n",
-                 (long long)(int)offsetof(struct obd_ioobj, ioo_gr));
-        LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_gr) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct obd_ioobj *)0)->ioo_gr));
+        LASSERTF((int)offsetof(struct obd_ioobj, ioo_seq) == 8, " found %lld\n",
+                 (long long)(int)offsetof(struct obd_ioobj, ioo_seq));
+        LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_seq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct obd_ioobj *)0)->ioo_seq));
         LASSERTF((int)offsetof(struct obd_ioobj, ioo_type) == 16, " found %lld\n",
                  (long long)(int)offsetof(struct obd_ioobj, ioo_type));
         LASSERTF((int)sizeof(((struct obd_ioobj *)0)->ioo_type) == 4, " found %lld\n",
@@ -1169,7 +1200,6 @@ void lustre_assert_wire_constants(void)
         CLASSERT(MDS_APPEND_FL == 0x00000020);
         CLASSERT(MDS_NOATIME_FL == 0x00000080);
         CLASSERT(MDS_DIRSYNC_FL == 0x00010000);
-        CLASSERT(MDS_BFLAG_EXT_FLAGS == 0x80000000);
         CLASSERT(MDS_INODELOCK_LOOKUP == 0x000001);
         CLASSERT(MDS_INODELOCK_UPDATE == 0x000002);
         CLASSERT(MDS_INODELOCK_OPEN == 0x000004);
@@ -1357,14 +1387,14 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct mdt_rec_create, cr_bias));
         LASSERTF((int)sizeof(((struct mdt_rec_create *)0)->cr_bias) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct mdt_rec_create *)0)->cr_bias));
-        LASSERTF((int)offsetof(struct mdt_rec_create, cr_flags) == 120, " found %lld\n",
-                 (long long)(int)offsetof(struct mdt_rec_create, cr_flags));
-        LASSERTF((int)sizeof(((struct mdt_rec_create *)0)->cr_flags) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct mdt_rec_create *)0)->cr_flags));
-        LASSERTF((int)offsetof(struct mdt_rec_create, cr_padding_2) == 124, " found %lld\n",
-                 (long long)(int)offsetof(struct mdt_rec_create, cr_padding_2));
-        LASSERTF((int)sizeof(((struct mdt_rec_create *)0)->cr_padding_2) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct mdt_rec_create *)0)->cr_padding_2));
+        LASSERTF((int)offsetof(struct mdt_rec_create, cr_flags_l) == 120, " found %lld\n",
+                 (long long)(int)offsetof(struct mdt_rec_create, cr_flags_l));
+        LASSERTF((int)sizeof(((struct mdt_rec_create *)0)->cr_flags_l) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct mdt_rec_create *)0)->cr_flags_l));
+        LASSERTF((int)offsetof(struct mdt_rec_create, cr_flags_h) == 124, " found %lld\n",
+                 (long long)(int)offsetof(struct mdt_rec_create, cr_flags_h));
+        LASSERTF((int)sizeof(((struct mdt_rec_create *)0)->cr_flags_h) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct mdt_rec_create *)0)->cr_flags_h));
         LASSERTF((int)offsetof(struct mdt_rec_create, cr_padding_3) == 128, " found %lld\n",
                  (long long)(int)offsetof(struct mdt_rec_create, cr_padding_3));
         LASSERTF((int)sizeof(((struct mdt_rec_create *)0)->cr_padding_3) == 4, " found %lld\n",
@@ -1730,25 +1760,25 @@ void lustre_assert_wire_constants(void)
         LASSERTF((int)sizeof(((struct ldlm_extent *)0)->gid) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct ldlm_extent *)0)->gid));
 
-        /* Checks for struct ldlm_flock */
-        LASSERTF((int)sizeof(struct ldlm_flock) == 32, " found %lld\n",
-                 (long long)(int)sizeof(struct ldlm_flock));
-        LASSERTF((int)offsetof(struct ldlm_flockstart) == 0, " found %lld\n",
-                 (long long)(int)offsetof(struct ldlm_flockstart));
-        LASSERTF((int)sizeof(((struct ldlm_flock *)0)->start) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct ldlm_flock *)0)->start));
-        LASSERTF((int)offsetof(struct ldlm_flockend) == 8, " found %lld\n",
-                 (long long)(int)offsetof(struct ldlm_flockend));
-        LASSERTF((int)sizeof(((struct ldlm_flock *)0)->end) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct ldlm_flock *)0)->end));
-        LASSERTF((int)offsetof(struct ldlm_flock, blocking_pid) == 24, " found %lld\n",
-                 (long long)(int)offsetof(struct ldlm_flock, blocking_pid));
-        LASSERTF((int)sizeof(((struct ldlm_flock *)0)->blocking_pid) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct ldlm_flock *)0)->blocking_pid));
-        LASSERTF((int)offsetof(struct ldlm_flockpid) == 28, " found %lld\n",
-                 (long long)(int)offsetof(struct ldlm_flockpid));
-        LASSERTF((int)sizeof(((struct ldlm_flock *)0)->pid) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct ldlm_flock *)0)->pid));
+        /* Checks for struct ldlm_flock_wire */
+        LASSERTF((int)sizeof(struct ldlm_flock_wire) == 32, " found %lld\n",
+                 (long long)(int)sizeof(struct ldlm_flock_wire));
+        LASSERTF((int)offsetof(struct ldlm_flock_wire, lfw_start) == 0, " found %lld\n",
+                 (long long)(int)offsetof(struct ldlm_flock_wire, lfw_start));
+        LASSERTF((int)sizeof(((struct ldlm_flock_wire *)0)->lfw_start) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct ldlm_flock_wire *)0)->lfw_start));
+        LASSERTF((int)offsetof(struct ldlm_flock_wire, lfw_end) == 8, " found %lld\n",
+                 (long long)(int)offsetof(struct ldlm_flock_wire, lfw_end));
+        LASSERTF((int)sizeof(((struct ldlm_flock_wire *)0)->lfw_end) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct ldlm_flock_wire *)0)->lfw_end));
+        LASSERTF((int)offsetof(struct ldlm_flock_wire, lfw_owner) == 16, " found %lld\n",
+                 (long long)(int)offsetof(struct ldlm_flock_wire, lfw_owner));
+        LASSERTF((int)sizeof(((struct ldlm_flock_wire *)0)->lfw_owner) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct ldlm_flock_wire *)0)->lfw_owner));
+        LASSERTF((int)offsetof(struct ldlm_flock_wire, lfw_pid) == 28, " found %lld\n",
+                 (long long)(int)offsetof(struct ldlm_flock_wire, lfw_pid));
+        LASSERTF((int)sizeof(((struct ldlm_flock_wire *)0)->lfw_pid) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct ldlm_flock_wire *)0)->lfw_pid));
 
         /* Checks for struct ldlm_inodebits */
         LASSERTF((int)sizeof(struct ldlm_inodebits) == 8, " found %lld\n",
@@ -1913,10 +1943,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct llog_logid, lgl_oid));
         LASSERTF((int)sizeof(((struct llog_logid *)0)->lgl_oid) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct llog_logid *)0)->lgl_oid));
-        LASSERTF((int)offsetof(struct llog_logid, lgl_ogr) == 8, " found %lld\n",
-                 (long long)(int)offsetof(struct llog_logid, lgl_ogr));
-        LASSERTF((int)sizeof(((struct llog_logid *)0)->lgl_ogr) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct llog_logid *)0)->lgl_ogr));
+        LASSERTF((int)offsetof(struct llog_logid, lgl_oseq) == 8, " found %lld\n",
+                 (long long)(int)offsetof(struct llog_logid, lgl_oseq));
+        LASSERTF((int)sizeof(((struct llog_logid *)0)->lgl_oseq) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct llog_logid *)0)->lgl_oseq));
         LASSERTF((int)offsetof(struct llog_logid, lgl_ogen) == 16, " found %lld\n",
                  (long long)(int)offsetof(struct llog_logid, lgl_ogen));
         LASSERTF((int)sizeof(((struct llog_logid *)0)->lgl_ogen) == 4, " found %lld\n",
@@ -2035,14 +2065,18 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct llog_create_rec, lcr_oid));
         LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_oid) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_oid));
-        LASSERTF((int)offsetof(struct llog_create_rec, lcr_ogr) == 40, " found %lld\n",
-                 (long long)(int)offsetof(struct llog_create_rec, lcr_ogr));
-        LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_ogr) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_ogr));
+        LASSERTF((int)offsetof(struct llog_create_rec, lcr_oseq) == 40, " found %lld\n",
+                 (long long)(int)offsetof(struct llog_create_rec, lcr_oseq));
+        LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_oseq) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_oseq));
         LASSERTF((int)offsetof(struct llog_create_rec, padding) == 44, " found %lld\n",
                  (long long)(int)offsetof(struct llog_create_rec, padding));
         LASSERTF((int)sizeof(((struct llog_create_rec *)0)->padding) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct llog_create_rec *)0)->padding));
+        LASSERTF((int)offsetof(struct llog_create_rec, lcr_tail) == 48, " found %lld\n",
+                 (long long)(int)offsetof(struct llog_create_rec, lcr_tail));
+        LASSERTF((int)sizeof(((struct llog_create_rec *)0)->lcr_tail) == 8, " found %lld\n",
+                 (long long)(int)sizeof(((struct llog_create_rec *)0)->lcr_tail));
 
         /* Checks for struct llog_orphan_rec */
         LASSERTF((int)sizeof(struct llog_orphan_rec) == 40, " found %lld\n",
@@ -2079,10 +2113,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct llog_unlink_rec, lur_oid));
         LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_oid) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct llog_unlink_rec *)0)->lur_oid));
-        LASSERTF((int)offsetof(struct llog_unlink_rec, lur_ogr) == 24, " found %lld\n",
-                 (long long)(int)offsetof(struct llog_unlink_rec, lur_ogr));
-        LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_ogr) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct llog_unlink_rec *)0)->lur_ogr));
+        LASSERTF((int)offsetof(struct llog_unlink_rec, lur_oseq) == 24, " found %lld\n",
+                 (long long)(int)offsetof(struct llog_unlink_rec, lur_oseq));
+        LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_oseq) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct llog_unlink_rec *)0)->lur_oseq));
         LASSERTF((int)offsetof(struct llog_unlink_rec, lur_count) == 28, " found %lld\n",
                  (long long)(int)offsetof(struct llog_unlink_rec, lur_count));
         LASSERTF((int)sizeof(((struct llog_unlink_rec *)0)->lur_count) == 4, " found %lld\n",
@@ -2103,10 +2137,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct llog_setattr_rec, lsr_oid));
         LASSERTF((int)sizeof(((struct llog_setattr_rec *)0)->lsr_oid) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct llog_setattr_rec *)0)->lsr_oid));
-        LASSERTF((int)offsetof(struct llog_setattr_rec, lsr_ogr) == 24, " found %lld\n",
-                 (long long)(int)offsetof(struct llog_setattr_rec, lsr_ogr));
-        LASSERTF((int)sizeof(((struct llog_setattr_rec *)0)->lsr_ogr) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct llog_setattr_rec *)0)->lsr_ogr));
+        LASSERTF((int)offsetof(struct llog_setattr_rec, lsr_oseq) == 24, " found %lld\n",
+                 (long long)(int)offsetof(struct llog_setattr_rec, lsr_oseq));
+        LASSERTF((int)sizeof(((struct llog_setattr_rec *)0)->lsr_oseq) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct llog_setattr_rec *)0)->lsr_oseq));
         LASSERTF((int)offsetof(struct llog_setattr_rec, lsr_uid) == 28, " found %lld\n",
                  (long long)(int)offsetof(struct llog_setattr_rec, lsr_uid));
         LASSERTF((int)sizeof(((struct llog_setattr_rec *)0)->lsr_uid) == 4, " found %lld\n",
@@ -2135,10 +2169,10 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct llog_setattr64_rec, lsr_oid));
         LASSERTF((int)sizeof(((struct llog_setattr64_rec *)0)->lsr_oid) == 8, " found %lld\n",
                  (long long)(int)sizeof(((struct llog_setattr64_rec *)0)->lsr_oid));
-        LASSERTF((int)offsetof(struct llog_setattr64_rec, lsr_ogr) == 24, " found %lld\n",
-                 (long long)(int)offsetof(struct llog_setattr64_rec, lsr_ogr));
-        LASSERTF((int)sizeof(((struct llog_setattr64_rec *)0)->lsr_ogr) == 4, " found %lld\n",
-                 (long long)(int)sizeof(((struct llog_setattr64_rec *)0)->lsr_ogr));
+        LASSERTF((int)offsetof(struct llog_setattr64_rec, lsr_oseq) == 24, " found %lld\n",
+                 (long long)(int)offsetof(struct llog_setattr64_rec, lsr_oseq));
+        LASSERTF((int)sizeof(((struct llog_setattr64_rec *)0)->lsr_oseq) == 4, " found %lld\n",
+                 (long long)(int)sizeof(((struct llog_setattr64_rec *)0)->lsr_oseq));
         LASSERTF((int)offsetof(struct llog_setattr64_rec, padding) == 28, " found %lld\n",
                  (long long)(int)offsetof(struct llog_setattr64_rec, padding));
         LASSERTF((int)sizeof(((struct llog_setattr64_rec *)0)->padding) == 4, " found %lld\n",
@@ -2671,19 +2705,18 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)sizeof(((struct link_ea_header *)0)->padding2));
 
         /* Checks for struct link_ea_entry */
-        LASSERTF((int)sizeof(struct link_ea_entry) == 20, " found %lld\n",
+        LASSERTF((int)sizeof(struct link_ea_entry) == 18, " found %lld\n",
                  (long long)(int)sizeof(struct link_ea_entry));
-        LASSERTF((int)offsetof(struct link_ea_entry, lee_reclen) == 16, " found %lld\n",
+        LASSERTF((int)offsetof(struct link_ea_entry, lee_reclen) == 0, " found %lld\n",
                  (long long)(int)offsetof(struct link_ea_entry, lee_reclen));
         LASSERTF((int)sizeof(((struct link_ea_entry *)0)->lee_reclen) == 2, " found %lld\n",
                  (long long)(int)sizeof(((struct link_ea_entry *)0)->lee_reclen));
-        LASSERTF((int)offsetof(struct link_ea_entry, lee_parent_fid) == 0, " found %lld\n",
+        LASSERTF((int)offsetof(struct link_ea_entry, lee_parent_fid) == 2, " found %lld\n",
                  (long long)(int)offsetof(struct link_ea_entry, lee_parent_fid));
         LASSERTF((int)sizeof(((struct link_ea_entry *)0)->lee_parent_fid) == 16, " found %lld\n",
                  (long long)(int)sizeof(((struct link_ea_entry *)0)->lee_parent_fid));
-        LASSERTF((int)offsetof(struct link_ea_entry, lee_name) == 20, " found %lld\n",
+        LASSERTF((int)offsetof(struct link_ea_entry, lee_name) == 18, " found %lld\n",
                  (long long)(int)offsetof(struct link_ea_entry, lee_name));
         LASSERTF((int)sizeof(((struct link_ea_entry *)0)->lee_name) == 0, " found %lld\n",
                  (long long)(int)sizeof(((struct link_ea_entry *)0)->lee_name));
 }
-