Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 188686
b: refs/heads/master
c: ac8839d
h: refs/heads/master
v: v3
  • Loading branch information
Sage Weil committed Jan 29, 2010
1 parent db2151e commit 4aa5925
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 361be8601d78e488b5249032cc4e779b81d7928e
refs/heads/master: ac8839d7b264d0fa478fca7c4f9b6bb833540a80
1 change: 1 addition & 0 deletions trunk/fs/ceph/decode.h
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ static inline void ceph_encode_filepath(void **p, void *end,
{
u32 len = path ? strlen(path) : 0;
BUG_ON(*p + sizeof(ino) + sizeof(len) + len > end);
ceph_encode_8(p, 1);
ceph_encode_64(p, ino);
ceph_encode_32(p, len);
if (len)
Expand Down
2 changes: 1 addition & 1 deletion trunk/fs/ceph/mds_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -1325,7 +1325,7 @@ static struct ceph_msg *create_request_message(struct ceph_mds_client *mdsc,
}

len = sizeof(*head) +
pathlen1 + pathlen2 + 2*(sizeof(u32) + sizeof(u64));
pathlen1 + pathlen2 + 2*(1 + sizeof(u32) + sizeof(u64));

/* calculate (max) length for cap releases */
len += sizeof(struct ceph_mds_request_release) *
Expand Down
1 change: 1 addition & 0 deletions trunk/fs/ceph/messenger.c
Original file line number Diff line number Diff line change
Expand Up @@ -1909,6 +1909,7 @@ struct ceph_messenger *ceph_messenger_create(struct ceph_entity_addr *myaddr)
msgr->inst.addr = *myaddr;

/* select a random nonce */
msgr->inst.addr.type = 0;
get_random_bytes(&msgr->inst.addr.nonce, sizeof(msgr->inst.addr.nonce));
encode_my_addr(msgr);

Expand Down
5 changes: 3 additions & 2 deletions trunk/fs/ceph/msgr.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
* whenever the wire protocol changes. try to keep this string length
* constant.
*/
#define CEPH_BANNER "ceph v026"
#define CEPH_BANNER "ceph v027"
#define CEPH_BANNER_MAX_LEN 30


Expand Down Expand Up @@ -61,7 +61,8 @@ extern const char *ceph_entity_type_name(int type);
* entity_addr -- network address
*/
struct ceph_entity_addr {
__le64 nonce; /* unique id for process (e.g. pid) */
__le32 type;
__le32 nonce; /* unique id for process (e.g. pid) */
struct sockaddr_storage in_addr;
} __attribute__ ((packed));

Expand Down

0 comments on commit 4aa5925

Please sign in to comment.