Skip to content
Snippets Groups Projects
Commit c584acbe authored by Yury Umanets's avatar Yury Umanets
Browse files

b=17310

r=shadow,vitaly
- correct check for phase in ptlrpc_expired_set() and couple of other places.
parent c448adfa
No related branches found
No related tags found
No related merge requests found
......@@ -1372,10 +1372,8 @@ int ptlrpc_expired_set(void *data)
list_entry(tmp, struct ptlrpc_request, rq_set_chain);
/* Request in-flight? */
if (!((req->rq_phase &
(RQ_PHASE_RPC & RQ_PHASE_UNREGISTERING) &&
!req->rq_waiting && !req->rq_resend) ||
(req->rq_phase == RQ_PHASE_BULK)))
if (!((req->rq_phase == RQ_PHASE_RPC && !req->rq_waiting &&
!req->rq_resend) || (req->rq_phase == RQ_PHASE_BULK)))
continue;
if (req->rq_timedout || /* already dealt with */
......@@ -1436,20 +1434,11 @@ int ptlrpc_set_next_timeout(struct ptlrpc_request_set *set)
req = list_entry(tmp, struct ptlrpc_request, rq_set_chain);
/* Request in-flight? */
if (!(((req->rq_phase &
(RQ_PHASE_RPC | RQ_PHASE_UNREGISTERING)) &&
!req->rq_waiting) ||
if (!(((req->rq_phase == RQ_PHASE_RPC) && !req->rq_waiting) ||
(req->rq_phase == RQ_PHASE_BULK) ||
(req->rq_phase == RQ_PHASE_NEW)))
continue;
/* Check those waiting for long reply unlink every one
* second. */
if (req->rq_phase == RQ_PHASE_UNREGISTERING) {
timeout = 1;
break;
}
/* Already timed out. */
if (req->rq_timedout)
continue;
......
......@@ -204,9 +204,8 @@ ptlrpc_inflight_deadline(struct ptlrpc_request *req, time_t now)
{
long dl;
if (!(((req->rq_phase & (RQ_PHASE_RPC | RQ_PHASE_UNREGISTERING)) &&
!req->rq_waiting) ||
(req->rq_phase == RQ_PHASE_BULK) ||
if (!(((req->rq_phase == RQ_PHASE_RPC) && !req->rq_waiting) ||
(req->rq_phase == RQ_PHASE_BULK) ||
(req->rq_phase == RQ_PHASE_NEW)))
return 0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment