ceph: make sure request isn't in any waiting list when kicking request.
authorYan, Zheng <ukernel@gmail.com>
Thu, 11 Sep 2014 06:28:56 +0000 (14:28 +0800)
committerIlya Dryomov <idryomov@redhat.com>
Tue, 14 Oct 2014 17:03:24 +0000 (21:03 +0400)
we may corrupt waiting list if a request in the waiting list is kicked.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
fs/ceph/mds_client.c

index 267ba4496dc8c9da7c0547fdd7a71266fca3dc61..a17fc49c9948ad5d454d448381733545e6b7a057 100644 (file)
@@ -2078,6 +2078,7 @@ static void kick_requests(struct ceph_mds_client *mdsc, int mds)
                if (req->r_session &&
                    req->r_session->s_mds == mds) {
                        dout(" kicking tid %llu\n", req->r_tid);
+                       list_del_init(&req->r_wait);
                        __do_request(mdsc, req);
                }
        }