Whamcloud - gitweb
LU-10855 ptlrpc: remove obsolete OBD RPC opcodes 51/32651/3
authorAndreas Dilger <andreas.dilger@intel.com>
Wed, 6 Jun 2018 20:41:13 +0000 (14:41 -0600)
committerOleg Drokin <green@whamcloud.com>
Wed, 18 Jul 2018 06:00:33 +0000 (06:00 +0000)
Remove the obsolete OBD_LOG_CANCEL (since Lustre 1.5) and
OBD_QC_CALLBACK (since Lustre 2.4) RPC opcodes.

Assign  OBD_IDX_READ an explicit opcode (as should be done with all
enums in lustre_idl.h) so that the value does not change if some
prior field is removed.

Also remove the OBD_FAIL checks that were used to test them.
The setting in conf_sanity.sh test_58 was unused for many years.

Test-Parameters: trivial testlist=conf-sanity
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: Ie68c6be0da1c114fc981cb4b1afdcdb7c13ebbe5
Reviewed-on: https://review.whamcloud.com/32651
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <jhammond@whamcloud.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/obd_support.h
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/ptlrpc/lproc_ptlrpc.c
lustre/ptlrpc/wiretest.c
lustre/tests/conf-sanity.sh
lustre/utils/wirecheck.c
lustre/utils/wiretest.c

index db8378b..cc9ec19 100644 (file)
@@ -431,12 +431,12 @@ extern char obd_jobid_var[];
 #define OBD_FAIL_PTLRPC_BULK_ATTACH      0x521
 
 #define OBD_FAIL_OBD_PING_NET            0x600
-#define OBD_FAIL_OBD_LOG_CANCEL_NET      0x601
+/*     OBD_FAIL_OBD_LOG_CANCEL_NET      0x601 obsolete since 1.5 */
 #define OBD_FAIL_OBD_LOGD_NET            0x602
 /*     OBD_FAIL_OBD_QC_CALLBACK_NET     0x603 obsolete since 2.4 */
 #define OBD_FAIL_OBD_DQACQ               0x604
 #define OBD_FAIL_OBD_LLOG_SETUP          0x605
-#define OBD_FAIL_OBD_LOG_CANCEL_REP      0x606
+/*     OBD_FAIL_OBD_LOG_CANCEL_REP      0x606 obsolete since 1.5 */
 #define OBD_FAIL_OBD_IDX_READ_NET        0x607
 #define OBD_FAIL_OBD_IDX_READ_BREAK     0x608
 #define OBD_FAIL_OBD_NO_LRU             0x609
index 7999816..a7ce930 100644 (file)
@@ -2557,13 +2557,13 @@ struct cfg_marker {
  * Opcodes for multiple servers.
  */
 enum obd_cmd {
-       OBD_PING = 400,
-       OBD_LOG_CANCEL, /* Obsolete since 1.5. */
-       OBD_QC_CALLBACK, /* not used since 2.4 */
-       OBD_IDX_READ,
-        OBD_LAST_OPC
+       OBD_PING        = 400,
+/*     OBD_LOG_CANCEL  = 401, obsolete since 1.5 */
+/*     OBD_QC_CALLBACK = 402, obsolete since 2.4 */
+       OBD_IDX_READ    = 403,
+       OBD_LAST_OPC,
+       OBD_FIRST_OPC = OBD_PING
 };
-#define OBD_FIRST_OPC OBD_PING
 
 /**
  * llog contexts indices.
index 89d256d..dac0942 100644 (file)
@@ -109,10 +109,10 @@ static struct ll_rpc_opcode {
         { MGS_TARGET_DEL,   "mgs_target_del" },
         { MGS_SET_INFO,     "mgs_set_info" },
         { MGS_CONFIG_READ,  "mgs_config_read" },
-        { OBD_PING,         "obd_ping" },
-       { OBD_LOG_CANCEL,       "llog_cancel" },
-        { OBD_QC_CALLBACK,  "obd_quota_callback" },
-       { OBD_IDX_READ,     "dt_index_read" },
+       { OBD_PING,                      "obd_ping" },
+       { 401, /* was OBD_LOG_CANCEL */  "llog_cancel" },
+       { 402, /* was OBD_QC_CALLBACK */ "obd_quota_callback" },
+       { OBD_IDX_READ,                  "dt_index_read" },
        { LLOG_ORIGIN_HANDLE_CREATE,     "llog_origin_handle_open" },
         { LLOG_ORIGIN_HANDLE_NEXT_BLOCK, "llog_origin_handle_next_block" },
         { LLOG_ORIGIN_HANDLE_READ_HEADER,"llog_origin_handle_read_header" },
index e44d933..9aa4553 100644 (file)
@@ -338,10 +338,6 @@ void lustre_assert_wire_constants(void)
        CLASSERT(LQUOTA_RES_DT == 2);
        LASSERTF(OBD_PING == 400, "found %lld\n",
                 (long long)OBD_PING);
-       LASSERTF(OBD_LOG_CANCEL == 401, "found %lld\n",
-                (long long)OBD_LOG_CANCEL);
-       LASSERTF(OBD_QC_CALLBACK == 402, "found %lld\n",
-                (long long)OBD_QC_CALLBACK);
        LASSERTF(OBD_IDX_READ == 403, "found %lld\n",
                 (long long)OBD_IDX_READ);
        LASSERTF(OBD_LAST_OPC == 404, "found %lld\n",
index 10408d5..aa6c654 100644 (file)
@@ -4376,9 +4376,6 @@ test_58() { # bug 22658
        setup_noconfig
        mkdir $DIR/$tdir || error "mkdir $DIR/$tdir failed"
        createmany -o $DIR/$tdir/$tfile-%d 100
-       # make sure that OSTs do not cancel llog cookies before we unmount the MDS
-#define OBD_FAIL_OBD_LOG_CANCEL_NET      0x601
-       do_facet $SINGLEMDS "$LCTL set_param fail_loc=0x601"
        unlinkmany $DIR/$tdir/$tfile-%d 100
        stop_mds || error "Unable to stop MDS"
 
index 72151df..178fc8f 100644 (file)
@@ -2703,8 +2703,6 @@ main(int argc, char **argv)
        CHECK_CVALUE(LQUOTA_RES_DT);
 
        CHECK_VALUE(OBD_PING);
-       CHECK_VALUE(OBD_LOG_CANCEL);
-       CHECK_VALUE(OBD_QC_CALLBACK);
        CHECK_VALUE(OBD_IDX_READ);
        CHECK_VALUE(OBD_LAST_OPC);
 
index 0264979..a83a3db 100644 (file)
@@ -359,10 +359,6 @@ void lustre_assert_wire_constants(void)
        CLASSERT(LQUOTA_RES_DT == 2);
        LASSERTF(OBD_PING == 400, "found %lld\n",
                 (long long)OBD_PING);
-       LASSERTF(OBD_LOG_CANCEL == 401, "found %lld\n",
-                (long long)OBD_LOG_CANCEL);
-       LASSERTF(OBD_QC_CALLBACK == 402, "found %lld\n",
-                (long long)OBD_QC_CALLBACK);
        LASSERTF(OBD_IDX_READ == 403, "found %lld\n",
                 (long long)OBD_IDX_READ);
        LASSERTF(OBD_LAST_OPC == 404, "found %lld\n",