Re: page split failures in truncate_inode_pages_range

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 23, 2021 at 07:51:18PM +0100, Matthew Wilcox wrote:
> But truncate_inode_pages_range() is also called by, for example,
> truncate().  In that case, nobody calls filemap_write_and_wait_range(),
> so we can't discard the page because it might still be dirty.
> Is that an acceptable way to choose behaviour -- if the split fails,
> discard the page if it's clean and keep it if it's dirty?  I'll
> put a great big comment on it, because it's not entirely obvious.

It seems to be working ...

        if (!folio_multi(folio))
                return true;
//      if (split_huge_page(&folio->page) == 0)
//              return true;
        if (folio_dirty(folio))
                return false;
        truncate_inode_folio(mapping, folio);
        return true;

No additional xfstests failures from commenting out those two lines.



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux