[Cluster-devel] GFS2 file system does not invalidate page cache after direct IO write

2017-05-03 Thread Gang He
Hello Guys, I found a interesting thing on GFS2 file system, After I did a direct IO write for a whole file, I still saw there were some page caches in this inode. It looks this GFS2 behavior does not follow file system POSIX semantics, I just want to know this problem belongs to a know issue

[Cluster-devel] [PATCH 2/2 linux-next] gfs2: remove unused flags parameter

2017-05-03 Thread Fabian Frederick
We already assumed rename flags when calling gfs2_exchange() Signed-off-by: Fabian Frederick --- fs/gfs2/inode.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c index 9698796..b5858a3 100644 --- a/fs/gfs2/inode.c +++

[Cluster-devel] GFS2: Pull request (merge window)

2017-05-03 Thread Bob Peterson
Hi Linus, Please consider pulling the following changes for the GFS2 file system. Special note: This time we had an unusual dependency on a patch (f9fe1c12) which went through David Miller's net-next tree, so we had a merge commit on our GFS2 for-next branch. After you pulled that patch, I

[Cluster-devel] [PATCH 5/9] GFS2: Temporarily zero i_no_addr when creating a dinode

2017-05-03 Thread Bob Peterson
Before this patch i_no_addr was not initialized until after the return from allocating its block. That meant the i_no_addr was temporarily uninitialized storage. Ordinarily that's not a concern, but if inplace_reserve can't find space, it can call try_rgrp_unlink which references i_no_addr as a

[Cluster-devel] [PATCH 3/9] gfs2: Deduplicate gfs2_{glocks, glstats}_open

2017-05-03 Thread Bob Peterson
From: Andreas Gruenbacher Both functions are identical except for the seq_operations used. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 26 +- 1 file changed, 9

[Cluster-devel] [PATCH 8/9] gfs2: Re-enable fallocate for the rindex

2017-05-03 Thread Bob Peterson
From: Andrew Price Commit 86066914edff2316cbed63aac8a87d5001441a16 "gfs2: Don't support fallocate on jdata files" removed the ability of gfs2_grow to reserve space at the end of the rindex, which could prevent a second gfs2_grow from succeeding if the fs is full. Allow

[Cluster-devel] [PATCH 4/9] gfs2: Don't pack struct lm_lockname

2017-05-03 Thread Bob Peterson
From: Andreas Gruenbacher As per a suggestion by Linus, don't pack struct lm_lockname: we did that because the struct is used as a rhashtable key, but packing tells the compiler that the 64-bit fields in the struct may be unaligned, causing it to generate worse code on some

[Cluster-devel] [PATCH 2/9] gfs2: Replace rhashtable_walk_init with rhashtable_walk_enter

2017-05-03 Thread Bob Peterson
From: Andreas Gruenbacher Function rhashtable_walk_init is deprecated. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[Cluster-devel] [PATCH 0/9] GFS2: Pre-pull patch posting (merge window)

2017-05-03 Thread Bob Peterson
Hi, We've got nine GFS2 patches for this merge window. 1. Andreas Gruenbacher wrote a patch to replace the deprecated call to rhashtable_walk_init with rhashtable_walk_enter. 2. Andreas also wrote a patch to eliminate redundant code in two of our debugfs sequence files. 3. Andreas also

[Cluster-devel] [PATCH 6/9] gfs2: Switch to rhashtable_lookup_get_insert_fast

2017-05-03 Thread Bob Peterson
From: Andreas Gruenbacher Switch from rhashtable_lookup_insert_fast + rhashtable_lookup_fast to rhashtable_lookup_get_insert_fast, which is cleaner and avoids an extra rhashtable lookup. At the same time, turn the retry loop in gfs2_glock_get into an infinite loop. The

[Cluster-devel] [PATCH 9/9] GFS2: Non-recursive delete

2017-05-03 Thread Bob Peterson
Implement truncate/delete as a non-recursive algorithm. The older algorithm was implemented with recursion to strip off each layer at a time (going by height, starting with the maximum height. This version tries to do the same thing but without recursion, and without needing to allocate new

[Cluster-devel] [PATCH 1/9] GFS2: Prevent BUG from occurring when normal Withdraws occur

2017-05-03 Thread Bob Peterson
When the GFS2 file system withdraws due to metadata corruption, it often has outstanding transactions in the journal and delayed work queued for its glocks. This patch adds some new checks for a withdrawn file system before proceeding with operations that would obviously cause a BUG() to be