~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/net/ceph/ceph_strings.c

Version: ~ [ linux-5.8-rc4 ] ~ [ linux-5.7.7 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.50 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.131 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.187 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.229 ] ~ [ linux-4.8.17 ] ~ [ linux-4.7.10 ] ~ [ linux-4.6.7 ] ~ [ linux-4.5.7 ] ~ [ linux-4.4.229 ] ~ [ linux-4.3.6 ] ~ [ linux-4.2.8 ] ~ [ linux-4.1.52 ] ~ [ linux-4.0.9 ] ~ [ linux-3.19.8 ] ~ [ linux-3.18.140 ] ~ [ linux-3.17.8 ] ~ [ linux-3.16.85 ] ~ [ linux-3.15.10 ] ~ [ linux-3.14.79 ] ~ [ linux-3.13.11 ] ~ [ linux-3.12.74 ] ~ [ linux-3.11.10 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.5 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /*
  2  * Ceph string constants
  3  */
  4 #include <linux/module.h>
  5 #include <linux/ceph/types.h>
  6 
  7 const char *ceph_entity_type_name(int type)
  8 {
  9         switch (type) {
 10         case CEPH_ENTITY_TYPE_MDS: return "mds";
 11         case CEPH_ENTITY_TYPE_OSD: return "osd";
 12         case CEPH_ENTITY_TYPE_MON: return "mon";
 13         case CEPH_ENTITY_TYPE_CLIENT: return "client";
 14         case CEPH_ENTITY_TYPE_AUTH: return "auth";
 15         default: return "unknown";
 16         }
 17 }
 18 
 19 const char *ceph_osd_op_name(int op)
 20 {
 21         switch (op) {
 22         case CEPH_OSD_OP_READ: return "read";
 23         case CEPH_OSD_OP_STAT: return "stat";
 24         case CEPH_OSD_OP_MAPEXT: return "mapext";
 25         case CEPH_OSD_OP_SPARSE_READ: return "sparse-read";
 26         case CEPH_OSD_OP_NOTIFY: return "notify";
 27         case CEPH_OSD_OP_NOTIFY_ACK: return "notify-ack";
 28         case CEPH_OSD_OP_ASSERT_VER: return "assert-version";
 29 
 30         case CEPH_OSD_OP_MASKTRUNC: return "masktrunc";
 31 
 32         case CEPH_OSD_OP_CREATE: return "create";
 33         case CEPH_OSD_OP_WRITE: return "write";
 34         case CEPH_OSD_OP_DELETE: return "delete";
 35         case CEPH_OSD_OP_TRUNCATE: return "truncate";
 36         case CEPH_OSD_OP_ZERO: return "zero";
 37         case CEPH_OSD_OP_WRITEFULL: return "writefull";
 38         case CEPH_OSD_OP_ROLLBACK: return "rollback";
 39 
 40         case CEPH_OSD_OP_APPEND: return "append";
 41         case CEPH_OSD_OP_STARTSYNC: return "startsync";
 42         case CEPH_OSD_OP_SETTRUNC: return "settrunc";
 43         case CEPH_OSD_OP_TRIMTRUNC: return "trimtrunc";
 44 
 45         case CEPH_OSD_OP_TMAPUP: return "tmapup";
 46         case CEPH_OSD_OP_TMAPGET: return "tmapget";
 47         case CEPH_OSD_OP_TMAPPUT: return "tmapput";
 48         case CEPH_OSD_OP_WATCH: return "watch";
 49 
 50         case CEPH_OSD_OP_CLONERANGE: return "clonerange";
 51         case CEPH_OSD_OP_ASSERT_SRC_VERSION: return "assert-src-version";
 52         case CEPH_OSD_OP_SRC_CMPXATTR: return "src-cmpxattr";
 53 
 54         case CEPH_OSD_OP_GETXATTR: return "getxattr";
 55         case CEPH_OSD_OP_GETXATTRS: return "getxattrs";
 56         case CEPH_OSD_OP_SETXATTR: return "setxattr";
 57         case CEPH_OSD_OP_SETXATTRS: return "setxattrs";
 58         case CEPH_OSD_OP_RESETXATTRS: return "resetxattrs";
 59         case CEPH_OSD_OP_RMXATTR: return "rmxattr";
 60         case CEPH_OSD_OP_CMPXATTR: return "cmpxattr";
 61 
 62         case CEPH_OSD_OP_PULL: return "pull";
 63         case CEPH_OSD_OP_PUSH: return "push";
 64         case CEPH_OSD_OP_BALANCEREADS: return "balance-reads";
 65         case CEPH_OSD_OP_UNBALANCEREADS: return "unbalance-reads";
 66         case CEPH_OSD_OP_SCRUB: return "scrub";
 67         case CEPH_OSD_OP_SCRUB_RESERVE: return "scrub-reserve";
 68         case CEPH_OSD_OP_SCRUB_UNRESERVE: return "scrub-unreserve";
 69         case CEPH_OSD_OP_SCRUB_STOP: return "scrub-stop";
 70         case CEPH_OSD_OP_SCRUB_MAP: return "scrub-map";
 71 
 72         case CEPH_OSD_OP_WRLOCK: return "wrlock";
 73         case CEPH_OSD_OP_WRUNLOCK: return "wrunlock";
 74         case CEPH_OSD_OP_RDLOCK: return "rdlock";
 75         case CEPH_OSD_OP_RDUNLOCK: return "rdunlock";
 76         case CEPH_OSD_OP_UPLOCK: return "uplock";
 77         case CEPH_OSD_OP_DNLOCK: return "dnlock";
 78 
 79         case CEPH_OSD_OP_CALL: return "call";
 80 
 81         case CEPH_OSD_OP_PGLS: return "pgls";
 82         case CEPH_OSD_OP_PGLS_FILTER: return "pgls-filter";
 83         case CEPH_OSD_OP_OMAPGETKEYS: return "omap-get-keys";
 84         case CEPH_OSD_OP_OMAPGETVALS: return "omap-get-vals";
 85         case CEPH_OSD_OP_OMAPGETHEADER: return "omap-get-header";
 86         case CEPH_OSD_OP_OMAPGETVALSBYKEYS: return "omap-get-vals-by-keys";
 87         case CEPH_OSD_OP_OMAPSETVALS: return "omap-set-vals";
 88         case CEPH_OSD_OP_OMAPSETHEADER: return "omap-set-header";
 89         case CEPH_OSD_OP_OMAPCLEAR: return "omap-clear";
 90         case CEPH_OSD_OP_OMAPRMKEYS: return "omap-rm-keys";
 91         }
 92         return "???";
 93 }
 94 
 95 const char *ceph_osd_state_name(int s)
 96 {
 97         switch (s) {
 98         case CEPH_OSD_EXISTS:
 99                 return "exists";
100         case CEPH_OSD_UP:
101                 return "up";
102         case CEPH_OSD_AUTOOUT:
103                 return "autoout";
104         case CEPH_OSD_NEW:
105                 return "new";
106         default:
107                 return "???";
108         }
109 }
110 
111 const char *ceph_pool_op_name(int op)
112 {
113         switch (op) {
114         case POOL_OP_CREATE: return "create";
115         case POOL_OP_DELETE: return "delete";
116         case POOL_OP_AUID_CHANGE: return "auid change";
117         case POOL_OP_CREATE_SNAP: return "create snap";
118         case POOL_OP_DELETE_SNAP: return "delete snap";
119         case POOL_OP_CREATE_UNMANAGED_SNAP: return "create unmanaged snap";
120         case POOL_OP_DELETE_UNMANAGED_SNAP: return "delete unmanaged snap";
121         }
122         return "???";
123 }
124 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | Wiki (Japanese) | Wiki (English) | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

osdn.jp