]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
common/ceph_strings: get_con_mode_name()
authorSage Weil <sage@redhat.com>
Sun, 17 Feb 2019 15:42:10 +0000 (09:42 -0600)
committerRadoslaw Zarzynski <rzarzyns@redhat.com>
Thu, 21 Feb 2019 22:31:01 +0000 (23:31 +0100)
Signed-off-by: Sage Weil <sage@redhat.com>
src/common/ceph_strings.cc
src/include/ceph_fs.h

index 3e453a2663a53e6752553c0042dfcdd8d78669e9..c7d1b7877d4e007eeb3b14a7c40e4759893a1850 100644 (file)
@@ -17,6 +17,16 @@ const char *ceph_entity_type_name(int type)
        }
 }
 
+const char *ceph_con_mode_name(int con_mode)
+{
+       switch (con_mode) {
+       case CEPH_CON_MODE_UNKNOWN: return "unknown";
+       case CEPH_CON_MODE_CRC: return "crc";
+       case CEPH_CON_MODE_SECURE: return "secure";
+       default: return "???";
+       }
+}
+
 const char *ceph_osd_op_name(int op)
 {
        switch (op) {
index 4b0d3ed75f4b6ba2f7192cc95daf4ee3a61d76a5..3bf4383358a0ca79d3f4b351fbc901bf471f3085 100644 (file)
@@ -78,6 +78,8 @@ struct ceph_dir_layout {
 #define CEPH_CON_MODE_CRC     0x1
 #define CEPH_CON_MODE_SECURE  0x2
 
+extern const char *ceph_con_mode_name(int con_mode);
+
 /*  For options with "_", like: GSS_GSS
     which means: Mode/Protocol to validate "authentication_authorization",
     where: