mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-28 21:33:52 +00:00
ceph: flush cap releases when the session is flushed
commit e7d84c6a12
upstream.
MDS expects the completed cap release prior to responding to the
session flush for cache drop.
Cc: stable@vger.kernel.org
Link: http://tracker.ceph.com/issues/38009
Signed-off-by: Xiubo Li <xiubli@redhat.com>
Reviewed-by: Venky Shankar <vshankar@redhat.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
62890f3eab
commit
a89868254c
1 changed files with 6 additions and 0 deletions
|
@ -3662,6 +3662,12 @@ static void handle_session(struct ceph_mds_session *session,
|
|||
break;
|
||||
|
||||
case CEPH_SESSION_FLUSHMSG:
|
||||
/* flush cap releases */
|
||||
spin_lock(&session->s_cap_lock);
|
||||
if (session->s_num_cap_releases)
|
||||
ceph_flush_cap_releases(mdsc, session);
|
||||
spin_unlock(&session->s_cap_lock);
|
||||
|
||||
send_flushmsg_ack(mdsc, session, seq);
|
||||
break;
|
||||
|
||||
|
|
Loading…
Reference in a new issue