diff options
author | Alex Elder <elder@inktank.com> | 2012-05-27 00:26:43 -0400 |
---|---|---|
committer | Alex Elder <elder@dreamhost.com> | 2012-06-01 09:37:56 -0400 |
commit | 15d9882c336db2db73ccf9871ae2398e452f694c (patch) | |
tree | cfa0c726a69b68f51b344d50114a2961019c1231 /net/ceph/osd_client.c | |
parent | e22004235a900213625acd6583ac913d5a30c155 (diff) |
libceph: embed ceph messenger structure in ceph_client
A ceph client has a pointer to a ceph messenger structure in it.
There is always exactly one ceph messenger for a ceph client, so
there is no need to allocate it separate from the ceph client
structure.
Switch the ceph_client structure to embed its ceph_messenger
structure.
Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Yehuda Sadeh <yehuda@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
Diffstat (limited to 'net/ceph/osd_client.c')
-rw-r--r-- | net/ceph/osd_client.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c index b098e7b591f0..cca4c7f1c780 100644 --- a/net/ceph/osd_client.c +++ b/net/ceph/osd_client.c | |||
@@ -639,7 +639,7 @@ static struct ceph_osd *create_osd(struct ceph_osd_client *osdc) | |||
639 | INIT_LIST_HEAD(&osd->o_osd_lru); | 639 | INIT_LIST_HEAD(&osd->o_osd_lru); |
640 | osd->o_incarnation = 1; | 640 | osd->o_incarnation = 1; |
641 | 641 | ||
642 | ceph_con_init(osdc->client->msgr, &osd->o_con); | 642 | ceph_con_init(&osdc->client->msgr, &osd->o_con); |
643 | osd->o_con.private = osd; | 643 | osd->o_con.private = osd; |
644 | osd->o_con.ops = &osd_con_ops; | 644 | osd->o_con.ops = &osd_con_ops; |
645 | osd->o_con.peer_name.type = CEPH_ENTITY_TYPE_OSD; | 645 | osd->o_con.peer_name.type = CEPH_ENTITY_TYPE_OSD; |
@@ -1391,7 +1391,7 @@ void ceph_osdc_handle_map(struct ceph_osd_client *osdc, struct ceph_msg *msg) | |||
1391 | epoch, maplen); | 1391 | epoch, maplen); |
1392 | newmap = osdmap_apply_incremental(&p, next, | 1392 | newmap = osdmap_apply_incremental(&p, next, |
1393 | osdc->osdmap, | 1393 | osdc->osdmap, |
1394 | osdc->client->msgr); | 1394 | &osdc->client->msgr); |
1395 | if (IS_ERR(newmap)) { | 1395 | if (IS_ERR(newmap)) { |
1396 | err = PTR_ERR(newmap); | 1396 | err = PTR_ERR(newmap); |
1397 | goto bad; | 1397 | goto bad; |