Whamcloud - gitweb
LU-10175 ptlrpc: add LOCK_CONVERT connection flag 93/32593/3
authorMikhail Pershin <mike.pershin@intel.com>
Sun, 20 May 2018 18:00:23 +0000 (21:00 +0300)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 14 Jun 2018 03:56:52 +0000 (03:56 +0000)
Add LOCK_CONVERT connection flag to don't use lock
convert feature with old servers.

Test-Parameters: trivial
Signed-off-by: Mikhail Pershin <mike.pershin@intel.com>
Change-Id: Ie860f43955314017609774d692f89cfe3c2ab896
Reviewed-on: https://review.whamcloud.com/32593
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/obdclass/lprocfs_status.c
lustre/ptlrpc/wiretest.c
lustre/utils/wirecheck.c
lustre/utils/wiretest.c

index 11ea4d3..1c821a0 100644 (file)
@@ -808,6 +808,7 @@ struct ptlrpc_body_v2 {
 #define OBD_CONNECT2_DIR_MIGRATE        0x4ULL /* migrate striped dir */
 #define OBD_CONNECT2_FLR               0x20ULL /* FLR support */
 #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 */
 
 /* XXX README XXX:
  * Please DO NOT add flag values here before first ensuring that this same
index 1c30d87..fbe115a 100644 (file)
@@ -807,6 +807,7 @@ static const char *obd_connect_names[] = {
        "unknown",      /* 0x10 */
        "flr",          /* 0x20 */
        "wbc",          /* 0x40 */
+       "lock_convert",  /* 0x80 */
        NULL
 };
 
index 0adfdba..e44d933 100644 (file)
@@ -1308,6 +1308,8 @@ void lustre_assert_wire_constants(void)
                 OBD_CONNECT2_FLR);
        LASSERTF(OBD_CONNECT2_WBC_INTENTS == 0x40ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_WBC_INTENTS);
+       LASSERTF(OBD_CONNECT2_LOCK_CONVERT == 0x80ULL, "found 0x%.16llxULL\n",
+                OBD_CONNECT2_LOCK_CONVERT);
        LASSERTF(OBD_CKSUM_CRC32 == 0x00000001UL, "found 0x%.8xUL\n",
                (unsigned)OBD_CKSUM_CRC32);
        LASSERTF(OBD_CKSUM_ADLER == 0x00000002UL, "found 0x%.8xUL\n",
index 67efc67..72151df 100644 (file)
@@ -590,6 +590,7 @@ check_obd_connect_data(void)
        CHECK_DEFINE_64X(OBD_CONNECT2_DIR_MIGRATE);
        CHECK_DEFINE_64X(OBD_CONNECT2_FLR);
        CHECK_DEFINE_64X(OBD_CONNECT2_WBC_INTENTS);
+       CHECK_DEFINE_64X(OBD_CONNECT2_LOCK_CONVERT);
 
        CHECK_VALUE_X(OBD_CKSUM_CRC32);
        CHECK_VALUE_X(OBD_CKSUM_ADLER);
index 777e224..0264979 100644 (file)
@@ -1325,10 +1325,12 @@ void lustre_assert_wire_constants(void)
                 OBD_CONNECT2_LOCKAHEAD);
        LASSERTF(OBD_CONNECT2_DIR_MIGRATE == 0x4ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_DIR_MIGRATE);
-       LASSERTF(OBD_CONNECT2_FLR == 0x20ULL, "found 0x%.16llxULL\n",
+       LASSERTF(OBD_CONNECT2_FLR == 0x20ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_FLR);
        LASSERTF(OBD_CONNECT2_WBC_INTENTS == 0x40ULL, "found 0x%.16llxULL\n",
                 OBD_CONNECT2_WBC_INTENTS);
+       LASSERTF(OBD_CONNECT2_LOCK_CONVERT == 0x80ULL, "found 0x%.16llxULL\n",
+                OBD_CONNECT2_LOCK_CONVERT);
        LASSERTF(OBD_CKSUM_CRC32 == 0x00000001UL, "found 0x%.8xUL\n",
                (unsigned)OBD_CKSUM_CRC32);
        LASSERTF(OBD_CKSUM_ADLER == 0x00000002UL, "found 0x%.8xUL\n",