[pnfs] [PATCH 1/8] nfs: fix race in nfs_dirty_request
Benny Halevy
bhalevy at panasas.com
Fri May 2 06:16:41 EDT 2008
Applied to the upstream branches
and forwarded to Trond.
Benny
On May. 01, 2008, 16:02 +0300, Fred Isaman <iisaman at citi.umich.edu> wrote:
> When called from nfs_flush_incompatible, the req is not locked, so
> req->wb_page might be set to NULL before it is used by PageWriteback.
>
> Signed-off-by: Fred Isaman <iisaman at citi.umich.edu>
> ---
> fs/nfs/write.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/fs/nfs/write.c b/fs/nfs/write.c
> index 015e035..656af5f 100644
> --- a/fs/nfs/write.c
> +++ b/fs/nfs/write.c
> @@ -434,7 +434,7 @@ nfs_dirty_request(struct nfs_page *req)
>
> if (page == NULL || test_bit(PG_NEED_COMMIT, &req->wb_flags))
> return 0;
> - return !PageWriteback(req->wb_page);
> + return !PageWriteback(page);
> }
>
> #if defined(CONFIG_NFS_V3) || defined(CONFIG_NFS_V4)
More information about the pNFS
mailing list