- if ((last + cdt->cdt_active_req_timeout)
- < cfs_time_current_sec()) {
- struct hsm_progress_kernel pgs;
-
- dump_llog_agent_req_rec("mdt_coordinator_cb(): "
- "request timeouted, start "
- "cleaning", larr);
- /* a too old cancel request just needs to be removed
- * this can happen, if copy tool does not support cancel
- * for other requests, we have to remove the running
- * request and notify the copytool
- */
- pgs.hpk_fid = larr->arr_hai.hai_fid;
- pgs.hpk_cookie = larr->arr_hai.hai_cookie;
- pgs.hpk_extent = larr->arr_hai.hai_extent;
- pgs.hpk_flags = HP_FLAG_COMPLETED;
- pgs.hpk_errval = ENOSYS;
- pgs.hpk_data_version = 0;
- /* update request state, but do not record in llog, to
- * avoid deadlock on cdt_llog_lock
- */
- rc = mdt_hsm_update_request_state(hsd->mti, &pgs, 0);
- if (rc)
- CERROR("%s: Cannot cleanup timeouted request: "
- DFID" for cookie "LPX64" action=%s\n",
- mdt_obd_name(mdt),
- PFID(&pgs.hpk_fid), pgs.hpk_cookie,
- hsm_copytool_action2name(
- larr->arr_hai.hai_action));
-
- if (rc == -ENOENT) {
- /* The request no longer exists, forget
- * about it, and do not send a cancel request
- * to the client, for which an error will be
- * sent back, leading to an endless cycle of
- * cancellation. */
- RETURN(LLOG_DEL_RECORD);
- }
-
- /* add the cookie to the list of record to be
- * canceled by caller */
- if (hsd->max_cookie == (hsd->cookie_cnt - 1)) {
- __u64 *ptr, *old_ptr;
- int old_sz, new_sz, new_cnt;