Re: [PATCH V2] fuse: Remove __GFP_FS flag to avoid allocator recursing

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

 



On 2020-09-16 20:26, Matthew Wilcox wrote:
On Wed, Sep 16, 2020 at 12:09:40PM +0530, Pradeep P V K wrote:
Changes since V1:
- Used memalloc_nofs_save() in all allocation paths of fuse daemons
  to avoid use __GFP_FS flag as per Matthew comments.

That's not how to use memalloc_nofs_save(). You call it when entering a context in which any memory allocation would cause a deadlock. You don't look for every place which allocates memory and wrap the memory allocation
calls in memalloc_nofs_save() because you're likely to miss one.

ok, i will fix this in my next patch set.
 static ssize_t fuse_dev_read(struct kiocb *iocb, struct iov_iter *to)
 {
+	ssize_t size;
+	unsigned nofs_flag;

This is almost certainly too low in the call stack.
ok, i will update this in my next patch set.



[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