[Cluster-devel] [PATCH 1/3] lockref: Add lockref_put_not_zero

2018-04-12 Thread Bob Peterson
From: Andreas Gruenbacher Put a lockref unless the lockref is dead or its count would become zero. This is the same as lockref_put_or_lock except that the lock is never left held. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- include/linux/lockref.h | 1 + lib/lockref.c

[Cluster-devel] [PATCH 2/3] gfs2: Stop using rhashtable_walk_peek

2018-04-12 Thread Bob Peterson
keeping track of the current glock in the seq file iterator functions instead. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 47 --- 1 file changed, 28 insertions(+), 19 deletions(-) diff --git a/fs/gfs2/glock.c b

[Cluster-devel] [PATCH 1/3] lockref: Add lockref_put_not_zero

2018-04-12 Thread Bob Peterson
From: Andreas Gruenbacher Put a lockref unless the lockref is dead or its count would become zero. This is the same as lockref_put_or_lock except that the lock is never left held. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- include/linux/lockref.h | 1 + lib/lockref.c

[Cluster-devel] [PATCH 3/3] GFS2: Minor improvements to comments and documentation

2018-04-12 Thread Bob Peterson
This patch simply fixes some comments and the gfs2-glocks.txt file: Places where i_rwsem was called i_mutex, and adding i_rw_mutex. Signed-off-by: Bob Peterson --- Documentation/filesystems/gfs2-glocks.txt | 5 +++-- fs/gfs2/bmap.c| 2 +- fs/gfs2/ops_fstype.c

[Cluster-devel] [PATCH 0/3] GFS2: Second pre-pull patch posting (merge window)

2018-04-12 Thread Bob Peterson
a problem whereby lock dumps could miss glocks. 3. I made a minor patch to update some comments and fix the lock ordering text in our gfs2-glocks.txt Documentation file. Regards, Bob Peterson --- Andreas Gruenbacher (2): lockref: Add lockref_put_not_zero gfs2: Stop using rhashtable_walk

[Cluster-devel] [PATCH 2/3] gfs2: Stop using rhashtable_walk_peek

2018-04-12 Thread Bob Peterson
keeping track of the current glock in the seq file iterator functions instead. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 47 --- 1 file changed, 28 insertions(+), 19 deletions(-) diff --git a/fs/gfs2/glock.c b

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

2018-04-12 Thread Bob Peterson
Hi Linus, Please consider pulling the following additional 3 patches for the GFS2 file system. Regards, Bob Peterson The following changes since commit e241e3f2bf975788a1b70dff2eb5180ca395b28e: Merge tag 'for_linus

Re: [Cluster-devel] [PATCH] gfs2: Remove sdp->sd_jheightsize

2018-04-13 Thread Bob Peterson
ash table size from 2048 pointers to 4096 pointers, the table needs to go from 16K to 32K bytes. Thus, the height needs to go from 1 to 2, whereas if the same thing was done to a file, the 16K would still fit inside a dinode of height 1. Right? Bob Peterson Red Hat File Systems

[Cluster-devel] GFS2: Patches pulled, linux-gfs2.git for-next rebased (again)

2018-04-13 Thread Bob Peterson
Hi, Linus has pulled the latest set of patches from the for-next branch of the linux-gfs2.git tree, so I rebased the tree from Linus's master. So the current tree is back to having no unmerged GFS2 patches. Regards, Bob Peterson Red Hat File Systems

[Cluster-devel] [PATCH 0/3] GFS2: Second pre-pull patch posting (merge window)

2018-04-15 Thread Bob Peterson
a problem whereby lock dumps could miss glocks. 3. I made a minor patch to update some comments and fix the lock ordering text in our gfs2-glocks.txt Documentation file. Regards, Bob Peterson --- Andreas Gruenbacher (2): lockref: Add lockref_put_not_zero gfs2: Stop using rhashtable_walk

[Cluster-devel] [PATCH 3/3] GFS2: Minor improvements to comments and documentation

2018-04-15 Thread Bob Peterson
This patch simply fixes some comments and the gfs2-glocks.txt file: Places where i_rwsem was called i_mutex, and adding i_rw_mutex. Signed-off-by: Bob Peterson --- Documentation/filesystems/gfs2-glocks.txt | 5 +++-- fs/gfs2/bmap.c| 2 +- fs/gfs2/ops_fstype.c

Re: [Cluster-devel] [PATCH] gfs2: Remove sdp->sd_jheightsize

2018-04-16 Thread Bob Peterson
ch of the linux-gfs2 tree: https://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2.git/commit/fs/gfs2?h=for-next&id=9a38662ba4e2682f3f3e9f3ce02a243b837aa8c6 Regards, Bob Peterson Red Hat File Systems

Re: [Cluster-devel] [PATCH] fs: gfs2: Adding new return type vm_fault_t

2018-04-16 Thread Bob Peterson
systems that need similar patches. Shouldn't you do one big patch set that fixes several file systems at once and run it through Viro's kernel or Linus's kernel or something? Adding Viro and linux-fsdevel for more opinions. Regards, Bob Peterson

Re: [Cluster-devel] [PATCH] mkfs.gfs2: Zero blocks in alignment gaps

2018-04-17 Thread Bob Peterson
> --- Looks good to me. ACK. Regards, Bob Peterson

[Cluster-devel] [GFS2 PATCH 1/2] GFS2: Introduce EXSH (exclusively shared on one node)

2018-04-18 Thread Bob Peterson
rgrp sharing. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 12 +++- fs/gfs2/glock.h | 16 fs/gfs2/incore.h | 8 fs/gfs2/lock_dlm.c | 5 - fs/gfs2/trace_gfs2.h | 2 ++ 5 files changed, 33 insertions(+), 10 deletions(-) diff --git a/fs

[Cluster-devel] [GFS2 PATCH v1 0/2] Improve throughput through rgrp sharing

2018-04-18 Thread Bob Peterson
er we can go without separating them to their own rgrps. The statistics indicate this is well worth pursuing. --- Bob Peterson (2): GFS2: Introduce EXSH (exclusively shared on one node) GFS2: Take advantage of new EXSH glock mode for rgrps fs/gfs2/bmap.c | 2 +- fs/gfs2/dir.c|

[Cluster-devel] [GFS2 PATCH 2/2] GFS2: Take advantage of new EXSH glock mode for rgrps

2018-04-18 Thread Bob Peterson
This patch switches rgrp locking to EXSH mode so that it's only taken when the rgrp is added to an active transaction, or when blocks are being reserved. As soon as the transaction is ended, the rgrp exclusivity is released. This allows for rgrp sharing. Signed-off-by: Bob Peterson --- fs

Re: [Cluster-devel] [GFS2 PATCH 1/2] GFS2: Introduce EXSH (exclusively shared on one node)

2018-04-18 Thread Bob Peterson
- Original Message - > Hi, > > > On 18/04/18 17:58, Bob Peterson wrote: > > This patch is a first step in rgrp sharing. It allows for a new > > type of glock mode called EXSH, which stands for a lock that is > > Exclusive to one node, but shared amongst proc

Re: [Cluster-devel] [GFS2 PATCH 2/2] GFS2: Take advantage of new EXSH glock mode for rgrps

2018-04-18 Thread Bob Peterson
- Original Message - > Hi, > > > On 18/04/18 17:58, Bob Peterson wrote: > > This patch switches rgrp locking to EXSH mode so that it's only > > taken when the rgrp is added to an active transaction, or when > > blocks are being reserved. As soon as the

[Cluster-devel] [PATCH 0/2] Improve throughput through rgrp sharing (v2)

2018-05-08 Thread Bob Peterson
lag. The second patch puts it into use for rgrp sharing. Exclusive access to the rgrp is implemented through an rwsem. Performance testing using iozone looks even better than version 1. --- Bob Peterson (2): GFS2: Introduce GLF_EX_SHARING bit: local EX sharing GFS2: Take advantage of new EXSH

[Cluster-devel] [PATCH 1/2] GFS2: Introduce GLF_EX_SHARING bit: local EX sharing

2018-05-08 Thread Bob Peterson
lock. For now, there are no users of the new flag. A future patch will use it to improve performance with rgrp sharing. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 23 +++ fs/gfs2/glock.h | 4 2 files changed, 23 insertions(+), 4 deletions(-) diff --git a/fs

[Cluster-devel] [PATCH 2/2] GFS2: Take advantage of new EXSH glock mode for rgrps

2018-05-08 Thread Bob Peterson
This patch switches rgrp locking to EXSH mode so that it's only taken when the rgrp is added to an active transaction, or when blocks are being reserved. As soon as the transaction is ended, the rgrp exclusivity is released. This allows for rgrp sharing. Signed-off-by: Bob Peterson --- fs

[Cluster-devel] [GFS2 PATCH] GFS2: Add to tail, not head, of transaction

2018-05-09 Thread Bob Peterson
are artificially inflated because I was also running with Andreas Gruenbacher's iomap-write patch set plus my rgrp sharing patch set in both these cases. Still, it shows a 9 percent performance boost for both children and parent throughput. Signed-off-by: Bob Peterson --- fs/gfs2/trans.

[Cluster-devel] [GFS2 PATCH 0/2] GFS2: Bulk submit ordered writes

2018-05-14 Thread Bob Peterson
function gfs2_ordered_wait. The second patch implements the actual change. Bob Peterson (2): GFS2: Move function gfs2_ordered_wait before ordered_write GFS2: Submit all ordered writes in bulk, wait after that fs/gfs2/log.c | 48 +++- 1 file ch

[Cluster-devel] [GFS2 PATCH 1/2] GFS2: Move function gfs2_ordered_wait before ordered_write

2018-05-14 Thread Bob Peterson
Although it may not be obvious from the patch contents, this patch simply moves function gfs2_ordered_wait before its sister function, gfs2_ordered_write. There are no changes to the code. This was done to make a follow-on patch more clear and easy to read. Signed-off-by: Bob Peterson --- fs

[Cluster-devel] [GFS2 PATCH 2/2] GFS2: Submit all ordered writes in bulk, wait after that

2018-05-14 Thread Bob Peterson
Before this patch, the ordered_write function would submit all the ordered writes with filemap_fdatawrite, which waited for each one to complete before moving on to the next. This patch allows it to submit them all, then wait for them after they're submitted. Signed-off-by: Bob Peterson --

[Cluster-devel] [GFS2 PATCH 0/2] Improve throughput through rgrp sharing (v3)

2018-05-15 Thread Bob Peterson
roved sharing of the block allocator. Bob Peterson (2): GFS2: Introduce LM_FLAG_NODE_EX holder bit: Node Exclusive sharing GFS2: Introduce rgrp sharing fs/gfs2/bmap.c | 2 +- fs/gfs2/dir.c| 2 +- fs/gfs2/glock.c | 23 ++--- fs/gfs2/glock.h | 6 fs/gfs2/incore.h | 2 +

[Cluster-devel] [GFS2 PATCH 1/2] GFS2: Introduce LM_FLAG_NODE_EX holder bit: Node Exclusive sharing

2018-05-15 Thread Bob Peterson
"Even though I've locked the glock in EX, this process will share the lock and allow multiple holders for other local processes that use the same flag." For now, there are no users of the new flag. A future patch will use it to improve performance with rgrp sharing. Signed-off-by: B

[Cluster-devel] [GFS2 PATCH 2/2] GFS2: Introduce rgrp sharing

2018-05-15 Thread Bob Peterson
) which is another performance boost for the block allocator. Signed-off-by: Bob Peterson --- fs/gfs2/bmap.c | 2 +- fs/gfs2/dir.c| 2 +- fs/gfs2/incore.h | 2 ++ fs/gfs2/inode.c | 7 ++-- fs/gfs2/rgrp.c | 86 fs/gfs2/rgrp.h | 2 +- fs

[Cluster-devel] [RHEL6.10 PATCH] GFS2: allow gfs2_write_calc_reserv to use minimum values for rindex

2018-05-30 Thread Bob Peterson
number of blocks we need to allocate. Signed-off-by: Bob Peterson --- fs/gfs2/bmap.c | 2 +- fs/gfs2/bmap.h | 13 + 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c index 2d2b14371b72..9e6d6775fbf7 100644 --- a/fs/gfs2/bmap.c +++ b/fs/g

Re: [Cluster-devel] [RHEL6.10 PATCH] GFS2: allow gfs2_write_calc_reserv to use minimum values for rindex

2018-05-30 Thread Bob Peterson
Hi, Please ignore the last email. I sent it to the wrong list. This is a rhel6 patch, not meant for the development kernel tree. Bob Peterson - Original Message - > Hi, > > QE found problems with the previous patch for bug #1384184. > This replacement patch reverts the fir

Re: [Cluster-devel] [PATCH v5 00/14] gfs2 iomap write support

2018-05-30 Thread Bob Peterson
omap-write set. Do you see any reason why we can't treat them as separate patches? Regards, Bob Peterson Red Hat File Systems

[Cluster-devel] [GFS2 PATCH] GFS2: Fix allocation error bug with recursive rgrp glocking

2018-05-30 Thread Bob Peterson
lock prior to the call to gfs2_trim_blocks, thus preventing the glock recursion. Signed-off-by: Bob Peterson --- fs/gfs2/aops.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/fs/gfs2/aops.c b/fs/gfs2/aops.c index f58716567972..629e614b324c 100644 --- a/fs/gfs2/aops.c +++

[Cluster-devel] [GFS2 PATCH] GFS2: rgrp free blocks used incorrectly

2018-05-30 Thread Bob Peterson
elves reserved (because obviously we need to allocate them). Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 33 + 1 file changed, 29 insertions(+), 4 deletions(-) diff --git a/fs/gfs2/rgrp.c b/fs/gfs2/rgrp.c index 8b683917a27e..8be47b81011a 100644 --- a/fs/gfs2/r

[Cluster-devel] [GFS2 PATCH] gfs2: revert af21ca8ed50f01c5278c5ded6dad6f05e8a5d2e4

2018-05-30 Thread Bob Peterson
ify a directory when we should be able to. This patch reverts the patch. Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 9 ++--- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/fs/gfs2/rgrp.c b/fs/gfs2/rgrp.c index 8be47b81011a..d7a8ed8bb30c 100644 --- a/fs/gfs2/rgrp.c +++ b/fs

[Cluster-devel] [GFS2 PATCH] GFS2: Add to tail, not head, of transaction

2018-05-30 Thread Bob Peterson
are artificially inflated because I was also running with Andreas Gruenbacher's iomap-write patch set plus my rgrp sharing patch set in both these cases. Still, it shows a 9 percent performance boost for both children and parent throughput. Signed-off-by: Bob Peterson --- fs/gfs2/trans.

Re: [Cluster-devel] [GFS2 PATCH] GFS2: Fix allocation error bug with recursive rgrp glocking

2018-05-31 Thread Bob Peterson
- Original Message - > Bob, > > On 30 May 2018 at 21:14, Bob Peterson wrote: > > Before this patch function gfs2_write_begin, upon discovering an > > error, called gfs2_trim_blocks while the rgrp glock was still held. > > That's because gfs2_inplace_r

[Cluster-devel] [GFS2 PATCH] GFS2: gfs2_free_extlen can return an extent that is too long

2018-06-01 Thread Bob Peterson
e bitmap. This patch fixes the calculation so it won't exceed the last bitmap. It also adds a BUG_ON to guard against overflows in the future. Signed-off-by: Bob Peterson --- fs/gfs2/incore.h | 1 + fs/gfs2/rgrp.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/gfs2/

[Cluster-devel] [PATCH] MAINTAINERS: Add Andreas Gruenbacher as a maintainer for gfs2

2018-06-04 Thread Bob Peterson
Add Andreas Gruenbacher as a maintainer for the gfs2 file system Signed-off-by: Bob Peterson --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index b60179d948bb..f369e975c821 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -5941,6 +5941,7 @@ F

[Cluster-devel] [PATCH v2] MAINTAINERS: Add Andreas Gruenbacher as a maintainer for gfs2

2018-06-04 Thread Bob Peterson
Add Andreas Gruenbacher as a maintainer for the gfs2 file system and remove Steve Whitehouse. Signed-off-by: Bob Peterson --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index b60179d948bb..73745884a595 100644 --- a/MAINTAINERS +++ b

Re: [Cluster-devel] [PATCH 0/5] gfs2: Various minor cleanups

2018-06-04 Thread Bob Peterson
17.0 > > Hi, Thanks. This patch set is now pushed to the for-next branch of the linux-gfs2 tree. Regards, Bob Peterson Red Hat File Systems

[Cluster-devel] [PATCH 4/9] GFS2: gfs2_free_extlen can return an extent that is too long

2018-06-04 Thread Bob Peterson
p. This patch fixes the calculation so it won't exceed the last bitmap. It also adds a BUG_ON to guard against overflows in the future. Signed-off-by: Bob Peterson --- fs/gfs2/incore.h | 1 + fs/gfs2/rgrp.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/gfs2/incor

[Cluster-devel] [PATCH 1/9] gfs2: Remove sdp->sd_jheightsize

2018-06-04 Thread Bob Peterson
eparately for both files and directories, anyway. Remove the unncessary sdp->sd_jheightsize array. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/bmap.c | 14 +- fs/gfs2/incore.h | 2 -- fs/gfs2/ops_fstype.c | 19 --- 3 fi

[Cluster-devel] [PATCH 7/9] gfs2: Remove ordered write mode handling from gfs2_trans_add_data

2018-06-04 Thread Bob Peterson
inefficient for small block sizes as well. Handle both cases separately instead. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/aops.c | 7 --- fs/gfs2/bmap.c | 12 fs/gfs2/log.h | 7 ++- fs/gfs2/quota.c | 5 - fs/gfs2/trans.c | 27

[Cluster-devel] [PATCH 5/9] gfs2: hole_size improvement

2018-06-04 Thread Bob Peterson
returns the entire hole at once (provided that the caller is interested in the total size). Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/bmap.c | 210 +++-- 1 file changed, 153 insertions(+), 57 deletions(-) diff --git a/fs

[Cluster-devel] [PATCH 9/9] MAINTAINERS: Add Andreas Gruenbacher as a maintainer for gfs2

2018-06-04 Thread Bob Peterson
Add Andreas Gruenbacher as a maintainer for the gfs2 file system and remove Steve Whitehouse. Signed-off-by: Bob Peterson --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index b60179d948bb..73745884a595 100644 --- a/MAINTAINERS +++ b

[Cluster-devel] [PATCH 6/9] gfs2: gfs2_stuffed_write_end cleanup

2018-06-04 Thread Bob Peterson
Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/aops.c | 49 ++--- 1 file changed, 18 insertions(+), 31 deletions(-) diff --git a/fs/gfs2/aops.c b/fs/gfs2/aops.c index 66e7172e0134..69f25e3c97ce 100644 --- a/fs/gfs2/aops.c +++ b/fs/gfs2/aops.c @@ -817,7

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

2018-06-04 Thread Bob Peterson
code to pave the way for iomap writes, which is a future patch set. 8. I fixed a bug where block reservations can run off the end of a bitmap. 9. I added Andreas to the MAINTAINERS file. Regards, Bob Peterson --- Andreas Gruenbacher (7): gfs2: Remove sdp->sd_jheightsize gfs2: Update find_

[Cluster-devel] [PATCH 8/9] gfs2: Iomap cleanups and improvements

2018-06-04 Thread Bob Peterson
helper and use it in fallocate_chunk: gfs2_iomap_begin will become unsuitable for fallocate with proper iomap write support. In gfs2_block_map and fallocate_chunk, zero-initialize struct iomap. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/bmap.c | 205

[Cluster-devel] [PATCH 2/9] gfs2: Update find_metapath comment

2018-06-04 Thread Bob Peterson
From: Andreas Gruenbacher Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/bmap.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c index 0590e93494f7..fcf2f7d166de 100644 --- a/fs/gfs2/bmap.c +++ b/fs/gfs2

[Cluster-devel] [PATCH 3/9] GFS2: Fix allocation error bug with recursive rgrp glocking

2018-06-04 Thread Bob Peterson
alled to release the lock prior to the call to gfs2_trim_blocks, thus preventing the glock recursion. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- fs/gfs2/aops.c | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/fs/gfs2/aops.c b/fs/gfs2/aops.c

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

2018-06-04 Thread Bob Peterson
Hi Linus, Please consider pulling the following changes for the GFS2 file system. Note that I'm on holiday the rest of this week, but I added Andreas Gruenbacher to the MAINTAINERS file, so he can react if there are problems that can't wait until I'm back on 11 June. Regards

[Cluster-devel] GFS2: Patches pulled, linux-gfs2.git for-next rebased

2018-06-11 Thread Bob Peterson
Hi, Linus has pulled the latest set of patches from the for-next branch of the linux-gfs2.git tree, so I rebased the tree from Linus's master. So the current tree is back to having no unmerged GFS2 patches. Regards, Bob Peterson Red Hat File Systems

[Cluster-devel] [GFS2 PATCH] gfs2: eliminate rs_inum and reduce the size of gfs2 inodes

2018-06-13 Thread Bob Peterson
container_of. This saves us a little memory in our inode. Signed-off-by: Bob Peterson --- fs/gfs2/incore.h | 1 - fs/gfs2/rgrp.c | 5 +++-- fs/gfs2/trace_gfs2.h | 3 ++- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/fs/gfs2/incore.h b/fs/gfs2/incore.h index d2ad817e089f

[Cluster-devel] [GFS2 PATCH] GFS2: dirty inode correctly in gfs2_write_end for jdata

2018-06-18 Thread Bob Peterson
The check was never done for jdata files, so the inode was never properly marked dirty. This patch adds the additional check so that jdata files are also marked dirty. Signed-off-by: Bob Peterson --- fs/gfs2/aops.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/gfs2/a

[Cluster-devel] [GFS2 PATCH v2] GFS2: Submit all ordered writes in bulk, wait after that

2018-06-18 Thread Bob Peterson
, then wait for them after they're submitted. It also implements Andreas's suggestion to call the filemap functions directly rather than a more complicated ordered_wait. It also does the sorting outside the spin_lock. Signed-off-by: Bob Peterson --- fs/gfs2/log.c | 27 +++-

[Cluster-devel] [GFS2 PATCH] gfs2: use reservation rgd, not inode rgd for allocating blocks

2018-06-18 Thread Bob Peterson
d. If we don't, the gfs2_rbm_eq function may not determine that the rgd for allocations is the same as the reservation, and therefore, the reservation won't be properly adjusted. Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) di

[Cluster-devel] [GFS2 PATCH] gfs2: Don't reject a supposedly full bitmap if we have blocks reserved

2018-06-18 Thread Bob Peterson
igned-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/gfs2/rgrp.c b/fs/gfs2/rgrp.c index 5f695b8de30c..ddc8a1a728b1 100644 --- a/fs/gfs2/rgrp.c +++ b/fs/gfs2/rgrp.c @@ -1712,8 +1712,8 @@ static int gfs2_rbm_find(struct gfs2_rbm *rb

[Cluster-devel] [GFS2 v2 PATCH v2] GFS2: rgrp free blocks used incorrectly

2018-06-21 Thread Bob Peterson
osed to blocks that are still being used because an unlinked file is still open) minus the number of blocks reserved by processes, but not counting the blocks we ourselves reserved (because obviously we need to allocate them). Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 33 +

[Cluster-devel] [GFS2 PATCH v2] gfs2: Don't reject a supposedly full bitmap if we have blocks reserved

2018-06-21 Thread Bob Peterson
ck to allow processes to use their own reservations. Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/gfs2/rgrp.c b/fs/gfs2/rgrp.c index 9611b45b41a1..836e8f2ce3d4 100644 --- a/fs/gfs2/rgrp.c +++ b/fs/gfs2/rgrp.c @@ -1712,7 +1

Re: [Cluster-devel] [PATCH] gfs2: call ktime_get_coarse_real_ts64() directly

2018-06-21 Thread Bob Peterson
nux-gfs2 tree: https://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2.git/commit/fs/gfs2?h=for-next&id=ee9c7f9ae3d4fb9fb5c9cacbe3880d5dd66feb16 Regards, Bob Peterson Red Hat File Systems

[Cluster-devel] [GFS2 PATCH] GFS2: Skip taking journal recovery locks for spectators

2018-06-21 Thread Bob Peterson
secondary mounter who is really the first rw mounter, to do journal recovery: since the spectator doesn't acquire those locks, it can grab them in EX mode, and therefore consider itself to be the first mounter. Signed-off-by: Bob Peterson --- fs/gfs2/lock_dlm.c | 2 ++ 1 file changed, 2 inser

Re: [Cluster-devel] [GFS2 PATCH] GFS2: Skip taking journal recovery locks for spectators

2018-06-24 Thread Bob Peterson
- Original Message - > Bob, > > On 22 June 2018 at 00:05, Bob Peterson wrote: > > Hi, > > > > Before this patch, spectator mounts would try to acquire the dlm's > > control lock and mounted lock as part of its normal recovery sequence. > > It&#

Re: [Cluster-devel] A list of kernel panic bugs in gfs2 linux 4.18 kernel module found by fuzzing

2018-06-29 Thread Bob Peterson
3, 200259 and 200247 may have the same root cause, but I am > not sure. > I would like to provide any further help to debug and fix the bugs. I am also > willing to test the patch. > > Thanks, > Wen Hi, Thanks, Wen. Andy Price is doing most of the work on gfs2-utils and fsck.gfs2 these days. Adding him. Regards, Bob Peterson Red Hat File Systems

Re: [Cluster-devel] [PATCH v10 0/5] gfs2 iomap write support

2018-06-29 Thread Bob Peterson
- Original Message - > Here's another update of my gfs2 iomap write patches on top of: > > git://git.infradead.org/users/hch/xfs.git gfs2-iomap Hi Andreas, I've reviewed your patches and they look good to me. Go ahead and add my: Signed-off-by: Bob Peterson Bob Peterson

[Cluster-devel] [GFS2 PATCH] GFS2: Eliminate bitmap clones

2018-07-02 Thread Bob Peterson
Hi, Do we really still need "clone bitmaps" in gfs2? If so, why? I think maybe we can get rid of them. Can someone (Steve Whitehouse perhaps?) think of a scenario in which they're still needed? If so, please elaborate and give an example. Regards, Bob Peterson --- Before this p

Re: [Cluster-devel] [GFS2 PATCH] GFS2: Eliminate bitmap clones

2018-07-03 Thread Bob Peterson
Hi Steve, - Original Message - > > Do we really still need "clone bitmaps" in gfs2? If so, why? > > I think maybe we can get rid of them. Can someone (Steve Whitehouse > > perhaps?) think of a scenario in which they're still needed? If so, > > please elaborate and give an example. (snip) >

[Cluster-devel] [GFS2 PATCH v2] GFS2: dirty inode correctly in gfs2_iomap_end for jdata

2018-07-03 Thread Bob Peterson
done for ordered data files. The check was never done for jdata files, so the inode was never properly marked dirty. The affected code has since been moved to function gfs2_iomap_end. This patch adds the additional check so that jdata files are also marked dirty. Signed-off-by: Bob Peterson --- fs

Re: [Cluster-devel] [GFS2 PATCH] GFS2: Eliminate redundant ip->i_rgd in favor of ip->i_res.rs_rgd

2018-07-05 Thread Bob Peterson
- Original Message - > On 30 June 2017 at 18:40, Bob Peterson wrote: > > Hi, > > > > Before this patch, GFS2 remembered the last rgrp it used by way of > > a variable i_rgd. However, block allocations are made by way of a > > reservations structure,

[Cluster-devel] [GFS2 PATCH v2] gfs2: Fix recovery issues for spectators

2018-07-06 Thread Bob Peterson
Hi, This is a new version 2 of the patch I posted on 24 June 2018 titled: GFS2: Skip taking journal recovery locks for spectators. I've fixed and tested the corner cases Andreas was worried about. Regards, Bob Peterson --- This patch fixes a couple problems dealing with spectators who r

Re: [Cluster-devel] [PATCH 0/3] gfs2: More iomap enablement

2018-07-09 Thread Bob Peterson
Reviewed-by. Bob Peterson

[Cluster-devel] [GFS2 PATCH 11/12] GFS2: Add new GL_ST_UNLOCK state to reduce calls to the __ version

2018-07-09 Thread Bob Peterson
Before this patch, the truncate code called __state_machine but only did the unlock of GLF_UNLOCK. This patch adds a new state GL_ST_UNLOCK does the same thing, thus allowing it to call the regular state_machine function. This reduces the calls to the helper. Signed-off-by: Bob Peterson --- fs

[Cluster-devel] [GFS2 PATCH 09/12] GFS2: Reduce redundancy in GL_ST_DEMOTE_NONBLOCK state

2018-07-09 Thread Bob Peterson
This patch just simplifies the path through the GL_ST_DEMOTE_NONBLOCK state in the state machine. Regardless of whether a holder is found, it still needs to clear the GLF_LOCK bit. But we need to be careful to do it check for a holder before we release GLF_LOCK. Signed-off-by: Bob Peterson

[Cluster-devel] [GFS2 PATCH 02/12] GFS2: Eliminate a goto in finish_xmote

2018-07-09 Thread Bob Peterson
This is another baby step toward a better glock state machine. This patch eliminates a goto in function finish_xmote so we can begin unraveling the cryptic logic with later patches. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions

