mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-23 09:19:51 +00:00
ceph: cleanup aborted requests when re-sending requests.
Aborted requests usually get cleared when the reply is received. If MDS crashes, no reply will be received. So we need to cleanup aborted requests when re-sending requests. Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com> Reviewed-by: Greg Farnum <greg@inktank.com> Signed-off-by: Sage Weil <sage@inktank.com>
This commit is contained in:
parent
99a9c273b9
commit
eb1b8af33c
1 changed files with 4 additions and 1 deletions
|
@ -1872,8 +1872,11 @@ static int __do_request(struct ceph_mds_client *mdsc,
|
|||
int mds = -1;
|
||||
int err = -EAGAIN;
|
||||
|
||||
if (req->r_err || req->r_got_result)
|
||||
if (req->r_err || req->r_got_result) {
|
||||
if (req->r_aborted)
|
||||
__unregister_request(mdsc, req);
|
||||
goto out;
|
||||
}
|
||||
|
||||
if (req->r_timeout &&
|
||||
time_after_eq(jiffies, req->r_started + req->r_timeout)) {
|
||||
|
|
Loading…
Reference in a new issue