Re: [dm-devel] [PATCH 0/6] Overhaul memalloc_no*

2020-06-25 Thread Darrick J. Wong
On Thu, Jun 25, 2020 at 12:31:16PM +0100, Matthew Wilcox (Oracle) wrote: > I want a memalloc_nowait like we have memalloc_noio and memalloc_nofs > for an upcoming patch series, and Jens also wants it for non-blocking > io_uring. It turns out we already have dm-bufio which could benefit > from mema

Re: [dm-devel] [PATCH 13/13] Documentation/admin-guide: xfs: drop doubled word

2020-07-03 Thread Darrick J. Wong
On Fri, Jul 03, 2020 at 08:20:20PM -0700, Randy Dunlap wrote: > Drop the doubled word "for". > > Signed-off-by: Randy Dunlap > Cc: Jonathan Corbet > Cc: linux-...@vger.kernel.org > Cc: Darrick J. Wong > Cc: linux-...@vger.kernel.org Looks good to me, Rev

Re: [dm-devel] [PATCH v2] dm: Call proper helper to determine dax support

2020-09-18 Thread Darrick J. Wong
On Thu, Sep 17, 2020 at 10:30:03PM -0700, Dan Williams wrote: > From: Jan Kara > > DM was calling generic_fsdax_supported() to determine whether a device > referenced in the DM table supports DAX. However this is a helper for "leaf" > device drivers so that > they don't have to duplicate common

Re: [dm-devel] [PATCH v6 4/6] block: Add support for REQ_ALLOCATE flag

2020-02-12 Thread Darrick J. Wong
On Mon, Feb 10, 2020 at 12:33:53PM +0300, Kirill Tkhai wrote: > This adds support for REQ_ALLOCATE extension of REQ_OP_WRITE_ZEROES > operation, which encourages a block device driver to just allocate > blocks (or mark them allocated) instead of actual blocks zeroing. > REQ_ALLOCATE is aimed to be

Re: [dm-devel] [PATCH v6 6/6] loop: Add support for REQ_ALLOCATE

2020-02-12 Thread Darrick J. Wong
_req_filebacked(struct loop_device *lo, > struct request *rq) >* write zeroes the range. Otherwise, punch them out. >*/ Please update this comment to reflect the new REQ_ALLOCATE mode, and move it to where you define write_zeroes_to_falloca

Re: [dm-devel] [PATCH v6 4/6] block: Add support for REQ_ALLOCATE flag

2020-02-12 Thread Darrick J. Wong
On Wed, Feb 12, 2020 at 08:33:52PM +0300, Kirill Tkhai wrote: > Hi, Darrick, > > On 12.02.2020 19:58, Darrick J. Wong wrote: > > On Mon, Feb 10, 2020 at 12:33:53PM +0300, Kirill Tkhai wrote: > >> This adds support for REQ_ALLOCATE extension of REQ_OP_WRITE_ZEROES > >

Re: [dm-devel] [PATCH v6 6/6] loop: Add support for REQ_ALLOCATE

2020-02-12 Thread Darrick J. Wong
On Wed, Feb 12, 2020 at 11:00:15PM +0300, Kirill Tkhai wrote: > On 12.02.2020 20:01, Darrick J. Wong wrote: > > On Mon, Feb 10, 2020 at 12:34:04PM +0300, Kirill Tkhai wrote: > >> Support for new modifier of REQ_OP_WRITE_ZEROES command. > >> This results in allocat

Re: [dm-devel] [PATCH v7 6/6] loop: Add support for REQ_ALLOCATE

2020-02-13 Thread Darrick J. Wong
On Thu, Feb 13, 2020 at 10:39:35AM +0300, Kirill Tkhai wrote: > Support for new modifier of REQ_OP_WRITE_ZEROES command. > This results in allocation extents in backing file instead > of actual blocks zeroing. > > Signed-off-by: Kirill Tkhai > Reviewed-by: Bob Liu > Reviewe

Re: [dm-devel] [PATCH v7 0/6] block: Introduce REQ_ALLOCATE flag for REQ_OP_WRITE_ZEROES

2020-03-25 Thread Darrick J. Wong
On Thu, Mar 19, 2020 at 09:03:40AM -0400, Martin K. Petersen wrote: > > Christoph, > > >> Some comments? Some requests for reworking? Some personal reasons to > >> ignore my patches? > > > > I'm still completely opposed to the magic overloading using a flag. > > That is just a bad design waiting

Re: [dm-devel] [PATCH 04/45] fs: simplify freeze_bdev/thaw_bdev