[Cluster-devel] [GFS2 PATCH 08/12] GFS2: Replace run_queue with new GL_ST_RUN state in state machine

2018-07-09 Thread Bob Peterson
Now we replace the run_queue function with a new state in the glock state machine which does the same thing. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 60 + fs/gfs2/glock.h | 1 + 2 files changed, 27 insertions(+), 34 deletions(-) diff

[Cluster-devel] [GFS2 PATCH 03/12] GFS2: Baby step toward a real state machine: finish_xmote

2018-07-09 Thread Bob Peterson
This patch adds a new function state_machine and some hooks to call it. For this early version, we've only got two states: idle and finish_xmote. Later, many more will be added. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 74 +++- fs

[Cluster-devel] [GFS2 PATCH 01/12] GFS2: Make do_xmote determine its own gh parameter

2018-07-09 Thread Bob Peterson
This is another baby step toward a better glock state machine. Before this patch, do_xmote was called with a gh parameter, but only for promotes, not demotes. This patch allows do_xmote to determine the gh autonomously. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 12 ++-- 1 file

[Cluster-devel] [GFS2 PATCH 12/12] GFS2: Optimization of GL_ST_UNLOCK state

2018-07-09 Thread Bob Peterson
unlock-then-lock and extra checks and skips directly to the resulting promotion/demotion state. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 6 ++ fs/gfs2/glock.h | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c index b7b8cf16d613

[Cluster-devel] [GFS2 PATCH 06/12] GFS2: Add blocking and non-blocking demote to state machine

2018-07-09 Thread Bob Peterson
: Bob Peterson --- fs/gfs2/glock.c | 44 +--- fs/gfs2/glock.h | 2 ++ 2 files changed, 31 insertions(+), 15 deletions(-) diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c index 47b023ed8f51..344ef774f68f 100644 --- a/fs/gfs2/glock.c +++ b/fs/gfs2/glock.c

[Cluster-devel] [GFS2 PATCH 07/12] GFS2: Add a new GL_ST_PROMOTE state to glock state machine

2018-07-09 Thread Bob Peterson
Before this patch, function run_queue did a bunch of logic when glocks are being promoted. This patch moves the logic to the glock state machine and simplifies run_queue further. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 46 +++--- fs/gfs2/glock.h

[Cluster-devel] [GFS2 PATCH 05/12] GFS2: Make do_xmote not call the state machine again

2018-07-09 Thread Bob Peterson
Before this patch, the state machine could call do_xmote which, in turn, could call back into the state machine. This patch unravels the logic so instead it sends back an -EAGAIN return code, which signals the state machine to loop under the new state. Signed-off-by: Bob Peterson --- fs/gfs2

[Cluster-devel] [GFS2 PATCH 04/12] GFS2: Add do_xmote states to state machine

2018-07-09 Thread Bob Peterson
This patch adds two new states to the glock state machine. The first is a normal call for gl_target. The second is an abnormal call for cases in which dlm was unable to grant our request. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 37 - fs/gfs2/glock.h

[Cluster-devel] [GFS2 PATCH 00/12] Radical Reform of glock state machine

2018-07-09 Thread Bob Peterson
hine from within the process context. For example, there are only a few cases in which we need to ensure a glock demote happen later (minimum hold time). --- Bob Peterson (12): GFS2: Make do_xmote determine its own gh parameter GFS2: Eliminate a goto in finish_xmote GFS2: Baby step toward

[Cluster-devel] [GFS2 PATCH 10/12] GFS2: Reduce glock_work_func to a single call to state_machine

2018-07-09 Thread Bob Peterson
state machine. The goal here is to allow for patches in the future that will bypass the delayed workqueue altogether to improve performance. Signed-off-by: Bob Peterson --- fs/gfs2/glock.c | 97 - fs/gfs2/glock.h | 1 + 2 files changed, 56

[Cluster-devel] [PATCH] gfs2: Fix gfs2_testbit to use clone bitmaps

2018-07-10 Thread Bob Peterson
nt of free blocks. Before this patch, it wasn't using the clone bitmap, which means soon-to-be-freed blocks will be treated as free blocks for the purposes of an extent, and that's clearly wrong. Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 4 +++- 1 file changed, 3 insertions(+),

[Cluster-devel] [PATCH v2] gfs2: Fix gfs2_testbit to use clone bitmaps

2018-07-13 Thread Bob Peterson
favor of calling it directly from its only caller, gfs2_check_blk_type. This simplifies the code. Bob Peterson --- Function gfs2_testbit is called in three places. Two of those places, gfs2_alloc_extent and gfs2_unaligned_extlen, should be using the clone bitmaps, not the "real" bitmaps

[Cluster-devel] [GFS2 PATCH] gfs2: Return all reservations when rgrp_brelse is called

2018-07-13 Thread Bob Peterson
ne on another node may have reserved those blocks and even used them. This patch makes the function returns all the block reservations held for the rgrp whose buffer_heads are being released. Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/gfs2/rgr

Re: [Cluster-devel] [GFS2 PATCH] gfs2: Return all reservations when rgrp_brelse is called

