@@ -364,7 +364,7 @@ int fld_client_rpc(struct obd_export *exp,
if (OBD_FAIL_CHECK(OBD_FAIL_FLD_QUERY_REQ && req->rq_no_delay)) {
/* the same error returned by ptlrpc_import_delay_req */
- rc = -EWOULDBLOCK;
+ rc = -EAGAIN;
req->rq_status = rc;
} else {
obd_get_request_slot(&exp->exp_obd->u.cli);
@@ -1637,7 +1637,7 @@ struct cl_io_operations {
enum cl_enq_flags {
/**
* instruct server to not block, if conflicting lock is found. Instead
- * -EWOULDBLOCK is returned immediately.
+ * -EAGAIN is returned immediately.
*/
CEF_NONBLOCK = 0x00000001,
/**
@@ -207,7 +207,7 @@ int __cl_glimpse_size(struct inode *inode, int agl)
} else if (result == 0) {
result = cl_glimpse_lock(env, io, inode, io->ci_obj,
agl);
- if (!agl && result == -EWOULDBLOCK)
+ if (!agl && result == -EAGAIN)
io->ci_need_restart = 1;
}
@@ -272,7 +272,7 @@ static void vvp_page_completion_read(const struct lu_env *env,
cl_page_export(env, page, 1);
} else if (vpg->vpg_defer_uptodate) {
vpg->vpg_defer_uptodate = 0;
- if (ioret == -EWOULDBLOCK) {
+ if (ioret == -EAGAIN) {
/* mirror read failed, it needs to destroy the page
* because subpage would be from wrong osc when trying
* to read from a new mirror
@@ -749,7 +749,7 @@ int cl_io_loop(const struct lu_env *env, struct cl_io *io)
if (rc && !result)
result = rc;
- if (result == -EWOULDBLOCK && io->ci_ndelay) {
+ if (result == -EAGAIN && io->ci_ndelay) {
io->ci_need_restart = 1;
result = 0;
}
@@ -406,7 +406,7 @@ int osc_io_iter_init(const struct lu_env *env, const struct cl_io_slice *ios)
*/
if (ios->cis_io->ci_type == CIT_READ && ios->cis_io->ci_ndelay &&
!ios->cis_io->ci_tried_all_mirrors && osc_import_not_healthy(imp)) {
- rc = -EWOULDBLOCK;
+ rc = -EAGAIN;
} else if (likely(!imp->imp_invalid)) {
atomic_inc(&osc->oo_nr_ios);
oio->oi_is_active = 1;
@@ -306,7 +306,7 @@ static int osc_lock_upcall(void *cookie, struct lustre_handle *lockh,
/* Hide the error. */
rc = 0;
} else if (rc < 0 && oscl->ols_flags & LDLM_FL_NDELAY) {
- rc = -EWOULDBLOCK;
+ rc = -EAGAIN;
}
if (oscl->ols_owner)
@@ -2430,7 +2430,7 @@ static int brw_interpret(const struct lu_env *env,
list_for_each_entry_safe(ext, tmp, &aa->aa_exts, oe_link) {
list_del_init(&ext->oe_link);
osc_extent_finish(env, ext, 1,
- rc && req->rq_no_delay ? -EWOULDBLOCK : rc);
+ rc && req->rq_no_delay ? -EAGAIN : rc);
}
LASSERT(list_empty(&aa->aa_exts));
LASSERT(list_empty(&aa->aa_oaps));
@@ -1236,7 +1236,7 @@ static int ptlrpc_import_delay_req(struct obd_import *imp,
} else if (req->rq_no_delay &&
imp->imp_generation != imp->imp_initiated_at) {
/* ignore nodelay for requests initiating connections */
- *status = -EWOULDBLOCK;
+ *status = -EAGAIN;
} else if (req->rq_allow_replay &&
(imp->imp_state == LUSTRE_IMP_REPLAY ||
imp->imp_state == LUSTRE_IMP_REPLAY_LOCKS ||
@@ -36,8 +36,8 @@
* The two translation tables below must define a one-to-one mapping between
* host and network errnos.
*
- * EWOULDBLOCK is equal to EAGAIN on all architectures except for parisc, which
- * appears irrelevant. Thus, existing references to EWOULDBLOCK are fine.
+ * EAGAIN is equal to EAGAIN on all architectures except for parisc, which
+ * appears irrelevant. Thus, existing references to EAGAIN are fine.
*
* EDEADLOCK is equal to EDEADLK on x86 but not on sparc, at least. A sparc
* host has no context-free way to determine if a LUSTRE_EDEADLK represents an
@@ -720,7 +720,7 @@ int sptlrpc_req_refresh_ctx(struct ptlrpc_request *req, long timeout)
spin_unlock(&ctx->cc_lock);
if (timeout == 0)
- return -EWOULDBLOCK;
+ return -EAGAIN;
/* Clear any flags that may be present from previous sends */
LASSERT(req->rq_receiving_reply == 0);