Re: [f2fs-dev] [PATCH v4 6/9] f2fs: don't allow DIO reads but not DIO writes

2022-08-16 Thread Dave Chinner
gt; we'd instead have to "duplicate" the API, with STATX_DIOROALIGN and > statx_dio_ro_*_align fields. That seems uglier than building a directional > indicator into the API from the beginning. On the other hand, requiring all > programs to check stx_dio_direction would add complexity to using the API. > > Any thoughts on this? Decide whether partial, single direction DIO serves a useful purpose before trying to work out what is needed in the API to indicate that this sort of crazy will be supported Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH 04/23] page-writeback: Convert write_cache_pages() to use filemap_get_folios_tag()

2022-10-18 Thread Dave Chinner
age(wbc, inode_to_bdi(mapping->host)); > - error = (*writepage)(page, wbc, data); > + error = writepage(&folio->page, wbc, data); Yet, IIUC, this treats all folios as if they are single page folios. i.e. it passes the head page of a multi-pa

Re: [f2fs-dev] [PATCH 00/23] Convert to filemap_get_folios_tag()

2022-10-18 Thread Dave Chinner
e updated and validated to ensure that it correctly handles multi-page folios. And the only way you can do that fully at this point in time is via testing XFS or AFS... Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing li

Re: [f2fs-dev] [PATCH v4 00/23] Convert to filemap_get_folios_tag()

2022-11-03 Thread Dave Chinner
the other changes (afs, ceph, cifs, gfs2) would be appreciated. Same question as last time: have you tested this with multipage folios enabled? If you haven't tested XFS, then I'm guessing the answer is no, and you haven't fixed the bug I pointed out in the write_cache_pages(

Re: [f2fs-dev] [PATCH v4 00/23] Convert to filemap_get_folios_tag()

2022-11-03 Thread Dave Chinner
On Thu, Nov 03, 2022 at 09:38:48AM -0700, Vishal Moola wrote: > On Thu, Nov 3, 2022 at 12:08 AM Dave Chinner wrote: > > > > On Wed, Nov 02, 2022 at 09:10:08AM -0700, Vishal Moola (Oracle) wrote: > > > This patch series replaces find_get_pages_range_tag() with > > &g

Re: [f2fs-dev] [PATCH 04/23] page-writeback: Convert write_cache_pages() to use filemap_get_folios_tag()

2022-11-03 Thread Dave Chinner
On Thu, Nov 03, 2022 at 03:28:05PM -0700, Vishal Moola wrote: > On Wed, Oct 19, 2022 at 08:01:52AM +1100, Dave Chinner wrote: > > On Thu, Sep 01, 2022 at 03:01:19PM -0700, Vishal Moola (Oracle) wrote: > > > Converted function to use folios throughout. This is in preparation for

Re: [f2fs-dev] [PATCH 04/23] page-writeback: Convert write_cache_pages() to use filemap_get_folios_tag()

2022-11-03 Thread Dave Chinner
On Thu, Nov 03, 2022 at 07:45:01PM -0700, Darrick J. Wong wrote: > On Fri, Nov 04, 2022 at 11:32:35AM +1100, Dave Chinner wrote: > > On Thu, Nov 03, 2022 at 03:28:05PM -0700, Vishal Moola wrote: > > > On Wed, Oct 19, 2022 at 08:01:52AM +1100, Dave Chinner wrote: > > > &

Re: [f2fs-dev] [PATCH 0/4] fsverity cleanups

2022-12-14 Thread Dave Chinner
| 46 - > include/linux/fsverity.h | 74 +--- > 6 files changed, 84 insertions(+), 71 deletions(-) The whole series looks fairly sane to me. Acked-by: Dave Chinner -- Dave Chinner da...@fromorbit.com __

Re: [f2fs-dev] [PATCH 14/18] xfs: use generic posix ACL infrastructure

2013-12-10 Thread Dave Chinner
On Sun, Dec 01, 2013 at 03:59:17AM -0800, Christoph Hellwig wrote: > Also create inodes with the proper mode instead of fixing it up later. > > Signed-off-by: Christoph Hellwig Nice cleanup work, Christoph. Reviewed-by: Dave Chinner -- Dave Chinner da...@from

Re: [f2fs-dev] [PATCH] f2fs: fix dirty page accounting when redirty

2014-02-28 Thread Dave Chinner
ount(sbi, F2FS_DIRTY_META); > wbc->pages_skipped++; > + account_page_redirty(page); > set_page_dirty(page); > return AOP_WRITEPAGE_ACTIVATE; redirty_page_for_writepage()? Cheers, Dave. -- Dave Chinner da...@fromorbit.com --

Re: [f2fs-dev] [RFC 00/32] making inode time stamps y2038 ready

2014-06-04 Thread Dave Chinner
me representation, and the kernel to be independent of the physical filesystem time encoding Cheers, Dave. -- Dave Chinner da...@fromorbit.com -- Learn Graph Databases - Download FREE O'Reilly Book "Grap

Re: [f2fs-dev] [PATCH v3] common/rc: generalize _get_filesize()