2018-07-23 Thread Bob Peterson
h what RHEL6 and prior releases do by using "try" locks on rgrps. (Which is why simultaneous allocators often perform better on RHEL6 and older.) In my opinion, there's no advantage to using a hint when we can do actual accounting to keep track of spans of blocks too small to be considered for a reservation. Regards, Bob Peterson Red Hat File Systems

[Cluster-devel] Corrections to patch d1475c07f7 "GFS2: rgrp free blocks used incorrectly"

2018-07-24 Thread Bob Peterson
before. When those blocks are allocated, function gfs2_adjust_reservation should then remove the reservation from the rgrp tree and adjust its count of reserved blocks accordingly. Later, if we tighten the enforcement of block reservations, we should change it back into a BUG_ON. Regards, Bob Peterson Red Hat File Systems

Re: [Cluster-devel] [PATCH] gfs2: Special-case rindex for gfs2_grow

2018-07-25 Thread Bob Peterson
completely full filesystems. > > Signed-off-by: Andreas Gruenbacher Hi, ACK. Yeah, we need this. Bob Peterson

Re: [Cluster-devel] [PATCH v2] gfs2: Fix gfs2_testbit to use clone bitmaps

2018-07-26 Thread Bob Peterson
- Original Message - > Bob, > > On 13 July 2018 at 22:19, Bob Peterson wrote: > > Hi, > > > > The previous version of my patch had a bug. Apparently function > > gfs2_check_blk_type does need to check the non-clone bitmap. The other > > two cal

[Cluster-devel] [GFS2 PATCH] gfs2: cleanup: call gfs2_rgrp_ondisk2lvb from gfs2_rgrp_out

2018-07-26 Thread Bob Peterson
Hi, Before this patch gfs2_rgrp_ondisk2lvb was called after every call to gfs2_rgrp_out. This patch just calls it directly from within gfs2_rgrp_out, and moves the function to be before it so we don't need a function prototype. Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c

Re: [Cluster-devel] [PATCH 1/3] gfs2: Don't depend on mp_aheight in clone_metapath

2018-07-30 Thread Bob Peterson
IGHT; hgt++) { > + if (mp->mp_bh[hgt] == NULL) > + break; > get_bh(clone->mp_bh[hgt]); > + } > } > > static void gfs2_metapath_ra(struct gfs2_glock *gl, __be64 *start, __be64 > *end) > -- > 2.17.1 > > Hi, Reviewed-by: Bob Peterson Bob Peterson

Re: [Cluster-devel] [PATCH 2/3] gfs2: Split gfs2_indirect_init

2018-07-30 Thread Bob Peterson
acher > --- Hi, Reviewed-by: Bob Peterson This looks right. It took me a while to convince myself though. :) Regards, Bob Peterson

Re: [Cluster-devel] [PATCH] gfs2: Get rid of gfs2_ea_strlen

2018-08-03 Thread Bob Peterson
Reviewed-by: Bob Peterson Bob Peterson

[Cluster-devel] [GFS2 PATCH v3] gfs2: Fix gfs2_testbit to use clone bitmaps

2018-08-03 Thread Bob Peterson
Hi, I sent a previous version of this patch earlier, but Andreas asked me to add some comments to the code to explain the purpose of the clone bitmaps. This version adds an extensive new comment to incore.h. Bob Peterson --- In the gfs2 block allocator there's a concept of an in-core only &

Re: [Cluster-devel] [PATCH 3/3] gfs2: Don't create unnecessary indirect blocks

2018-08-05 Thread Bob Peterson
i = 1 + overlap; This patch is a little more cryptic. I'll have to look at it again when I'm fresh. Regards, Bob Peterson

[Cluster-devel] [GFS2 PATCH] gfs2: eliminate update_rgrp_lvb_unlinked

2018-08-08 Thread Bob Peterson
Hi, Function update_rgrp_lvb_unlinked used to do the same thing as be32_add_cpu. This patch removes it in favor of using be32_add_cpu directly. Signed-off-by: Bob Peterson --- fs/gfs2/rgrp.c | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/fs/gfs2/rgrp.c b/fs

[Cluster-devel] [GFS2 PATCH] GFS2: Simplify iterative add loop in foreach_descriptor

2018-08-08 Thread Bob Peterson
Hi, Before this patch, function foreach_descriptor repeatedly called function gfs2_replay_incr_blk which just incremented the value while decrementing another, and checked for wrap. This is a waste of time. This patch just adds the value and adjusts it if a wrap occurred. Signed-off-by: Bob

Re: [Cluster-devel] [GFS2 PATCH] GFS2: Simplify iterative add loop in foreach_descriptor

2018-08-09 Thread Bob Peterson
it does at the moment. Otherwise this can easily get > missed when someone looks at the code in future, and expects > gfs2_replay_incr_blk to be the only thing that changes the position > during recovery, > > Steve. Hi, Since we're so close to the merge window, I'll just remo

<    1   2   3   4   5   6   7   8   9   10   >