diff mbox

xfstests crash with trond/testing

Message ID 1439224487.5233.2.camel@primarydata.com (mailing list archive)
State New, archived
Headers show

Commit Message

Trond Myklebust Aug. 10, 2015, 4:34 p.m. UTC
On Mon, 2015-08-10 at 10:19 -0400, Trond Myklebust wrote:
> On Mon, Aug 10, 2015 at 8:08 AM, Christoph Hellwig <hch@lst.de> 
> wrote:
> > Correction:  This was a plain 4.1 mount, not using pnfs at all, it
> > reproduces every time I do a full xfstests run.
> 
> Thanks! I'll look into it.

The following patch should fix it. Do you mind if I just squash it in
to the existing one?

Cheers
  Trond

8<-------------------------------------------------------------------
From 0074e4c989509e1a7b814664b1c256ed920e4ccc Mon Sep 17 00:00:00 2001
From: Trond Myklebust <trond.myklebust@primarydata.com>
Date: Mon, 10 Aug 2015 12:25:56 -0400
Subject: [PATCH] fixup! NFSv4.1/pnfs: Fix atomicity of commit list updates

---
 fs/nfs/internal.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Christoph Hellwig Aug. 11, 2015, 12:44 p.m. UTC | #1
On Mon, Aug 10, 2015 at 12:34:47PM -0400, Trond Myklebust wrote:
> The following patch should fix it. Do you mind if I just squash it in
> to the existing one?

Fine with me.

--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/fs/nfs/internal.h b/fs/nfs/internal.h
index 9553e024fa7d..1dad18105ed0 100644
--- a/fs/nfs/internal.h
+++ b/fs/nfs/internal.h
@@ -628,9 +628,9 @@  void nfs_super_set_maxbytes(struct super_block *sb, __u64 maxfilesize)
 static inline
 void nfs_mark_page_unstable(struct page *page, struct nfs_commit_info *cinfo)
 {
-	struct inode *inode = page_file_mapping(page)->host;
-
 	if (!cinfo->dreq) {
+		struct inode *inode = page_file_mapping(page)->host;
+
 		inc_zone_page_state(page, NR_UNSTABLE_NFS);
 		inc_wb_stat(&inode_to_bdi(inode)->wb, WB_RECLAIMABLE);
 		__mark_inode_dirty(inode, I_DIRTY_DATASYNC);