remarkable-linux/include/linux/ceph
Alex Elder ace6d3a96f libceph: drop ceph_osd_request->r_con_filling_msg
A field in an osd request keeps track of whether a connection is
currently filling the request's reply message.  This patch gets rid
of that field.

An osd request includes two messages--a request and a reply--and
they're both associated with the connection that existed to its
the target osd at the time the request was created.

An osd request can be dropped early, even when it's in flight.
And at that time both messages are released.  It's possible the
reply message has been supplied to its connection to receive
an incoming response message at the time the osd request gets
dropped.  So ceph_osdc_release_request() revokes that message
from the connection before releasing it so things get cleaned up
properly.

Previously this may have caused a problem, because the connection
that a message was associated with might have gone away before the
revoke request.  And to avoid any problems using that connection,
the osd client held a reference to it when it supplies its response
message.

However since this commit:
    38941f80 libceph: have messages point to their connection
all messages hold a reference to the connection they are associated
with whenever the connection is actively operating on the message
(i.e. while the message is queued to send or sending, and when it
data is being received into it).  And if a message has no connection
associated with it, ceph_msg_revoke_incoming() won't do anything
when asked to revoke it.

As a result, there is no need to keep an additional reference to the
connection associated with a message when we hand the message to the
messenger when it calls our alloc_msg() method to receive something.
If the connection *were* operating on it, it would have its own
reference, and if not, there's no work to be done when we need to
revoke it.

So get rid of the osd request's r_con_filling_msg field.

This resolves:
    http://tracker.ceph.com/issues/4647

Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
2013-05-01 21:17:54 -07:00
..
auth.h libceph: wrap auth methods in a mutex 2013-05-01 21:17:15 -07:00
buffer.h
ceph_debug.h
ceph_features.h libceph: implement RECONNECT_SEQ feature 2013-05-01 21:17:09 -07:00
ceph_frag.h
ceph_fs.h libceph: update ceph_fs.h 2013-02-18 12:20:30 -06:00
ceph_hash.h
debugfs.h UAPI: (Scripted) Convert #include "..." to #include <path/...> in kernel system headers 2012-10-02 18:01:25 +01:00
decode.h ceph: move max constant definitions 2013-05-01 21:17:42 -07:00
libceph.h libceph: define CEPH_MSG_MAX_MIDDLE_LEN 2013-05-01 21:16:29 -07:00
mdsmap.h ceph: update support for PGID64, PGPOOL3, OSDENC protocol features 2013-02-26 15:02:25 -08:00
messenger.h libceph: make message data be a pointer 2013-05-01 21:17:37 -07:00
mon_client.h Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client 2012-10-08 06:38:18 +09:00
msgpool.h UAPI: (Scripted) Convert #include "..." to #include <path/...> in kernel system headers 2012-10-02 18:01:25 +01:00
msgr.h libceph: implement RECONNECT_SEQ feature 2013-05-01 21:17:09 -07:00
osd_client.h libceph: drop ceph_osd_request->r_con_filling_msg 2013-05-01 21:17:54 -07:00
osdmap.h libceph: define ceph_decode_pgid() only once 2013-05-01 21:17:52 -07:00
pagelist.h
rados.h libceph: update osd request/reply encoding 2013-02-26 15:02:50 -08:00
types.h UAPI: (Scripted) Convert #include "..." to #include <path/...> in kernel system headers 2012-10-02 18:01:25 +01:00