2020-11-30 Thread Darrick J. Wong
| 2 +- > fs/f2fs/file.c| 14 +- > fs/xfs/xfs_fsops.c| 7 ++----- For the xfs part: Acked-by: Darrick J. Wong (I did glance at the other 44 patches and didn't see anything that screamed 'wrong' but I wouldn't call that a strong review.

Re: [dm-devel] [RFC PATCH v4 2/3] block: add simple copy support

2021-01-04 Thread Darrick J. Wong
SelvaKumar S: This didn't show up on dm-devel, sorry for the OT reply... On Mon, Jan 04, 2021 at 12:47:11PM +, Damien Le Moal wrote: > On 2021/01/04 19:48, SelvaKumar S wrote: > > Add new BLKCOPY ioctl that offloads copying of one or more sources > > ranges to a destination in the device. Acce

Re: [dm-devel] [RFC PATCH 26/34] xfs: use bio_new in xfs_rw_bdev

2021-01-29 Thread Darrick J. Wong
On Wed, Jan 27, 2021 at 11:11:25PM -0800, Chaitanya Kulkarni wrote: > Signed-off-by: Chaitanya Kulkarni Seems fine to me... Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_bio_io.c | 7 ++- > 1 file changed, 2 insertions(+), 5 deletions(-) > > diff --git a/fs/xfs

Re: [dm-devel] [RFC PATCH 18/34] iomap: use bio_new in iomap_dio_bio_actor

2021-01-29 Thread Darrick J. Wong
On Wed, Jan 27, 2021 at 11:11:17PM -0800, Chaitanya Kulkarni wrote: > Signed-off-by: Chaitanya Kulkarni > --- > fs/iomap/direct-io.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/fs/iomap/direct-io.c b/fs/iomap/direct-io.c > index f6c557a1bd25..0737192f7e5c 100644

Re: [dm-devel] [RFC PATCH 17/34] iomap: use bio_new in iomap_dio_zero

2021-01-29 Thread Darrick J. Wong
On Wed, Jan 27, 2021 at 11:11:16PM -0800, Chaitanya Kulkarni wrote: > Signed-off-by: Chaitanya Kulkarni Looks ok to me, Reviewed-by: Darrick J. Wong --D > --- > fs/iomap/direct-io.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/fs/ioma

Re: [dm-devel] [RFC PATCH 27/34] xfs: use bio_new in xfs_buf_ioapply_map

2021-01-29 Thread Darrick J. Wong
On Wed, Jan 27, 2021 at 11:11:26PM -0800, Chaitanya Kulkarni wrote: > Signed-off-by: Chaitanya Kulkarni Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_buf.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/fs/xfs/xfs_buf.c b/fs/xfs

Re: [dm-devel] [PATCH RESEND v2 09/10] xfs: Implement ->corrupted_range() for XFS

2021-02-01 Thread Darrick J. Wong
On Fri, Jan 29, 2021 at 02:27:56PM +0800, Shiyang Ruan wrote: > This function is used to handle errors which may cause data lost in > filesystem. Such as memory failure in fsdax mode. > > In XFS, it requires "rmapbt" feature in order to query for files or > metadata which associated to the corrup

Re: [dm-devel] [PATCH RESEND v2 08/10] md: Implement ->corrupted_range()

2021-02-01 Thread Darrick J. Wong
On Fri, Jan 29, 2021 at 02:27:55PM +0800, Shiyang Ruan wrote: > With the support of ->rmap(), it is possible to obtain the superblock on > a mapped device. > > If a pmem device is used as one target of mapped device, we cannot > obtain its superblock directly. With the help of SYSFS, the mapped >

Re: [dm-devel] [PATCH v3 02/11] blk: Introduce ->corrupted_range() for block device

2021-03-04 Thread Darrick J. Wong
On Wed, Feb 10, 2021 at 02:21:39PM +0100, Christoph Hellwig wrote: > On Mon, Feb 08, 2021 at 06:55:21PM +0800, Shiyang Ruan wrote: > > In fsdax mode, the memory failure happens on block device. So, it is > > needed to introduce an interface for block devices. Each kind of block > > device can han

Re: [dm-devel] [PATCH 0/7] add simple copy support

2021-08-17 Thread Darrick J. Wong
On Tue, Aug 17, 2021 at 03:44:16PM +0530, SelvaKumar S wrote: > This started out as an attempt to support NVMe Simple Copy Command (SCC), > and evolved during the RFC review process. > > The patchset, at this point, contains - > 1. SCC support in NVMe driver > 2. Block-layer infra for copy-offload

Re: [dm-devel] [PATCH 4/7] block: Introduce a new ioctl for simple copy

2021-08-17 Thread Darrick J. Wong
On Tue, Aug 17, 2021 at 03:44:20PM +0530, SelvaKumar S wrote: > From: Nitesh Shetty > > Add new BLKCOPY ioctl that offloads copying of one or more sources ranges > to a destination in the device. COPY ioctl accepts a 'copy_range' > structure that contains destination (in sectors), no of sources a

Re: [dm-devel] [PATCH RESEND v6 1/9] pagemap: Introduce ->memory_failure()

2021-08-18 Thread Darrick J. Wong
On Tue, Aug 17, 2021 at 11:08:40PM -0700, Jane Chu wrote: > > On 8/17/2021 10:43 PM, Jane Chu wrote: > > More information - > > > > On 8/16/2021 10:20 AM, Jane Chu wrote: > > > Hi, ShiYang, > > > > > > So I applied the v6 patch series to my 5.14-rc3 as it's what you > > > indicated is what v6 wa

Re: [dm-devel] [PATCH 4/7] block: Introduce a new ioctl for simple copy

2021-08-18 Thread Darrick J. Wong
On Wed, Aug 18, 2021 at 09:07:54PM +0530, Nitesh Shetty wrote: > On Wed, Aug 18, 2021 at 5:06 AM Darrick J. Wong wrote: > > > > On Tue, Aug 17, 2021 at 03:44:20PM +0530, SelvaKumar S wrote: > > > From: Nitesh Shetty > > > > > > Add new BLKCOPY ioctl th

Re: [PATCH 06/11] xfs: factor out a xfs_setup_dax helper

2021-10-18 Thread Darrick J. Wong
bring that up is that Eric reminded me a while ago that we don't actually print any kind of EXPERIMENTAL warning for the auto-detection behavior. That said, I never liked looking at the nested backwards logic of the old code, so: Reviewed-by: Darrick J. Wong --D > + struct xfs

Re: [dm-devel] [PATCH 07/11] dax: remove dax_capable

2021-10-19 Thread Darrick J. Wong
i : agcount; > } > > -static bool > -xfs_buftarg_is_dax( > - struct super_block *sb, > - struct xfs_buftarg *bt) > -{ > - return dax_supported(bt->bt_daxdev, bt->bt_bdev, sb->s_blocksize, 0, > - bdev_nr_sec

Re: [dm-devel] [PATCH 0/6] dax poison recovery with RWF_RECOVERY_DATA flag

2021-10-21 Thread Darrick J. Wong
On Fri, Oct 22, 2021 at 01:37:28AM +, Jane Chu wrote: > On 10/21/2021 4:31 AM, Christoph Hellwig wrote: > > Looking over the series I have serious doubts that overloading the > > slow path clear poison operation over the fast path read/write > > path is such a great idea. Why would data recove

Re: [dm-devel] [PATCH 0/6] dax poison recovery with RWF_RECOVERY_DATA flag

2021-10-27 Thread Darrick J. Wong
On Tue, Oct 26, 2021 at 11:49:59PM -0700, Christoph Hellwig wrote: > On Fri, Oct 22, 2021 at 08:52:55PM +, Jane Chu wrote: > > Thanks - I try to be honest. As far as I can tell, the argument > > about the flag is a philosophical argument between two views. > > One view assumes design based on

Re: futher decouple DAX from block devices

2021-10-29 Thread Darrick J. Wong
On Fri, Oct 29, 2021 at 08:42:29AM -0700, Dan Williams wrote: > On Thu, Oct 28, 2021 at 4:52 PM Stephen Rothwell > wrote: > > > > Hi Dan, > > > > On Wed, 27 Oct 2021 13:46:31 -0700 Dan Williams > > wrote: > > > > > > My merge resolution is here [1]. Christoph, please have a look. The > > > reba

Re: [dm-devel] [PATCH 0/6] dax poison recovery with RWF_RECOVERY_DATA flag

2021-10-29 Thread Darrick J. Wong
On Fri, Oct 29, 2021 at 12:46:14PM +0100, Pavel Begunkov wrote: > On 10/28/21 23:59, Dave Chinner wrote: > [...] > > > > Well, my point is doing recovery from bit errors is by definition not > > > > the fast path. Which is why I'd rather keep it away from the pmem > > > > read/write fast path, whi

Re: [dm-devel] [PATCH 0/6] dax poison recovery with RWF_RECOVERY_DATA flag

2021-10-29 Thread Darrick J. Wong
On Fri, Oct 29, 2021 at 08:23:53PM +0100, Pavel Begunkov wrote: > On 10/29/21 17:57, Darrick J. Wong wrote: > > On Fri, Oct 29, 2021 at 12:46:14PM +0100, Pavel Begunkov wrote: > > > On 10/28/21 23:59, Dave Chinner wrote: > > > [...] > > > > > > Well,

Re: [dm-devel] [RFC PATCH 1/8] block: add support for REQ_OP_VERIFY

2021-11-04 Thread Darrick J. Wong
On Wed, Nov 03, 2021 at 11:46:27PM -0700, Chaitanya Kulkarni wrote: > From: Chaitanya Kulkarni > > This adds a new block layer operation to offload verifying a range of > LBAs. This support is needed in order to provide file systems and > fabrics, kernel components to offload LBA verification whe

Re: [dm-devel] [RFC PATCH 0/8] block: add support for REQ_OP_VERIFY

2021-11-04 Thread Darrick J. Wong
On Thu, Nov 04, 2021 at 09:27:50AM +, Chaitanya Kulkarni wrote: > On 11/4/2021 12:14 AM, Christoph Hellwig wrote: > > External email: Use caution opening links or attachments > > > > > > What is the actual use case here? > > > > One of the immediate use-case is to use this interface with XF

Re: futher decouple DAX from block devices

2021-11-04 Thread Darrick J. Wong
On Thu, Nov 04, 2021 at 09:17:40AM +0100, Christoph Hellwig wrote: > On Wed, Nov 03, 2021 at 12:59:31PM -0500, Eric Sandeen wrote: > > Christoph, can I ask what the end game looks like, here? If dax is > > completely > > decoupled from block devices, are there user-visible changes? > > Yes. > >

Re: futher decouple DAX from block devices

2021-11-04 Thread Darrick J. Wong
On Thu, Nov 04, 2021 at 11:10:19AM -0700, Dan Williams wrote: > On Thu, Nov 4, 2021 at 10:36 AM Christoph Hellwig wrote: > > > > On Thu, Nov 04, 2021 at 10:34:17AM -0700, Darrick J. Wong wrote: > > > /me wonders, are block devices going away? Will mkfs.xfs have to le

Re: [PATCH v2 1/2] dax: Introduce normal and recovery dax operation modes

2021-11-05 Thread Darrick J. Wong
On Fri, Nov 05, 2021 at 07:16:37PM -0600, Jane Chu wrote: > Introduce DAX_OP_NORMAL and DAX_OP_RECOVERY operation modes to > {dax_direct_access, dax_copy_from_iter, dax_copy_to_iter}. > DAX_OP_NORMAL is the default or the existing mode, and > DAX_OP_RECOVERY is a new mode for data recovery purpose.

Re: [PATCH v2 2/2] dax,pmem: Implement pmem based dax data recovery

2021-11-05 Thread Darrick J. Wong
On Fri, Nov 05, 2021 at 07:16:38PM -0600, Jane Chu wrote: > For /dev/pmem based dax, enable DAX_OP_RECOVERY mode for > dax_direct_access to translate 'kaddr' over a range that > may contain poison(s); and enable dax_copy_to_iter to > read as much data as possible up till a poisoned page is > encoun

Re: [PATCH 07/29] xfs: factor out a xfs_setup_dax_always helper

2021-11-17 Thread Darrick J. Wong
g Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_super.c | 47 +++--- > 1 file changed, 28 insertions(+), 19 deletions(-) > > diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c > index e21459f9923a8..875fd3151d6c9 100644 > ---

Re: [PATCH 06/29] dax: move the partition alignment check into fs_dax_get_by_bdev

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:32:46AM +0100, Christoph Hellwig wrote: > fs_dax_get_by_bdev is the primary interface to find a dax device for a > block device, so move the partition alignment check there instead of > wiring it up through ->dax_supported. > > Signed-off-by: Christoph Hellwig > --- >

Re: [PATCH 08/29] dax: remove dax_capable

2021-11-23 Thread Darrick J. Wong
Turning off DAX."); > goto disable_dax; > } > > + if (mp->m_super->s_blocksize != PAGE_SIZE) { > + xfs_alert(mp, > + "DAX not supported for blocksize. Turning off DAX.\n"); Nit: xfs_alert() already adds a new

Re: [PATCH 12/29] fsdax: remove a pointless __force cast in copy_cow_page_dax

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:32:52AM +0100, Christoph Hellwig wrote: > Despite its name copy_user_page expected kernel addresses, which is what > we already have. > > Signed-off-by: Christoph Hellwig Looks ok, Reviewed-by: Darrick J. Wong --D > --- > fs/dax.c | 2 +- &g

Re: [PATCH 13/29] fsdax: use a saner calling convention for copy_cow_page_dax

2021-11-23 Thread Darrick J. Wong
-by: Darrick J. Wong --D > --- > fs/dax.c | 29 + > 1 file changed, 13 insertions(+), 16 deletions(-) > > diff --git a/fs/dax.c b/fs/dax.c > index 73bd1439d8089..e51b4129d1b65 100644 > --- a/fs/dax.c > +++ b/fs/dax.c > @@ -709,26 +709,31 @

Re: [PATCH 14/29] fsdax: simplify the pgoff calculation

2021-11-23 Thread Darrick J. Wong
e relying on fs_dax_get_by_bdev to have validated this previously, which is why the error return stuff goes away? If so, Reviewed-by: Darrick J. Wong --D > - return -EINVAL; > - return 0; > -} > -EXPORT_SYMBOL(bdev_dax_pgoff); > - > /** > * dax_get_by_host() -

Re: [PATCH 15/29] xfs: add xfs_zero_range and xfs_truncate_page helpers

2021-11-23 Thread Darrick J. Wong
ig Looks good to me, Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_bmap_util.c | 7 +++ > fs/xfs/xfs_file.c | 3 +-- > fs/xfs/xfs_iomap.c | 25 + > fs/xfs/xfs_iomap.h | 4 > fs/xfs/xfs_iops.c | 7 +++ > fs/xfs/x

Re: [PATCH 16/29] fsdax: simplify the offset check in dax_iomap_zero

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:32:56AM +0100, Christoph Hellwig wrote: > The file relative offset must have the same alignment as the storage > offset, so use that and get rid of the call to iomap_sector. > > Signed-off-by: Christoph Hellwig Reviewed-by: Darrick J. Wong --D > ---

Re: [PATCH 17/29] fsdax: factor out a dax_memzero helper

2021-11-23 Thread Darrick J. Wong
if (rc >= 0) { > > Technically this should be "> 0" because dax_direct_access() returns > nr_available_pages @pgoff, but this isn't broken because > dax_direct_access() converts the "zero pages available" case into > -ERANGE. Agreed. With that fixed,

Re: [PATCH 18/29] fsdax: decouple zeroing from the iomap buffered I/O code

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:32:58AM +0100, Christoph Hellwig wrote: > Unshare the DAX and iomap buffered I/O page zeroing code. This code > previously did a IS_DAX check deep inside the iomap code, which in > fact was the only DAX check in the code. Instead move these checks > into the callers. M

Re: [PATCH 20/29] ext4: cleanup the dax handling in ext4_fill_super

2021-11-23 Thread Darrick J. Wong
if (blocksize == PAGE_SIZE) > set_bit(EXT4_FLAGS_BDEV_IS_DAX, &sbi->s_ext4_flags); > else > @@ -5096,10 +5095,10 @@ static int ext4_fill_super(struct super_block *sb, > void *data, int silent) > out_fail: > sb->s_fs_i

Re: [PATCH 19/29] ext2: cleanup the dax handling in ext2_fill_super

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:32:59AM +0100, Christoph Hellwig wrote: > Only call fs_dax_get_by_bdev once the sbi has been allocated and remove > the need for the dax_dev local variable. > > Signed-off-by: Christoph Hellwig Looks good, Reviewed-by: Darrick J. Wong --D > --- >

Re: [PATCH 21/29] xfs: move dax device handling into xfs_{alloc,free}_buftarg

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:33:01AM +0100, Christoph Hellwig wrote: > Hide the DAX device lookup from the xfs_super.c code. > > Reviewed-by: Christoph Hellwig This looks to be a straightforward conversion. Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_buf.c | 8 +++

Re: [PATCH 22/29] iomap: add a IOMAP_DAX flag

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:33:02AM +0100, Christoph Hellwig wrote: > Add a flag so that the file system can easily detect DAX operations. > > Signed-off-by: Christoph Hellwig > --- > fs/dax.c | 7 --- > include/linux/iomap.h | 1 + > 2 files changed, 5 insertions(+), 3 deletions

Re: [PATCH 23/29] xfs: use IOMAP_DAX to check for DAX mappings

2021-11-23 Thread Darrick J. Wong
bother me either way, was just curious. Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_iomap.c | 7 --- > fs/xfs/xfs_iomap.h | 3 ++- > fs/xfs/xfs_pnfs.c | 2 +- > 3 files changed, 7 insertions(+), 5 deletions(-) > > diff --git a/fs/xfs/xfs_iomap.c b/fs

Re: [PATCH 24/29] xfs: use xfs_direct_write_iomap_ops for DAX zeroing

2021-11-23 Thread Darrick J. Wong
I've wanted to fix this for a long time, but I like your surrounding cleanups better than anything I had time to work on. :) Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/xfs_iomap.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/fs/xfs/xfs_i

Re: [PATCH 26/29] fsdax: shift partition offset handling into the file systems

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:33:06AM +0100, Christoph Hellwig wrote: > Remove the last user of ->bdev in dax.c by requiring the file system to > pass in an address that already includes the DAX offset. As part of the > only set ->bdev or ->daxdev when actually required in the ->iomap_begin As part

Re: [PATCH 27/29] dax: fix up some of the block device related ifdefs

2021-11-23 Thread Darrick J. Wong
by: Christoph Hellwig Looks ok, Reviewed-by: Darrick J. Wong --D > --- > include/linux/dax.h | 41 - > 1 file changed, 20 insertions(+), 21 deletions(-) > > diff --git a/include/linux/dax.h b/include/linux/dax.h > index 90f95deff504d..556

Re: [PATCH 28/29] iomap: build the block based code conditionally

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:33:08AM +0100, Christoph Hellwig wrote: > Only build the block based iomap code if CONFIG_BLOCK is set. Currently > that is always the case, but it will change soon. > > Signed-off-by: Christoph Hellwig Looks ok, Reviewed-by: Darrick J. Wong --D

Re: [PATCH 29/29] fsdax: don't require CONFIG_BLOCK

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 09, 2021 at 09:33:09AM +0100, Christoph Hellwig wrote: > The file system DAX code now does not require the block code. So allow > building a kernel with fuse DAX but not block layer. > > Signed-off-by: Christoph Hellwig Looks good, Reviewed-by: Darrick J. Wong --D

Re: [PATCH 21/29] xfs: move dax device handling into xfs_{alloc,free}_buftarg

2021-11-23 Thread Darrick J. Wong
On Tue, Nov 23, 2021 at 06:40:47PM -0800, Dan Williams wrote: > On Tue, Nov 9, 2021 at 12:34 AM Christoph Hellwig wrote: > > > > Hide the DAX device lookup from the xfs_super.c code. > > > > Reviewed-by: Christoph Hellwig > > That's an interesting spelling of "Signed-off-by", but patch looks > g

Re: [PATCH 04/29] dax: simplify the dax_device <-> gendisk association

2021-11-30 Thread Darrick J. Wong
f-by: Christoph Hellwig > Acked-by: Mike Snitzer Nice cleanup from the fs side! Reviewed-by: Darrick J. Wong --D > --- > drivers/dax/bus.c| 6 +- > drivers/dax/super.c | 109 +-- > drivers/md/dm.c |

Re: [PATCH 05/29] dax: remove the pgmap sanity checks in generic_fsdax_supported

2021-11-30 Thread Darrick J. Wong
On Mon, Nov 29, 2021 at 11:21:39AM +0100, Christoph Hellwig wrote: > Drivers that register a dax_dev should make sure it works, no need > to double check from the file system. > > Signed-off-by: Christoph Hellwig > Reviewed-by: Dan Williams Reviewed-by: Darrick J. Wong --D &

Re: [PATCH 06/29] dax: move the partition alignment check into fs_dax_get_by_bdev

2021-11-30 Thread Darrick J. Wong
Christoph Hellwig > Reviewed-by: Dan Williams Makes more sense than the old "get the dax device and /then/ check if it's ok to use it" strategy. Reviewed-by: Darrick J. Wong --D > --- > drivers/dax/super.c | 23 ++- > 1 file changed, 6 insertions(+),

Re: [PATCH 18/29] fsdax: decouple zeroing from the iomap buffered I/O code

2021-11-30 Thread Darrick J. Wong
the callers. Most callers already have DAX special casing anyway > and XFS will need it for reflink support as well. > > Signed-off-by: Christoph Hellwig > Reviewed-by: Dan Williams Hooray, less dax entanglement! Reviewed-by: Darrick J. Wong --D > --- >

Re: [PATCH 23/29] xfs: pass the mapping flags to xfs_bmbt_to_iomap

2021-11-30 Thread Darrick J. Wong
ss confusing, Reviewed-by: Darrick J. Wong --D > --- > fs/xfs/libxfs/xfs_bmap.c | 4 ++-- > fs/xfs/xfs_aops.c| 2 +- > fs/xfs/xfs_iomap.c | 35 --- > fs/xfs/xfs_iomap.h | 5 +++-- > fs/xfs/xfs_pnfs.c| 2 +- > 5 fi

Re: [PATCH 24/29] iomap: add a IOMAP_DAX flag

2021-11-30 Thread Darrick J. Wong
ition offset only for operations that actually use DAX, > but not things like fiemap that are based on the block device. > In the long run it should also allow turning the bdev, dax_dev > and inline_data into a union. Heh. :) Reviewed-by: Darrick J. Wong --D > Signed-off-by: Christop

Re: [PATCH 25/29] dax: return the partition offset from fs_dax_get_by_bdev

2021-11-30 Thread Darrick J. Wong
ristoph Hellwig > Reviewed-by: Dan Williams Reviewed-by: Darrick J. Wong --D > --- > drivers/dax/super.c | 9 ++--- > drivers/md/dm.c | 4 ++-- > fs/erofs/internal.h | 2 ++ > fs/erofs/super.c| 4 ++-- > fs/ext2/ext2.h | 1 + > fs/ext2/super.c | 2 +-

Re: [PATCH 26/29] fsdax: shift partition offset handling into the file systems

2021-11-30 Thread Darrick J. Wong
an ack from Ted and Jan. Reviewed-by: Darrick J. Wong --D > --- > fs/dax.c| 6 +- > fs/erofs/data.c | 11 +-- > fs/erofs/internal.h | 1 + > fs/ext2/inode.c | 8 ++-- > fs/ext4/inode.c | 16 +++- > fs/xfs/xfs_iomap.

[dm-devel] [PATCH 2/3] block: require write_same and discard requests align to logical block size

2016-06-16 Thread Darrick J. Wong
ical block writes. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig --- block/blk-lib.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/block/blk-lib.c b/block/blk-lib.c index 9e29dc3..012aa98 100644 --- a/block/blk-lib.c +++ b/block/blk-lib.c @@ -29,6 +2

[dm-devel] [PATCH v9 0/3] fallocate for block devices

2016-06-16 Thread Darrick J. Wong
Hi, This is a redesign of the patch series that fixes various interface problems with the existing "zero out this part of a block device" code. BLKZEROOUT2 is gone. The first patch is still a fix to the existing BLKZEROOUT ioctl to invalidate the page cache if the zeroing command to the underlyi

[dm-devel] [PATCH 1/3] block: invalidate the page cache when issuing BLKZEROOUT.

2016-06-16 Thread Darrick J. Wong
Invalidate the page cache (as a regular O_DIRECT write would do) to avoid returning stale cache contents at a later time. v5: Refactor the 4.4 refactoring of the ioctl code into separate functions. Split the page invalidation and the new ioctl into separate patches. Signed-off-by: Darrick J

[dm-devel] [PATCH 3/3] block: implement (some of) fallocate for block devices

2016-06-16 Thread Darrick J. Wong
sion. v3: Forward port to 4.7. Signed-off-by: Darrick J. Wong --- fs/block_dev.c | 84 fs/open.c |3 +- 2 files changed, 86 insertions(+), 1 deletion(-) diff --git a/fs/block_dev.c b/fs/block_dev.c index 71ccab1..a3975c4 100644

Re: [dm-devel] [PATCH 1/3] block: invalidate the page cache when issuing BLKZEROOUT.

2016-06-28 Thread Darrick J. Wong
On Mon, Jun 20, 2016 at 02:35:29PM +0200, Bart Van Assche wrote: > On 06/17/2016 03:18 AM, Darrick J. Wong wrote: > >Invalidate the page cache (as a regular O_DIRECT write would do) to avoid > >returning stale cache contents at a later time. > > > >v5: Refactor the 4

[dm-devel] [PATCH 2/3] block: require write_same and discard requests align to logical block size

2016-08-25 Thread Darrick J. Wong
ical block writes. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Bart Van Assche Reviewed-by: Martin K. Petersen --- block/blk-lib.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/block/blk-lib.c b/block/blk-lib.c index 083e56f..46fe924 10

[dm-devel] [PATCH v10 0/3] fallocate for block devices

2016-08-25 Thread Darrick J. Wong
Hi, This is a redesign of the patch series that fixes various interface problems with the existing "zero out this part of a block device" code. BLKZEROOUT2 is gone. The first patch is still a fix to the existing BLKZEROOUT ioctl to invalidate the page cache if the zeroing command to the underlyi

[dm-devel] [PATCH 1/3] block: invalidate the page cache when issuing BLKZEROOUT.

2016-08-25 Thread Darrick J. Wong
invalidate_inode_pages2_range since we don't need it. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Martin K. Petersen --- block/ioctl.c | 18 -- 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/block/ioctl.c b/block/ioctl.c index ed

[dm-devel] [PATCH 3/3] block: implement (some of) fallocate for block devices

2016-08-25 Thread Darrick J. Wong
sion. v3: Forward port to 4.7. Signed-off-by: Darrick J. Wong --- fs/block_dev.c | 84 fs/open.c |3 +- 2 files changed, 86 insertions(+), 1 deletion(-) diff --git a/fs/block_dev.c b/fs/block_dev.c index c3cdde8..4df3fc8 100644

[dm-devel] [PATCH v10 0/3] fallocate for block devices

2016-09-28 Thread Darrick J. Wong
Hi Andrew & others, This is a resend of the patchset to fix page cache coherency with BLKZEROOUT and implement fallocate for block devices. This time I'm sending it direct to Andrew for inclusion because the block layer maintainer has not been responsive over the past year of submissions. Can thi

[dm-devel] [PATCH 3/3] block: implement (some of) fallocate for block devices

2016-09-28 Thread Darrick J. Wong
The other fallocate variants (collapse range, insert range, and allocate blocks) are not supported. Signed-off-by: Darrick J. Wong --- v2: Incorporate feedback from Christoph & Linus. Tentatively add a requirement that the fallocate arguments be aligned to logical block size, and put in

[dm-devel] [PATCH 1/3] block: invalidate the page cache when issuing BLKZEROOUT.

2016-09-28 Thread Darrick J. Wong
Invalidate the page cache (as a regular O_DIRECT write would do) to avoid returning stale cache contents at a later time. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Martin K. Petersen --- block/ioctl.c | 18 -- 1 file changed, 12 insertions

[dm-devel] [PATCH 2/3] block: require write_same and discard requests align to logical block size

2016-09-28 Thread Darrick J. Wong
ical block writes. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Bart Van Assche Reviewed-by: Martin K. Petersen --- block/blk-lib.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/block/blk-lib.c b/block/blk-lib.c index 083e56f..46fe924 10

Re: [dm-devel] [PATCH 3/3] block: implement (some of) fallocate for block devices

2016-09-28 Thread Darrick J. Wong
On Wed, Sep 28, 2016 at 06:42:14PM -0700, Bart Van Assche wrote: > On 09/28/16 17:39, Darrick J. Wong wrote: > >+if (end > isize) { > >+if (mode & FALLOC_FL_KEEP_SIZE) { > >+len = isize - start; > >+

[dm-devel] [PATCH v2 3/3] block: implement (some of) fallocate for block devices

2016-09-28 Thread Darrick J. Wong
The other fallocate variants (collapse range, insert range, and allocate blocks) are not supported. Signed-off-by: Darrick J. Wong --- v2: Incorporate feedback from Christoph & Linus. Tentatively add a requirement that the fallocate arguments be aligned to logical block size, and put in

Re: [dm-devel] [PATCH v2 3/3] block: implement (some of) fallocate for block devices

2016-09-29 Thread Darrick J. Wong
On Thu, Sep 29, 2016 at 01:08:57PM -0700, Bart Van Assche wrote: > On 09/28/2016 07:19 PM, Darrick J. Wong wrote: > >After much discussion, it seems that the fallocate feature flag > >FALLOC_FL_ZERO_RANGE maps nicely to SCSI WRITE SAME; and the feature > >FALLOC_FL_PUNCH_HO

[dm-devel] [PATCH v11 0/3] fallocate for block devices

2016-09-29 Thread Darrick J. Wong
Hi Andrew & others, This is a resend of the patchset to fix page cache coherency with BLKZEROOUT and implement fallocate for block devices. This time I'm sending it direct to Andrew for inclusion because the block layer maintainer has not been responsive over the past year of submissions. Can thi

[dm-devel] [PATCH 3/3] block: implement (some of) fallocate for block devices

2016-09-29 Thread Darrick J. Wong
The other fallocate variants (collapse range, insert range, and allocate blocks) are not supported. Signed-off-by: Darrick J. Wong Reviewed-by: Hannes Reinecke Reviewed-by: Bart Van Assche --- fs/block_dev.c | 77 fs/open.c |3

[dm-devel] [PATCH 2/3] block: require write_same and discard requests align to logical block size

2016-09-29 Thread Darrick J. Wong
ical block writes. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Bart Van Assche Reviewed-by: Martin K. Petersen Reviewed-by: Hannes Reinecke --- block/blk-lib.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/block/blk-lib.c b/block/blk-l

[dm-devel] [PATCH 1/3] block: invalidate the page cache when issuing BLKZEROOUT.

2016-09-29 Thread Darrick J. Wong
Invalidate the page cache (as a regular O_DIRECT write would do) to avoid returning stale cache contents at a later time. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig Reviewed-by: Martin K. Petersen Reviewed-by: Bart Van Assche Reviewed-by: Hannes Reinecke --- block/ioctl.c

Re: [dm-devel] trouble with generic/081

2017-01-09 Thread Darrick J. Wong
On Mon, Jan 09, 2017 at 08:54:02AM -0600, Eric Sandeen wrote: > On 1/9/17 8:22 AM, Zdenek Kabelac wrote: > > But could anyone from XFS specify - why umount is causing some > > 'more' damage, then no umount at all ? > > Please reread this thread... it /started/ with problems > /caused by unmoun

Re: [dm-devel] [PATCH 2/7] dax: change bdev_dax_supported() to support boolean returns

2018-05-24 Thread Darrick J. Wong
ging the return values > to return a bool where if DAX is supported then return true and no DAX > support returns false. > > Signed-off-by: Dave Jiang > Signed-off-by: Ross Zwisler Looks ok, Reviewed-by: Darrick J. Wong --D > --- > drivers/dax/super.c | 16

Re: [dm-devel] [PATCH 1/7] fs: allow per-device dax status checking for filesystems

2018-05-24 Thread Darrick J. Wong
On Thu, May 24, 2018 at 08:55:12PM -0600, Ross Zwisler wrote: > From: "Darrick J. Wong" > > Remove __bdev_dax_supported and change to bdev_dax_supported that takes a > bdev parameter. This enables multi-device filesystems like xfs to check > that a dax device ca

Re: [dm-devel] [PATCH 1/7] fs: allow per-device dax status checking for filesystems

2018-05-25 Thread Darrick J. Wong
On Fri, May 25, 2018 at 09:42:29AM -0600, Ross Zwisler wrote: > On Thu, May 24, 2018 at 10:02:18PM -0700, Darrick J. Wong wrote: > > On Thu, May 24, 2018 at 08:55:12PM -0600, Ross Zwisler wrote: > > > From: "Darrick J. Wong" > > > > >

Re: [dm-devel] [PATCH v2 2/7] dax: change bdev_dax_supported() to support boolean returns

2018-05-29 Thread Darrick J. Wong
ging the return values > to return a bool where if DAX is supported then return true and no DAX > support returns false. > > Signed-off-by: Dave Jiang > Signed-off-by: Ross Zwisler Looks ok, do you want me to pull the first two patches through the xfs tree? Reviewed-by: Darrick J

Re: [dm-devel] [PATCH v2 2/7] dax: change bdev_dax_supported() to support boolean returns

2018-05-31 Thread Darrick J. Wong
On Tue, May 29, 2018 at 04:01:14PM -0600, Ross Zwisler wrote: > On Tue, May 29, 2018 at 02:25:10PM -0700, Darrick J. Wong wrote: > > On Tue, May 29, 2018 at 01:51:01PM -0600, Ross Zwisler wrote: > > > From: Dave Jiang > > > > > > The function return values are

Re: [dm-devel] [PATCH v2 2/7] dax: change bdev_dax_supported() to support boolean returns

2018-05-31 Thread Darrick J. Wong
On Thu, May 31, 2018 at 04:52:06PM -0400, Mike Snitzer wrote: > On Thu, May 31 2018 at 3:13pm -0400, > Darrick J. Wong wrote: > > > On Tue, May 29, 2018 at 04:01:14PM -0600, Ross Zwisler wrote: > > > On Tue, May 29, 2018 at 02:25:10PM -0700, Darrick J. Wong wrote: >

Re: [dm-devel] [RFC] dm-bow working prototype

2018-10-25 Thread Darrick J. Wong
On Tue, Oct 23, 2018 at 02:23:28PM -0700, Paul Lawrence wrote: > bow == backup on write > > Similar to dm-snap, add the ability to take a snapshot of a device. > Unlike dm-snap, a separate volume is not required. > > dm-bow can be in one of three states. > > In state one, the free blocks on the

Re: [dm-devel] [PATCH 3/3] block: implement (some of) fallocate for block devices

2016-03-21 Thread Darrick J. Wong
On Mon, Mar 21, 2016 at 02:52:00PM -0400, Mike Snitzer wrote: > On Tue, Mar 15, 2016 at 3:42 PM, Darrick J. Wong > wrote: > > After much discussion, it seems that the fallocate feature flag > > FALLOC_FL_ZERO_RANGE maps nicely to SCSI WRITE SAME; and the feature > > F

Re: [dm-devel] [RFC PATCH] block: wire blkdev_fallocate() to block_device_operations' reserve_space

2016-04-12 Thread Darrick J. Wong
On Tue, Apr 12, 2016 at 04:04:59PM -0400, Mike Snitzer wrote: > On Tue, Apr 12 2016 at 12:42P -0400, > Brian Foster wrote: > > > Hi all, > > > > This is v2 of the XFS and block device reservation experiment. The > > significant changes in v2 are that the bdev interface has been condensed > > to

Re: [dm-devel] [RFC PATCH] block: wire blkdev_fallocate() to block_device_operations' reserve_space

2016-04-12 Thread Darrick J. Wong
On Tue, Apr 12, 2016 at 04:46:58PM -0400, Mike Snitzer wrote: > On Tue, Apr 12 2016 at 4:39pm -0400, > Darrick J. Wong wrote: > > > On Tue, Apr 12, 2016 at 04:04:59PM -0400, Mike Snitzer wrote: > > > On Tue, Apr 12 2016 at 12:42P -0400, > > > Brian Fos

Re: [dm-devel] [RFC PATCH] block: wire blkdev_fallocate() to block_device_operations' reserve_space

2016-04-12 Thread Darrick J. Wong
On Tue, Apr 12, 2016 at 05:04:27PM -0400, Mike Snitzer wrote: > On Tue, Apr 12 2016 at 4:39pm -0400, > Darrick J. Wong wrote: > > > On Tue, Apr 12, 2016 at 04:04:59PM -0400, Mike Snitzer wrote: > > > diff --git a/fs/block_dev.c b/fs/block_dev.c > > > index 5a2c3

[dm-devel] [RFC DONOTMERGE v8 0/3] fallocate for block devices

2016-04-12 Thread Darrick J. Wong
Hi, This is a redesign of the patch series that fixes various interface problems with the existing "zero out this part of a block device" code. BLKZEROOUT2 is gone. The first patch is still a fix to the existing BLKZEROOUT ioctl to invalidate the page cache if the zeroing command to the underlyi

[dm-devel] [PATCH 2/3] block: require write_same and discard requests align to logical block size

2016-04-12 Thread Darrick J. Wong
ical block writes. Signed-off-by: Darrick J. Wong Reviewed-by: Christoph Hellwig --- block/blk-lib.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/block/blk-lib.c b/block/blk-lib.c index 9ebf653..9dca6bb 100644 --- a/block/blk-lib.c +++ b/block/blk-lib.c @@ -49,6 +4

[dm-devel] [PATCH 3/3] block: implement (some of) fallocate for block devices

2016-04-12 Thread Darrick J. Wong
. Signed-off-by: Darrick J. Wong --- fs/block_dev.c | 87 fs/open.c |3 +- 2 files changed, 89 insertions(+), 1 deletion(-) diff --git a/fs/block_dev.c b/fs/block_dev.c index 20a2c02..5c8eb0c 100644 --- a/fs/block_dev.c

[dm-devel] [PATCH 1/3] block: invalidate the page cache when issuing BLKZEROOUT.

2016-04-12 Thread Darrick J. Wong
Invalidate the page cache (as a regular O_DIRECT write would do) to avoid returning stale cache contents at a later time. v5: Refactor the 4.4 refactoring of the ioctl code into separate functions. Split the page invalidation and the new ioctl into separate patches. Signed-off-by: Darrick J

  1   2   >