diff options
author | Ilya Dryomov <idryomov@gmail.com> | 2016-06-02 10:45:08 -0400 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2016-08-24 17:49:15 -0400 |
commit | f01d5cb24ea92494f9e093e6ee411364a686be99 (patch) | |
tree | ae43687bb4cdb80b57ef7cee89db8ac060dc0e79 | |
parent | 694d0d0bb2030d2e36df73e2d23d5770511dbc8d (diff) |
libceph: rename ceph_entity_name_encode() -> ceph_auth_entity_name_encode()
Clear up EntityName vs entity_name_t confusion.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Reviewed-by: Mike Christie <mchristi@redhat.com>
Reviewed-by: Alex Elder <elder@linaro.org>
-rw-r--r-- | include/linux/ceph/auth.h | 2 | ||||
-rw-r--r-- | net/ceph/auth.c | 7 | ||||
-rw-r--r-- | net/ceph/auth_none.c | 2 |
3 files changed, 7 insertions, 4 deletions
diff --git a/include/linux/ceph/auth.h b/include/linux/ceph/auth.h index 1563265d2097..374bb1c4ef52 100644 --- a/include/linux/ceph/auth.h +++ b/include/linux/ceph/auth.h | |||
@@ -104,7 +104,7 @@ extern int ceph_auth_build_hello(struct ceph_auth_client *ac, | |||
104 | extern int ceph_handle_auth_reply(struct ceph_auth_client *ac, | 104 | extern int ceph_handle_auth_reply(struct ceph_auth_client *ac, |
105 | void *buf, size_t len, | 105 | void *buf, size_t len, |
106 | void *reply_buf, size_t reply_len); | 106 | void *reply_buf, size_t reply_len); |
107 | extern int ceph_entity_name_encode(const char *name, void **p, void *end); | 107 | int ceph_auth_entity_name_encode(const char *name, void **p, void *end); |
108 | 108 | ||
109 | extern int ceph_build_auth(struct ceph_auth_client *ac, | 109 | extern int ceph_build_auth(struct ceph_auth_client *ac, |
110 | void *msg_buf, size_t msg_len); | 110 | void *msg_buf, size_t msg_len); |
diff --git a/net/ceph/auth.c b/net/ceph/auth.c index 2bc5965fdd1e..78067dda9d3c 100644 --- a/net/ceph/auth.c +++ b/net/ceph/auth.c | |||
@@ -82,7 +82,10 @@ void ceph_auth_reset(struct ceph_auth_client *ac) | |||
82 | mutex_unlock(&ac->mutex); | 82 | mutex_unlock(&ac->mutex); |
83 | } | 83 | } |
84 | 84 | ||
85 | int ceph_entity_name_encode(const char *name, void **p, void *end) | 85 | /* |
86 | * EntityName, not to be confused with entity_name_t | ||
87 | */ | ||
88 | int ceph_auth_entity_name_encode(const char *name, void **p, void *end) | ||
86 | { | 89 | { |
87 | int len = strlen(name); | 90 | int len = strlen(name); |
88 | 91 | ||
@@ -124,7 +127,7 @@ int ceph_auth_build_hello(struct ceph_auth_client *ac, void *buf, size_t len) | |||
124 | for (i = 0; i < num; i++) | 127 | for (i = 0; i < num; i++) |
125 | ceph_encode_32(&p, supported_protocols[i]); | 128 | ceph_encode_32(&p, supported_protocols[i]); |
126 | 129 | ||
127 | ret = ceph_entity_name_encode(ac->name, &p, end); | 130 | ret = ceph_auth_entity_name_encode(ac->name, &p, end); |
128 | if (ret < 0) | 131 | if (ret < 0) |
129 | goto out; | 132 | goto out; |
130 | ceph_decode_need(&p, end, sizeof(u64), bad); | 133 | ceph_decode_need(&p, end, sizeof(u64), bad); |
diff --git a/net/ceph/auth_none.c b/net/ceph/auth_none.c index 5f836f02ae36..df45e467c81f 100644 --- a/net/ceph/auth_none.c +++ b/net/ceph/auth_none.c | |||
@@ -46,7 +46,7 @@ static int ceph_auth_none_build_authorizer(struct ceph_auth_client *ac, | |||
46 | int ret; | 46 | int ret; |
47 | 47 | ||
48 | ceph_encode_8_safe(&p, end, 1, e_range); | 48 | ceph_encode_8_safe(&p, end, 1, e_range); |
49 | ret = ceph_entity_name_encode(ac->name, &p, end); | 49 | ret = ceph_auth_entity_name_encode(ac->name, &p, end); |
50 | if (ret < 0) | 50 | if (ret < 0) |
51 | return ret; | 51 | return ret; |
52 | 52 | ||