2019-10-15 Thread Dave Chinner
CH_MNT/file` $ git grep 'stat -c "%s"' tests/generic/286: test $(stat -c "%s" $src) = $(stat -c "%s" $dest) || tests/generic/286: test $(stat -c "%s" $src) = $(stat -c "%s" $dest) || tests/generic/286: test $(

Re: [f2fs-dev] [PATCH 1/3] fscrypt: add support for inline-encryption-optimized policies

2019-10-21 Thread Dave Chinner
filesystems. Why not just hash the 64 bit inode, file offset and block numbers into a single 64 bit value? It is still unique enough for the stated use (i.e. unique IV for each file block) but it doesn't limit what filesystem configurations can actually

Re: [f2fs-dev] [RFC] errno.h: Provide EFSCORRUPTED for everybody

2019-11-01 Thread Dave Chinner
both errors should use different values? That horse bolted to userspace years ago - this is just formalising the practice that has spread across multiple linux filesystems from XFS over the past ~10 years.. Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH 1/1] errno.h: Provide EFSBADCRC for everybody

2019-11-05 Thread Dave Chinner
EDOTDOT 73 /* RFS specific error */ > #define EBADMSG 74 /* Not a data message */ > +#define EFSBADCRCEBADMSG /* Bad CRC detected */ Inconsistent whitespace here. When you get tab vs space after #define wrong it only shows up in patches. :/ Chee

Re: [f2fs-dev] [RFC] errno.h: Provide EFSCORRUPTED for everybody

2019-11-05 Thread Dave Chinner
On Tue, Nov 05, 2019 at 04:15:50PM +0100, David Sterba wrote: > On Sat, Nov 02, 2019 at 08:38:23AM +1100, Dave Chinner wrote: > > On Fri, Nov 01, 2019 at 09:57:31PM +0100, Geert Uytterhoeven wrote: > > > Hi Valdis, > > > > > > On Thu, Oct 31, 2019 at 2

Re: [f2fs-dev] [RFC PATCH 3/3] xfs: show prjquota info on statfs for a file

2019-11-19 Thread Dave Chinner
statfs code should probably end up looking like this: - if ((ip->i_d.di_flags & XFS_DIFLAG_PROJINHERIT) && + if ((mp->m_flags & XFS_MOUNT_DIRQUOTA) && ((mp->m_qflags & (XFS_PQUOTA_ACCT|XFS_PQUOTA_ENFD))) == (XFS_

Re: [f2fs-dev] [PATCH 04/12] mm: Add readahead address space operation

2020-01-28 Thread Dave Chinner
2, nr_pages = 2, left = 1, this looks up the page at index 2, which is the one we issued IO on, not the one we "left behind" which is at index 3. Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH v5 04/13] mm: Add readahead address space operation

2020-02-10 Thread Dave Chinner
ge_nr_pages(page); > + rac->start += rac->batch_count; There's no mention of large page support in the patch description and I don't recall this sort of large page batching in previous iterations. This seems like new fun

Re: [f2fs-dev] [PATCH v5 04/13] mm: Add readahead address space operation

2020-02-11 Thread Dave Chinner
On Tue, Feb 11, 2020 at 04:54:13AM -0800, Matthew Wilcox wrote: > On Tue, Feb 11, 2020 at 03:52:30PM +1100, Dave Chinner wrote: > > > +struct readahead_control { > > > + struct file *file; > > > + struct address_space *mapping; > > > +/* private

Re: [f2fs-dev] [PATCH v6 01/19] mm: Return void from various readahead functions

2020-02-17 Thread Dave Chinner
on't need to worry that a present page in the readahead > window causes us to return a smaller nr_pages than we ought to have. > > Signed-off-by: Matthew Wilcox (Oracle) Looks good. Reviewed-by: Dave Chinner -- Dave Chinner da...@fromorbit.com _

Re: [f2fs-dev] [PATCH v6 02/19] mm: Ignore return value of ->readpages

2020-02-17 Thread Dave Chinner
Reviewed-by: Christoph Hellwig > --- > mm/readahead.c | 8 ++-- > 1 file changed, 2 insertions(+), 6 deletions(-) Simple enough. Reviewed-by: Dave Chinner -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linu

Re: [f2fs-dev] [PATCH v6 00/19] Change readahead API

2020-02-17 Thread Dave Chinner
el_init+0xe2/0xfa [2.479776] ret_from_fork+0x1f/0x30 [2.480737] ---[ end trace e77079de9b22dc6a ]--- I just dropped the ext4 conversion from my local tree so I can boot the machine and test XFS. Might have some more info when that crashes and burns... Cheers, Dave. -- Dave Chinner da...@fro

Re: [f2fs-dev] [PATCH v6 03/19] mm: Use readahead_control to pass arguments

2020-02-17 Thread Dave Chinner
efore continuing with the next >* batch. >*/ > - if (nr_pages) > - read_pages(mapping, filp, &page_pool, nr_pages, > - gfp_mask); > -

Re: [f2fs-dev] [PATCH v6 04/19] mm: Rearrange readahead loop

2020-02-17 Thread Dave Chinner
rac, &page_pool, gfp_mask); > + rac._nr_pages = 0; > } Also, why? This adds a goto from branched code that continues, then adds a continue so the unbranched code doesn't execute the code the goto jumps to. In absence of any explanation, this isn't an improvement

Re: [f2fs-dev] [PATCH v6 05/19] mm: Remove 'page_offset' from readahead loop

2020-02-17 Thread Dave Chinner
ontrol. > > Signed-off-by: Matthew Wilcox (Oracle) > --- > mm/readahead.c | 10 ++ > 1 file changed, 6 insertions(+), 4 deletions(-) Looks ok, but having the readahead dispatch out of line from the case that triggers it makes it hard to follow. Ch

Re: [f2fs-dev] [PATCH v6 06/19] mm: rename readahead loop variable to 'i'

2020-02-17 Thread Dave Chinner
igned-off-by: Matthew Wilcox (Oracle) > --- > mm/readahead.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) Looks fine. Reviewed-by: Dave Chinner -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list

Re: [f2fs-dev] [PATCH v6 07/19] mm: Put readahead pages in cache earlier

2020-02-17 Thread Dave Chinner
&page->lru, &page_pool); > + if (use_list) { > + page->index = offset; > + list_add(&page->lru, &page_pool); > + } else if (add_to_page_cache_lru(page, mapping, offset, > +

Re: [f2fs-dev] [PATCH v6 08/19] mm: Add readahead address space operation

2020-02-17 Thread Dave Chinner
ead.c b/mm/readahead.c > index 9e430daae42f..975ff5e387be 100644 > --- a/mm/readahead.c > +++ b/mm/readahead.c > @@ -121,7 +121,13 @@ static void read_pages(struct readahead_control *rac, > struct list_head *pages) > > blk_start_plug(&

Re: [f2fs-dev] [PATCH v6 09/19] mm: Add page_cache_readahead_limit

2020-02-17 Thread Dave Chinner
he." Also: "This is almost certainly not the function you want to call. Use page_cache_async_readahead or page_cache_sync_readahead() instead." Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH v6 10/19] fs: Convert mpage_readpages to mpage_readahead

2020-02-17 Thread Dave Chinner
insertions(+), 126 deletions(-) That's actually pretty simple changeover. Nothing really scary there. :) Reviewed-by: Dave Chinner -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH v6 11/19] btrfs: Convert from readpages to readahead

2020-02-17 Thread Dave Chinner
as_set(&xas, rac->_start + rac->_batch_count); What on earth does this do? Comments please! > + > + if (batch == size) > + break; > + } > + > + return batch; > +} Seems a bit big for an inline function. > + > +

Re: [f2fs-dev] [PATCH v6 00/19] Change readahead API

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 05:42:30AM -0800, Matthew Wilcox wrote: > On Tue, Feb 18, 2020 at 03:56:33PM +1100, Dave Chinner wrote: > > Latest version in your git tree: > > > > $ ▶ glo -n 5 willy/readahead > > 4be497096c04 mm: Use memalloc_nofs_save in readahead path >

Re: [f2fs-dev] [PATCH v6 03/19] mm: Use readahead_control to pass arguments

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 05:56:18AM -0800, Matthew Wilcox wrote: > On Tue, Feb 18, 2020 at 04:03:00PM +1100, Dave Chinner wrote: > > On Mon, Feb 17, 2020 at 10:45:44AM -0800, Matthew Wilcox wrote: > > > +static void read_pages(struct readahead_control *rac, struct list_

Re: [f2fs-dev] [PATCH v6 04/19] mm: Rearrange readahead loop

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 05:57:36AM -0800, Matthew Wilcox wrote: > On Tue, Feb 18, 2020 at 04:08:24PM +1100, Dave Chinner wrote: > > On Mon, Feb 17, 2020 at 10:45:45AM -0800, Matthew Wilcox wrote: > > > From: "Matthew Wilcox (Oracle)" > > > > > > Mov

Re: [f2fs-dev] [PATCH v6 07/19] mm: Put readahead pages in cache earlier

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 07:42:22AM -0800, Matthew Wilcox wrote: > On Tue, Feb 18, 2020 at 05:14:59PM +1100, Dave Chinner wrote: > > On Mon, Feb 17, 2020 at 10:45:52AM -0800, Matthew Wilcox wrote: > > > From: "Matthew Wilcox (Oracle)" > > > > > >

Re: [f2fs-dev] [PATCH v6 08/19] mm: Add readahead address space operation

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 08:10:04AM -0800, Matthew Wilcox wrote: > On Tue, Feb 18, 2020 at 05:21:47PM +1100, Dave Chinner wrote: > > On Mon, Feb 17, 2020 at 10:45:54AM -0800, Matthew Wilcox wrote: > > > From: "Matthew Wilcox (Oracle)" > > > > > > Th

Re: [f2fs-dev] [PATCH v6 09/19] mm: Add page_cache_readahead_limit

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 11:54:04AM -0800, Matthew Wilcox wrote: > On Tue, Feb 18, 2020 at 05:31:10PM +1100, Dave Chinner wrote: > > On Mon, Feb 17, 2020 at 10:45:56AM -0800, Matthew Wilcox wrote: > > > From: "Matthew Wilcox (Oracle)" > > > > > >

Re: [f2fs-dev] [PATCH v6 11/19] btrfs: Convert from readpages to readahead

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 01:12:28PM -0800, Matthew Wilcox wrote: > On Tue, Feb 18, 2020 at 05:57:58PM +1100, Dave Chinner wrote: > > On Mon, Feb 17, 2020 at 10:45:59AM -0800, Matthew Wilcox wrote: > > > From: "Matthew Wilcox (Oracle)" &g

Re: [f2fs-dev] [PATCH v6 12/19] erofs: Convert uncompressed files from readpages to readahead

2020-02-18 Thread Dave Chinner
--- > fs/erofs/zdata.c | 2 +- > include/trace/events/erofs.h | 6 +++--- > 3 files changed, 18 insertions(+), 29 deletions(-) Looks fine from the perspective of page iteration and error handling. Reviewed-by: Dave Chinne

Re: [f2fs-dev] [PATCH v6 13/19] erofs: Convert compressed files from readpages to readahead

2020-02-18 Thread Dave Chinner
file changed, 9 insertions(+), 20 deletions(-) Looks fine. Reviewed-by: Dave Chinner -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH v6 14/19] ext4: Convert from readpages to readahead

2020-02-18 Thread Dave Chinner
with ext4. I'll re-introduce the patch and see if it falls over again. Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH v6 16/19] fuse: Convert from readpages to readahead

2020-02-18 Thread Dave Chinner
of the get_page() call in fuse_readpages_fill(). > > Signed-off-by: Matthew Wilcox (Oracle) Looks OK. Reviewed-by: Dave Chinner -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists

Re: [f2fs-dev] [PATCH v6 17/19] iomap: Restructure iomap_readpages_actor

2020-02-18 Thread Dave Chinner
ge); > + ctx->cur_page = NULL; > + } > } > > return done; > @@ -451,11 +454,7 @@ iomap_readpages(struct address_space *mapping, struct > list_head *pages, > done: > if (ctx.bio) > submit_bio(ctx.bio); > - if

Re: [f2fs-dev] [PATCH v6 18/19] iomap: Convert from readpages to readahead

2020-02-18 Thread Dave Chinner
if (!ctx->cur_page_in_bio) unlock_page(ctx->cur_page); put_page(ctx->cur_page); ctx->cur_page = NULL; readahead_next(ctx->rac); } Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___

Re: [f2fs-dev] [PATCH v6 19/19] mm: Use memalloc_nofs_save in readahead path

2020-02-18 Thread Dave Chinner
l readahead allocations are now going to be GFP_NOFS | GFP_NORETRY | GFP_NOWARN ? If so, shouldn't we just strip all the gfp flags and masking out of the readahead path altogether? Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH v6 00/19] Change readahead API

2020-02-18 Thread Dave Chinner
On Wed, Feb 19, 2020 at 08:26:52AM +1100, Dave Chinner wrote: > On Tue, Feb 18, 2020 at 05:42:30AM -0800, Matthew Wilcox wrote: > > On Tue, Feb 18, 2020 at 03:56:33PM +1100, Dave Chinner wrote: > > > Latest version in your git tree: > > > > > > $ ▶ glo -n 5 w

Re: [f2fs-dev] [PATCH v6 00/19] Change readahead API

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 07:48:32PM -0800, Matthew Wilcox wrote: > On Wed, Feb 19, 2020 at 02:45:25PM +1100, Dave Chinner wrote: > > On Wed, Feb 19, 2020 at 08:26:52AM +1100, Dave Chinner wrote: > > > On Tue, Feb 18, 2020 at 05:42:30AM -0800, Matthew Wilcox wrote: > > > &

Re: [f2fs-dev] [PATCH v6 17/19] iomap: Restructure iomap_readpages_actor

2020-02-18 Thread Dave Chinner
On Tue, Feb 18, 2020 at 10:04:15PM -0800, Matthew Wilcox wrote: > On Wed, Feb 19, 2020 at 02:29:00PM +1100, Dave Chinner wrote: > > On Mon, Feb 17, 2020 at 10:46:11AM -0800, Matthew Wilcox wrote: > > > @@ -418,6 +412,15 @@ iomap_readpages_actor(struct inode *inode, loff_t > &

Re: [f2fs-dev] [PATCH] writeback: avoid double-writing the inode on a lazytime expiration

2020-03-11 Thread Dave Chinner
); > xfs_trans_commit(tp); > } > > > So flag=I_DIRTY_TIME_EXPIRED will be a no-op. > > Maybe you should be using I_DIRTY_SYNC instead? Or perhaps XFS should be > checking for either I_DIRTY_TIME_EXPIRED or I_DIRTY_SYNC? Right, XFS does not use the

Re: [f2fs-dev] [PATCH] writeback: avoid double-writing the inode on a lazytime expiration

2020-03-11 Thread Dave Chinner
d to be flushed to the journal. However, your change does not mark the inode dirtying on expiry anymore, so... > So I think we're fine. ... we're not fine. This breaks XFS and any other filesystem that relies on a I_DIRTY_SYNC notification to handle dirty time expiry correctly. Cheers, D

Re: [f2fs-dev] [PATCH] writeback: avoid double-writing the inode on a lazytime expiration

2020-03-12 Thread Dave Chinner
On Thu, Mar 12, 2020 at 07:34:45AM -0700, Christoph Hellwig wrote: > On Thu, Mar 12, 2020 at 11:07:17AM +1100, Dave Chinner wrote: > > > That's true, but when the timestamps were originally modified, > > > dirty_inode() will be called with flag == I_DIRTY_TIME, which w

Re: [f2fs-dev] [PATCH 2/4] fs: avoid double-writing the inode on a lazytime expiration

2020-03-25 Thread Dave Chinner
urrent in-memory timestamps are not present in the log before the fsync is run as so we violate the fsync guarantees lazytime gives for timestamp updates I haven't quite got it straight in my head if the iput() case has similar problems, but the fsync case definitely looks broken.

Re: [f2fs-dev] [PATCH v4 00/73] XArray version 4

2017-12-05 Thread Dave Chinner
On Wed, Dec 06, 2017 at 12:45:49PM +1100, Dave Chinner wrote: > On Tue, Dec 05, 2017 at 04:40:46PM -0800, Matthew Wilcox wrote: > > From: Matthew Wilcox > > > > I looked through some notes and decided this was version 4 of the XArray. > > Last posted two weeks ago, t

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-05 Thread Dave Chinner
nd operations in the MRU structure, not just the radix tree operations. Turning that around so that a larger XFS structure and algorithm is now protected by an opaque internal lock from generic storage structure the forms part of the larger structure seems like a bad design pattern to me... Cheers, D

Re: [f2fs-dev] [PATCH v4 00/73] XArray version 4

2017-12-05 Thread Dave Chinner
On Tue, Dec 05, 2017 at 04:40:46PM -0800, Matthew Wilcox wrote: > From: Matthew Wilcox > > I looked through some notes and decided this was version 4 of the XArray. > Last posted two weeks ago, this version includes a *lot* of changes. > I'd like to thank Dave Chin

Re: [f2fs-dev] [PATCH v4 00/73] XArray version 4

2017-12-05 Thread Dave Chinner
er path down the rat hole Ok, it build this time. -Dave. > > > -Original Message- > > From: Dave Chinner [mailto:da...@fromorbit.com] > > Sent: Tuesday, December 5, 2017 8:51 PM > > To: Matthew Wilcox > > Cc: Matthew Wilcox ; Ross Zwisler > > ; Jens A

Re: [f2fs-dev] [PATCH v4 00/73] XArray version 4

2017-12-05 Thread Dave Chinner
On Tue, Dec 05, 2017 at 06:05:15PM -0800, Matthew Wilcox wrote: > On Wed, Dec 06, 2017 at 12:45:49PM +1100, Dave Chinner wrote: > > On Tue, Dec 05, 2017 at 04:40:46PM -0800, Matthew Wilcox wrote: > > > From: Matthew Wilcox > > > > > > I looked through some not

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-05 Thread Dave Chinner
On Tue, Dec 05, 2017 at 06:02:08PM -0800, Matthew Wilcox wrote: > On Wed, Dec 06, 2017 at 12:36:48PM +1100, Dave Chinner wrote: > > > - if (radix_tree_preload(GFP_NOFS)) > > > - return -ENOMEM; > > > - > > > INIT_LIST_HEAD(&am

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-06 Thread Dave Chinner
On Tue, Dec 05, 2017 at 08:45:49PM -0800, Matthew Wilcox wrote: > On Wed, Dec 06, 2017 at 02:14:56PM +1100, Dave Chinner wrote: > > > The other conversions use the normal API instead of the advanced API, so > > > all of this gets hidden away. For example, the inode cache d

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-06 Thread Dave Chinner
On Wed, Dec 06, 2017 at 06:06:48AM -0800, Matthew Wilcox wrote: > On Wed, Dec 06, 2017 at 07:44:04PM +1100, Dave Chinner wrote: > > On Tue, Dec 05, 2017 at 08:45:49PM -0800, Matthew Wilcox wrote: > > > That said, using xa_cmpxchg() in the dquot code looked like the right > &g

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-07 Thread Dave Chinner
eadlock detection. e.g. it doesn't cover semaphores, which means it has zero coverage of the entire XFS metadata buffer subsystem and the complex locking orders we have for metadata updates. Put simply: lockdep doesn't provide me with any benefit, so I don't use it... Cheers, D

Re: [f2fs-dev] Lockdep is less useful than it was

2017-12-07 Thread Dave Chinner
> If you didn't > have to hack Kconfig to get rid of this problem, you'd be happier, right? I'd be much happier if it wasn't turned on by default in the first place. We gave plenty of warnings that there were still unsolved false positive problems with the new checks in t

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-07 Thread Dave Chinner
On Fri, Dec 08, 2017 at 01:45:52PM +0900, Byungchul Park wrote: > On Fri, Dec 08, 2017 at 09:22:16AM +1100, Dave Chinner wrote: > > On Thu, Dec 07, 2017 at 11:06:34AM -0500, Theodore Ts'o wrote: > > > On Wed, Dec 06, 2017 at 06:06:48AM -0800, Matthew Wilcox wrote: > >

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-08 Thread Dave Chinner
d to do the same thing with its semaphores. Who-ever adds semaphore checking to lockdep can add those annotations. The externalisation of the development cost of new lockdep functionality is one of the problems here. -Dave. (*) checkpatch.pl is considered mostly harmful round here, too, but that&#

Re: [f2fs-dev] Lockdep is less useful than it was

2017-12-08 Thread Dave Chinner
with a less efficient structure just to add lockdep validation to a tree that doesn't actually need any extra locking validation... Cheers, Dave. -- Dave Chinner da...@fromorbit.com -- Check out the vibrant tech

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-10 Thread Dave Chinner
On Fri, Dec 08, 2017 at 03:01:31PM -0800, Matthew Wilcox wrote: > On Thu, Dec 07, 2017 at 11:38:43AM +1100, Dave Chinner wrote: > > > > cmpxchg is for replacing a known object in a store - it's not really > > > > intended for doing initial inserts after a lookup t

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-11 Thread Dave Chinner
On Sat, Dec 09, 2017 at 09:00:18AM -0800, Joe Perches wrote: > On Sat, 2017-12-09 at 09:36 +1100, Dave Chinner wrote: > > 1. Using lockdep_set_novalidate_class() for anything other > > than device->mutex will throw checkpatch warnings. Nice. (*) > [] > > (*)

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-11 Thread Dave Chinner
On Sun, Dec 10, 2017 at 08:23:15PM -0800, Matthew Wilcox wrote: > On Mon, Dec 11, 2017 at 10:57:45AM +1100, Dave Chinner wrote: > > i.e. the fact the cmpxchg failed may not have anything to do with a > > race condtion - it failed because the slot wasn't empty like we > >

Re: [f2fs-dev] [PATCH v4 72/73] xfs: Convert mru cache to XArray

2017-12-11 Thread Dave Chinner
On Mon, Dec 11, 2017 at 02:12:28PM -0800, Joe Perches wrote: > On Tue, 2017-12-12 at 08:43 +1100, Dave Chinner wrote: > > On Sat, Dec 09, 2017 at 09:00:18AM -0800, Joe Perches wrote: > > > On Sat, 2017-12-09 at 09:36 +1100, Dave Chinner wrote: > > > > 1. Usin

Re: [f2fs-dev] xfstests: generic/342 run failed in f2fs

2017-12-28 Thread Dave Chinner
eate a new file that has the old name of the other file and is a child of the same parent directory, fsync the new inode, power fail and mount the filesystem, we do not lose the first file and that file has the name it was renamed to. This test is motivated by an issue found in

Re: [f2fs-dev] xfstests: generic/342 run failed in f2fs

2017-12-28 Thread Dave Chinner
On Thu, Dec 28, 2017 at 08:59:18AM -0800, Eric Sandeen wrote: > On 12/28/17 1:09 AM, Dave Chinner wrote: > ... > > > There's a whole lot more detail in the kernel commit 2be63d5ce929 > > ("Btrfs: fix file loss on log replay after renaming a file and > > fsync

Re: [f2fs-dev] [PATCH] f2fs: reserve bits for fs-verity

2018-04-02 Thread Dave Chinner
rypted file */ > > > > f2fs::i_advice > > #define FADVISE_ENCRYPT_BIT 0x04 > > > > It's very wired that f2fs didn't use well defined FS_ENCRYPT_FL bit > > position, > > result in that we leave a hole in on-disk

Re: [f2fs-dev] Symlink not persisted even after fsync

2018-04-13 Thread Dave Chinner
metadata recovery semantics, so it should behave the same way as ext4 and XFS in tests like these. If it doesn't, then there's filesystem bugs that need fixing... Cheers, Dave. -- Dave Chinner da...@fromorbit.com

Re: [f2fs-dev] Symlink not persisted even after fsync

2018-04-13 Thread Dave Chinner
as a ordering dependency with the symlink inode, not whatever is found by resolving the path in the symlink data. IOWs, there is no ordering relationship between the symlink's parent directory and whatever the symlink points at. i.e. it's a one-way relationship, and so there is no reve

Re: [f2fs-dev] Symlink not persisted even after fsync

2018-04-14 Thread Dave Chinner
on a symlink" may, in fact, run a fsync method of a completely different filesystem or subsystem. There is no way this could possible trigger a directory fsync of the symlink parent, because the object being fsync()d may not even know what a filesystem is... If you want a symlink

Re: [f2fs-dev] Symlink not persisted even after fsync

2018-04-16 Thread Dave Chinner
but it also means fsync() hasn't actually guaranteed inode changes made prior to the fsync to be persistent on disk. i.e. that's a violation of ordered metadata semantics and probably a bug. Cheers, Dave. -- Dave Chinner da...@fromorbit.com --

Re: [f2fs-dev] [PATCH 1/4] fs: introduce SB_INLINECRYPT

2020-06-17 Thread Dave Chinner
ions function, not a generic function. The option string must match what the filesystem defines, not require separate per-filesystem and VFS definitions of the same option that people could potentially get wrong (*cough* i_version vs iversion *cough*) Cheers, Dave. -- Dave Chinner da...@fromo

Re: [f2fs-dev] [PATCH 1/4] fs: introduce SB_INLINECRYPT

2020-06-22 Thread Dave Chinner
On Wed, Jun 17, 2020 at 08:19:35PM -0700, Eric Biggers wrote: > On Thu, Jun 18, 2020 at 11:19:12AM +1000, Dave Chinner wrote: > > On Wed, Jun 17, 2020 at 07:57:29AM +, Satya Tangirala wrote: > > > Introduce SB_INLINECRYPT, which is set by filesystems that wish to use > &g

Re: [f2fs-dev] [PATCH 1/4] fs: introduce SB_INLINECRYPT

2020-06-23 Thread Dave Chinner
On Mon, Jun 22, 2020 at 06:50:17PM -0700, Eric Biggers wrote: > On Tue, Jun 23, 2020 at 10:46:36AM +1000, Dave Chinner wrote: > > On Wed, Jun 17, 2020 at 08:19:35PM -0700, Eric Biggers wrote: > > > Are you objecting to the use of a SB_* flag, or just to showing

Re: [f2fs-dev] [PATCH v4 3/7] iomap: support direct I/O with fscrypt using blk-crypto

2020-07-22 Thread Dave Chinner
can issue as a contiguous range. If the fscrypt code is breaking that "contiguous IO range" because of the mode being used, the fs mapping code should break the mapping at the boundery where the IO needs to be broken. Hence the dio mapping code here will never build IOs that cross this -

Re: [f2fs-dev] [PATCH v4 3/7] iomap: support direct I/O with fscrypt using blk-crypto

2020-07-23 Thread Dave Chinner
On Wed, Jul 22, 2020 at 03:34:04PM -0700, Eric Biggers wrote: > On Thu, Jul 23, 2020 at 07:16:29AM +1000, Dave Chinner wrote: > > On Mon, Jul 20, 2020 at 11:37:35PM +, Satya Tangirala wrote: > > > From: Eric Biggers > > > > > > Wire up iomap direct I/O wit

Re: [f2fs-dev] [PATCH v4 3/7] iomap: support direct I/O with fscrypt using blk-crypto

2020-07-23 Thread Dave Chinner
On Thu, Jul 23, 2020 at 04:03:45PM -0700, Eric Biggers wrote: > Hi Dave, > > On Fri, Jul 24, 2020 at 08:07:52AM +1000, Dave Chinner wrote: > > > > > @@ -183,11 +184,16 @@ static void > > > > > iomap_dio_zero(struct iomap_dio *dio, str

Re: [f2fs-dev] [PATCH v4 3/7] iomap: support direct I/O with fscrypt using blk-crypto

2020-07-23 Thread Dave Chinner
On Thu, Jul 23, 2020 at 08:46:28PM -0700, Eric Biggers wrote: > On Fri, Jul 24, 2020 at 11:39:10AM +1000, Dave Chinner wrote: > > fscrypt_inode_uses_inline_crypto() ends up being: > > > > if (IS_ENCRYPTED(inode) && S_ISREG(inode->i_mode) && > &g

Re: [f2fs-dev] [PATCH v6 1/7] fscrypt: Add functions for direct I/O support

2020-07-24 Thread Dave Chinner
S has XFS_IOC_DIOINFO to expose exactly this information to userspace on a per-file basis. Other filesystem and VFS developers have said for the past 15 years "we don't need no stinking DIOINFO". The same people shot down adding optional IO alignment constraint f

Re: [f2fs-dev] [PATCH v4 3/7] iomap: support direct I/O with fscrypt using blk-crypto

2020-07-25 Thread Dave Chinner
On Fri, Jul 24, 2020 at 10:41:32AM -0700, Eric Biggers wrote: > On Fri, Jul 24, 2020 at 03:31:30PM +1000, Dave Chinner wrote: > > On Thu, Jul 23, 2020 at 08:46:28PM -0700, Eric Biggers wrote: > > > On Fri, Jul 24, 2020 at 11:39:10AM +1000,

Re: [f2fs-dev] [PATCH v4 3/7] iomap: support direct I/O with fscrypt using blk-crypto

2020-07-25 Thread Dave Chinner
On Sun, Jul 26, 2020 at 09:47:51AM +1000, Dave Chinner wrote: > On Fri, Jul 24, 2020 at 10:41:32AM -0700, Eric Biggers wrote: > > But again, as far as I can tell, fs/iomap/direct-io.c currently *does* > > guarantee > > that *if* the input is fully filesystem-block-ali

Re: [f2fs-dev] [PATCH v6 1/7] fscrypt: Add functions for direct I/O support

2020-07-26 Thread Dave Chinner
On Sat, Jul 25, 2020 at 07:49:20PM -0700, Eric Biggers wrote: > On Sat, Jul 25, 2020 at 10:14:41AM +1000, Dave Chinner wrote: > > > +bool fscrypt_dio_supported(struct kiocb *iocb, struct iov_iter *iter) > > > +{ > > > + const struct inode *inode = file_inode(iocb->

Re: [f2fs-dev] [PATCH v6 1/7] fscrypt: Add functions for direct I/O support

2020-07-26 Thread Dave Chinner
On Sun, Jul 26, 2020 at 07:59:46PM -0700, Eric Biggers wrote: > On Mon, Jul 27, 2020 at 10:58:48AM +1000, Dave Chinner wrote: > > On Sat, Jul 25, 2020 at 07:49:20PM -0700, Eric Biggers wrote: > > > On Sat, Jul 25, 2020 at 10:14:41AM +1000, Dave Chinner wrote: > > > >

Re: [f2fs-dev] [PATCH v2 04/12] fat: only specify I_DIRTY_TIME when needed in fat_update_time()

2021-01-11 Thread Dave Chinner
ourse, it will do if you crash or even just unmount/mount a filesystem that doesn't persist it. Cheers, Dave. -- Dave Chinner da...@fromorbit.com ___ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Re: [f2fs-dev] [PATCH 2/6] f2fs: support goingdown for fs shutdown

2015-01-08 Thread Dave Chinner
be it shouldn't share the > name at all. ;) The semantics are quite clear and generic - when you look at what they actually mean rather than looking at the implementation. There's no need for new ioctls here. Cheers, Dave. -- Dave Chinner da...@fromorbit.com -

Re: [f2fs-dev] [PATCH 2/6] f2fs: support goingdown for fs shutdown

2015-01-08 Thread Dave Chinner
On Thu, Jan 08, 2015 at 01:21:29PM -0800, Jaegeuk Kim wrote: > On Fri, Jan 09, 2015 at 07:54:16AM +1100, Dave Chinner wrote: > > On Thu, Jan 08, 2015 at 02:33:17PM -0600, Eric Sandeen wrote: > > > On 1/8/15 2:18 PM, Jaegeuk Kim wrote: > > > > On Thu, Jan 08, 2015 at

Re: [f2fs-dev] [PATCH 2/6 v2] f2fs: support goingdown for fs shutdown

2015-01-08 Thread Dave Chinner
te patch - the first patch in the series should add these definitions and define the XFS ioctl and flags to use them so we can clearly see there is no change of the existing user API. There's no need to change the XFS implementation at all. The second patch then adds the f2fs implementation.

Re: [f2fs-dev] [PATCH 1/2 v3] xfs/087: test f2fs selectively

2015-01-20 Thread Dave Chinner
" tests - with the correct "_requires_foo" rules we can just place those tests in generic/ and filesystems that don't support "foo" will avoid it. Cheers, Dave. -- Dave Chinner da...@fromorbit.com --

Re: [f2fs-dev] [PATCH 1/8 v4] common/rc: add _require_scratch_shtudown

2015-02-04 Thread Dave Chinner
gt; + || _notrun "$FSTYP does not support shutdown" Why verbose if you are redirecting all output to /dev/null? > + _scratch_unmount > +} Cheers, Dave. -- Dave Chinner da...@fromorbit.com -

Re: [f2fs-dev] [PATCH 2/8 v4] common/rc: add _require_bmap

2015-02-04 Thread Dave Chinner
ave. -- Dave Chinner da...@fromorbit.com -- Dive into the World of Parallel Programming. The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things paral

Re: [f2fs-dev] [PATCH 3/8 v4] common/rc: add _require_norecovery

2015-02-04 Thread Dave Chinner
ratch_mount -o ro,norecovery || \ > +_notrun "$FSTYP does not support norecovery" > + _scratch_unmount > +} What's the point of making tests that use an XFS specific mount option generic? If it requires this it is sti

Re: [f2fs-dev] [PATCH 4/8 v4] tests/xfs: convert 10 xfs's tests to be generic ones

2015-02-04 Thread Dave Chinner
ecovery vs ro-block device) > xfs/306 (fsstress vs recovery) > > All these tests need _require_scratch_shutdown, and some of them need > _require_bmap utils. > > Suggested-by: Dave Chinner > Signed-off-by: Jaegeuk Kim > --- > tests/xfs/053 | 3 ++- > tests/xfs/1

Re: [f2fs-dev] [PATCH 5/8 v4] tests/generic: relocate xfs's tests into tests/generic/

2015-02-04 Thread Dave Chinner
s_fs.h b/fs/xfs/libxfs/xfs_fs.h similarity index 100% rename from fs/xfs/xfs_fs.h rename to fs/xfs/libxfs/xfs_fs.h $ $ $ git diff --stat -M 97bf6af..2155355 fs/xfs/{ => libxfs}/xfs_fs.h | 0 1 file changed, 0 insertions(+), 0 deletions(-) $ It's much easier to revi

Re: [f2fs-dev] [PATCH 6/8 v4] common/rc: define dump.f2fs and logstate for f2fs

2015-02-04 Thread Dave Chinner
_notrun "This test requires dump.f2fs utility." > + fi > +} Actually, I'd make that _require_logstate() { case "$FSTYP" in xfs) if [ -z "$XFS_LOGPRINT_PROG" ]; then _notrun "This test requi

  1   2   3   >