Whamcloud - gitweb
Branch HEAD
[fs/lustre-release.git] / lustre / ptlrpc / wiretest.c
index ea5c7b7..090fa86 100644 (file)
@@ -125,7 +125,7 @@ void lustre_assert_wire_constants(void)
                  (long long)REINT_RENAME);
         LASSERTF(REINT_OPEN == 6, " found %lld\n",
                  (long long)REINT_OPEN);
-        LASSERTF(REINT_MAX == 7, " found %lld\n",
+        LASSERTF(REINT_MAX == 8, " found %lld\n",
                  (long long)REINT_MAX);
         LASSERTF(MGS_CONNECT == 250, " found %lld\n",
                  (long long)MGS_CONNECT);
@@ -137,6 +137,8 @@ void lustre_assert_wire_constants(void)
                  (long long)MGS_TARGET_REG);
         LASSERTF(MGS_TARGET_DEL == 254, " found %lld\n",
                  (long long)MGS_TARGET_DEL);
+        LASSERTF(MGS_SET_INFO == 255, " found %lld\n",
+                 (long long)MGS_SET_INFO);
         LASSERTF(DISP_IT_EXECD == 1, " found %lld\n",
                  (long long)DISP_IT_EXECD);
         LASSERTF(DISP_LOOKUP_EXECD == 2, " found %lld\n",
@@ -183,6 +185,8 @@ void lustre_assert_wire_constants(void)
                  (long long)LCK_GROUP);
         LASSERTF(LCK_MAXMODE == 65, " found %lld\n",
                  (long long)LCK_MAXMODE);
+        LASSERTF(LCK_MODE_NUM == 7, " found %lld\n",
+                 (long long)LCK_MODE_NUM);
         CLASSERT(LDLM_PLAIN == 10);
         CLASSERT(LDLM_EXTENT == 11);
         CLASSERT(LDLM_FLOCK == 12);
@@ -209,6 +213,8 @@ void lustre_assert_wire_constants(void)
                  (long long)MGS_TARGET_REG);
         LASSERTF(MGS_TARGET_DEL == 254, " found %lld\n",
                  (long long)MGS_TARGET_DEL);
+        LASSERTF(MGS_SET_INFO == 255, " found %lld\n",
+                 (long long)MGS_SET_INFO);
         /* Sizes and Offsets */
 
         /* Checks for struct obd_uuid */
@@ -431,18 +437,18 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct obd_connect_data, ocd_group));
         LASSERTF((int)sizeof(((struct obd_connect_data *)0)->ocd_group) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct obd_connect_data *)0)->ocd_group));
-        LASSERTF((int)offsetof(struct obd_connect_data, padding1) == 52, " found %lld\n",
+        LASSERTF((int)offsetof(struct obd_connect_data, ocd_cksum_types) == 52, " found %lld\n",
+                 (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",
                  (long long)(int)offsetof(struct obd_connect_data, padding1));
-        LASSERTF((int)sizeof(((struct obd_connect_data *)0)->padding1) == 4, " found %lld\n",
+        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) == 56, " found %lld\n",
+        LASSERTF((int)offsetof(struct obd_connect_data, padding2) == 64, " 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));
-        LASSERTF((int)offsetof(struct obd_connect_data, padding3) == 64, " found %lld\n",
-                 (long long)(int)offsetof(struct obd_connect_data, padding3));
-        LASSERTF((int)sizeof(((struct obd_connect_data *)0)->padding3) == 8, " found %lld\n",
-                 (long long)(int)sizeof(((struct obd_connect_data *)0)->padding3));
         CLASSERT(OBD_CONNECT_RDONLY == 0x00000001ULL);
         CLASSERT(OBD_CONNECT_INDEX == 0x00000002ULL);
         CLASSERT(OBD_CONNECT_GRANT == 0x00000008ULL);
@@ -468,6 +474,7 @@ void lustre_assert_wire_constants(void)
         CLASSERT(OBD_CONNECT_LRU_RESIZE == 0x02000000ULL);
         CLASSERT(OBD_CONNECT_MDS_MDS == 0x04000000ULL);
         CLASSERT(OBD_CONNECT_REAL == 0x08000000ULL);
+        CLASSERT(OBD_CONNECT_CKSUM == 0x20000000ULL);
 
         /* Checks for struct obdo */
         LASSERTF((int)sizeof(struct obdo) == 208, " found %lld\n",
@@ -611,6 +618,11 @@ void lustre_assert_wire_constants(void)
         CLASSERT(OBD_FL_DEBUG_CHECK == (0x00000040));
         CLASSERT(OBD_FL_NO_USRQUOTA == (0x00000100));
         CLASSERT(OBD_FL_NO_GRPQUOTA == (0x00000200));
+        CLASSERT(OBD_FL_TRUNCLOCK == (0x00000800));
+        CLASSERT(OBD_FL_CKSUM_CRC32 == (0x00001000));
+        CLASSERT(OBD_FL_CKSUM_ADLER == (0x00002000));
+        CLASSERT(OBD_CKSUM_CRC32 == (0x00000001));
+        CLASSERT(OBD_CKSUM_ADLER == (0x00000002));
 
         /* Checks for struct lov_mds_md_v1 */
         LASSERTF((int)sizeof(struct lov_mds_md_v1) == 32, " found %lld\n",
@@ -1145,6 +1157,22 @@ void lustre_assert_wire_constants(void)
                  (long long)(int)offsetof(struct mds_rec_setattr, sa_attr_flags));
         LASSERTF((int)sizeof(((struct mds_rec_setattr *)0)->sa_attr_flags) == 4, " found %lld\n",
                  (long long)(int)sizeof(((struct mds_rec_setattr *)0)->sa_attr_flags));
+        CLASSERT(MDS_ATTR_MODE == 1);
+        CLASSERT(MDS_ATTR_UID == 2);
+        CLASSERT(MDS_ATTR_GID == 4);
+        CLASSERT(MDS_ATTR_SIZE == 8);
+        CLASSERT(MDS_ATTR_ATIME == 16);
+        CLASSERT(MDS_ATTR_MTIME == 32);
+        CLASSERT(MDS_ATTR_CTIME == 64);
+        CLASSERT(MDS_ATTR_ATIME_SET == 128);
+        CLASSERT(MDS_ATTR_MTIME_SET == 256);
+        CLASSERT(MDS_ATTR_FORCE == 512);
+        CLASSERT(MDS_ATTR_ATTR_FLAG == 1024);
+        CLASSERT(MDS_ATTR_KILL_SUID == 2048);
+        CLASSERT(MDS_ATTR_KILL_SGID == 4096);
+        CLASSERT(MDS_ATTR_CTIME_SET == 8192);
+        CLASSERT(MDS_ATTR_FROM_OPEN == 16384);
+        CLASSERT(MDS_ATTR_BLOCKS == 32768);
 
         /* Checks for struct mds_rec_create */
         LASSERTF((int)sizeof(struct mds_rec_create) == 96, " found %lld\n",