Re: [PATCH v2] iomap: avoid deadlock if memory reclaim is triggered in writepage path

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

 



On Tue, Jun 9, 2020 at 10:32 PM Christoph Hellwig <hch@xxxxxxxxxxxxx> wrote:
>
> On Tue, Jun 09, 2020 at 10:28:06PM +0800, Yafang Shao wrote:
> > On Tue, Jun 9, 2020 at 10:03 PM Christoph Hellwig <hch@xxxxxxxxxxxxx> wrote:
> > >
> > > On Thu, Jun 04, 2020 at 03:05:47AM -0400, Yafang Shao wrote:
> > > > Recently there is a XFS deadlock on our server with an old kernel.
> > > > This deadlock is caused by allocating memory in xfs_map_blocks() while
> > > > doing writeback on behalf of memroy reclaim. Although this deadlock happens
> > > > on an old kernel, I think it could happen on the upstream as well. This
> > > > issue only happens once and can't be reproduced, so I haven't tried to
> > > > reproduce it on upsteam kernel.
> > >
> > > The report looks sensible, but I don't think the iomap code is the
> > > right place for this.  Until/unless the VM people agree that
> > > ->writepages(s) generally should not recurse into the fs I think the
> > > low-level file system allocating is the right place, so xfs_map_blocks
> > > would seem like the correct place.
> >
> > Thanks for your comment.
> > That is what I did in the previous version [1].
> > So should I resend the v1 ?
>
> Well, v1 won't apply.  But I do prefer the approach there.

All right. Let's include MM maintainers and see the opinion from them.

Hi Michal, Andrew,

What's your opinion on this XFS deadlock ?
Should ->writepages(s) generally not recurse into the fs ?


-- 
Thanks
Yafang



[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