Re: [PATCH] iomap: Do not use GFP_NORETRY to allocate BIOs

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

 



On Mon, Mar 23, 2020 at 08:10:54AM -0700, Matthew Wilcox wrote:
> > That looks silly to me.  This just means we'll keep iterating over
> > small bios for readahead..  Either we just ignore the different gfp
> > mask, or we need to go all the way and handle errors, although that
> > doesn't really look nice.
> 
> I'm not sure it's silly,

Oh well, I'm not going to be in the way of fixing a bug I added.  So
feel free to go ahead with this and mention it matches mpage_readpages.

> although I'd love to see bio_alloc() support
> nr_iovecs == 0 meaning "allocate me any size biovec and tell me what
> size I got in ->bi_max_vecs".  By allocating a small biovec this time,
> we do one allocation rather than two, and maybe by the time we come to
> allocate the next readahead bio, kswapd will have succeeded in freeing
> up more memory for us.

Sounds easy enough - especially as callers don't need to look at
bi_max_vecs anyway, that is the job of bio_add_page and friends.  That
being said an upper bound still sounds useful - no need to allocate
a a gigantic bio if we know we only need a few pages.



[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