From: Ann Koehler Date: Thu, 14 Nov 2013 22:02:15 +0000 (-0600) Subject: LU-4253 osc: Don't flush active extents. X-Git-Tag: 2.5.53~70 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=88198f6f410d80c1c76b2d6c85f40b9d1bcf7ad9 LU-4253 osc: Don't flush active extents. The extent is active so we need to abort and let the caller re-dirty the page. If we continued on here, and we were the one making the extent active, we could deadlock waiting for the page writeback to clear but it won't because the extent is active and won't be written out. Signed-off-by: Ann Koehler Change-Id: Iba646d8185b12ab227fe0bbee1c6602ccdc32ad6 Reviewed-on: http://review.whamcloud.com/8278 Tested-by: Jenkins Reviewed-by: Jinshan Xiong Tested-by: Maloo Reviewed-by: Alex Zhuravlev Reviewed-by: Alexey Lyashkov Reviewed-by: Oleg Drokin --- diff --git a/lustre/osc/osc_cache.c b/lustre/osc/osc_cache.c index 3dbb375..5c25dfd 100644 --- a/lustre/osc/osc_cache.c +++ b/lustre/osc/osc_cache.c @@ -2555,6 +2555,12 @@ int osc_flush_async_page(const struct lu_env *env, struct cl_io *io, * really sending the RPC. */ case OES_TRUNC: /* race with truncate, page will be redirtied */ + case OES_ACTIVE: + /* The extent is active so we need to abort and let the caller + * re-dirty the page. If we continued on here, and we were the + * one making the extent active, we could deadlock waiting for + * the page writeback to clear but it won't because the extent + * is active and won't be written out. */ GOTO(out, rc = -EAGAIN); default: break;