Re: [Cluster-devel] [PATCH] gfs2: Don't withdraw under a spin lock

2018-06-14 Thread Andreas Gruenbacher
On 13 June 2018 at 18:32, Andrew Price wrote: > On 07/06/18 12:09, Andreas Gruenbacher wrote: >> >> In two places, the gfs2_io_error_bh macro is called while holding the >> sd_ail_lock spin lock. This isn't allowed because gfs2_io_error_bh >> withdraws the filesystem, which can sleep because it i

Re: [Cluster-devel] iomap preparations for GFS2 v2

2018-06-14 Thread Andreas Gruenbacher
On 14 June 2018 at 14:04, Christoph Hellwig wrote: > Hi all, > > this is a slight rework of the patches from Andreas to prepare for gfs2 > using the iomap code. > > Note: I'd like to start with an immutable branch for iomap patches in either > the XFS tree or a tree of mine at the beginning of the

[Cluster-devel] [PATCH 6/6] iomap: add a page_done callback

2018-06-14 Thread Christoph Hellwig
This will be used by gfs2 to attach data to transactions for the journaled data mode. But the concept is generic enough that we might be able to use it for other purposes like encryption/integrity post-processing in the future. Based on a patch from Andreas Gruenbacher. Signed-off-by: Christoph

[Cluster-devel] [PATCH 4/6] iomap: complete partial direct I/O writes synchronously

2018-06-14 Thread Christoph Hellwig
From: Andreas Gruenbacher According to xfstest generic/240, applications seem to expect direct I/O writes to either complete as a whole or to fail; short direct I/O writes are apparently not appreciated. This means that when only part of an asynchronous direct I/O write succeeds, we can either f

[Cluster-devel] [PATCH 3/6] iomap: mark newly allocated buffer heads as new

2018-06-14 Thread Christoph Hellwig
From: Andreas Gruenbacher In iomap_to_bh, not only mark buffer heads in IOMAP_UNWRITTEN maps as new, but also buffer heads in IOMAP_MAPPED maps with the IOMAP_F_NEW flag set. This will be used by filesystems like gfs2, which allocate blocks in iomap->begin. Minor corrections to the comment for

[Cluster-devel] iomap preparations for GFS2 v2

2018-06-14 Thread Christoph Hellwig
Hi all, this is a slight rework of the patches from Andreas to prepare for gfs2 using the iomap code. Note: I'd like to start with an immutable branch for iomap patches in either the XFS tree or a tree of mine at the beginning of the merge window so that we have a common base for the GFS2 and XFS

[Cluster-devel] [PATCH 2/6] iomap: move bdev and dax_dev in a union

2018-06-14 Thread Christoph Hellwig
We always either ask for a block device or DAX device mapping, so we can use the same space for both. Signed-off-by: Christoph Hellwig --- fs/ext2/inode.c | 6 -- fs/ext4/inode.c | 6 -- fs/xfs/xfs_iomap.c| 6 -- include/linux/iomap.h | 6 -- 4 files changed, 16 i

[Cluster-devel] [PATCH 5/6] iomap: generic inline data handling

2018-06-14 Thread Christoph Hellwig
From: Andreas Gruenbacher Add generic inline data handling by adding a pointer to the inline data region to struct iomap. When handling a buffered IOMAP_INLINE write, iomap_write_begin will copy the current inline data from the inline data region into the page cache, and iomap_write_end will cop

[Cluster-devel] [PATCH 1/6] fs: factor out a __generic_write_end helper

2018-06-14 Thread Christoph Hellwig
Bits of the buffer.c based write_end implementations that don't know about buffer_heads and can be reused by other implementations. Signed-off-by: Christoph Hellwig Reviewed-by: Brian Foster Reviewed-by: Andreas Gruenbacher Reviewed-by: Darrick J. Wong --- fs/buffer.c | 67 +

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

2018-06-14 Thread Steven Whitehouse
Hi, Yes, that seems like a good plan Acked-by: Steven Whitehouse Steve. On 13/06/18 14:58, Bob Peterson wrote: Hi, Before this patch, block reservations kept track of the inode number. At one point, that was a valid thing to do. However, since we made the reservation a part of the inode (r