Whamcloud - gitweb
LU-11444 ptlrpc: Add increasing XIDs CONNECT2 flag 13/35113/3
authorAndriy Skulysh <c17819@cray.com>
Fri, 28 Sep 2018 11:02:22 +0000 (14:02 +0300)
committerOleg Drokin <green@whamcloud.com>
Wed, 3 Jul 2019 03:16:31 +0000 (03:16 +0000)
This patch reserves the OBD_CONNECT2 flag
for increasing XIDs.

Change-Id: Id825ce1c86a345884c9d4cd90cd2e13839a268f0
Cray-bug-id: LUS-6272
Signed-off-by: Andriy Skulysh <c17819@cray.com>
Reviewed-on: https://review.whamcloud.com/35113
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Alexandr Boyko <c17825@cray.com>
lustre/include/lu_target.h
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/obdclass/lprocfs_status.c
lustre/ptlrpc/wiretest.c
lustre/utils/wiretest.c

index 7cafb24..dfb3dcc 100644 (file)
@@ -398,6 +398,10 @@ static inline bool tgt_is_multimodrpcs_client(struct obd_export *exp)
        return exp_connect_flags(exp) & OBD_CONNECT_MULTIMODRPCS;
 }
 
+static inline bool tgt_is_increasing_xid_client(struct obd_export *exp)
+{
+       return exp_connect_flags2(exp) & OBD_CONNECT2_INC_XID;
+}
 
 /* target/tgt_handler.c */
 int tgt_request_handle(struct ptlrpc_request *req);
index e2bd6b3..4389e5d 100644 (file)
@@ -834,6 +834,7 @@ struct ptlrpc_body_v2 {
 #define OBD_CONNECT2_WBC_INTENTS       0x40ULL /* create/unlink/... intents for wbc, also operations under client-held parent locks */
 #define OBD_CONNECT2_LOCK_CONVERT      0x80ULL /* IBITS lock convert support */
 #define OBD_CONNECT2_ARCHIVE_ID_ARRAY  0x100ULL /* store HSM archive_id in array */
+#define OBD_CONNECT2_INC_XID           0x200ULL /* Increasing xid */
 #define OBD_CONNECT2_SELINUX_POLICY    0x400ULL /* has client SELinux policy */
 #define OBD_CONNECT2_LSOM              0x800ULL /* LSOM support */
 #define OBD_CONNECT2_PCC               0x1000ULL /* Persistent Client Cache */
index 6f81f5d..63b28a8 100644 (file)
@@ -780,7 +780,7 @@ static const char *obd_connect_names[] = {
        "wbc",          /* 0x40 */
        "lock_convert",  /* 0x80 */
        "archive_id_array",     /* 0x100 */
-       "unknown",              /* 0x200 */
+       "increasing_xid",       /* 0x200 */
        "selinux_policy",       /* 0x400 */
        "lsom",                 /* 0x800 */
        "pcc",                  /* 0x1000 */
index 7c949f3..6080876 100644 (file)
@@ -1341,6 +1341,8 @@ void lustre_assert_wire_constants(void)
                 OBD_CONNECT2_LOCK_CONVERT);
        LASSERTF(OBD_CONNECT2_ARCHIVE_ID_ARRAY == 0x100ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_ARCHIVE_ID_ARRAY);
+       LASSERTF(OBD_CONNECT2_INC_XID == 0x200ULL, "found 0x%.16llxULL\n",
+                OBD_CONNECT2_INC_XID);
        LASSERTF(OBD_CONNECT2_SELINUX_POLICY == 0x400ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_SELINUX_POLICY);
        LASSERTF(OBD_CONNECT2_LSOM == 0x800ULL, "found 0x%.16llxULL\n",
index 9597231..ad8e89e 100644 (file)
@@ -1362,6 +1362,8 @@ void lustre_assert_wire_constants(void)
                 OBD_CONNECT2_LOCK_CONVERT);
        LASSERTF(OBD_CONNECT2_ARCHIVE_ID_ARRAY == 0x100ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_ARCHIVE_ID_ARRAY);
+       LASSERTF(OBD_CONNECT2_INC_XID == 0x200ULL, "found 0x%.16llxULL\n",
+                OBD_CONNECT2_INC_XID);
        LASSERTF(OBD_CONNECT2_SELINUX_POLICY == 0x400ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_SELINUX_POLICY);
        LASSERTF(OBD_CONNECT2_LSOM == 0x800ULL, "found 0x%.16llxULL\n",