Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-04 Thread Junxiao Bi
On 09/05/2014 10:32 AM, Junxiao Bi wrote: > On 09/04/2014 05:23 PM, Dave Chinner wrote: >> On Wed, Sep 03, 2014 at 01:54:54PM +0800, Junxiao Bi wrote: >>> commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O >>> during memory allocation") >>> introduces PF_MEMALLOC_NOIO flag to

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-04 Thread Junxiao Bi
On 09/04/2014 05:23 PM, Dave Chinner wrote: > On Wed, Sep 03, 2014 at 01:54:54PM +0800, Junxiao Bi wrote: >> commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O >> during memory allocation") >> introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memory >> allocation, _

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-04 Thread Dave Chinner
On Wed, Sep 03, 2014 at 07:30:58PM -0700, Andrew Morton wrote: > > PF_MEMALLOC_NOIO is only set for some special processes. I think it > > won't affect much. > > Maybe not now. But once we add hacks like this, people say "goody" and > go and use them rather than exerting the effort to sort out th

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-04 Thread Dave Chinner
On Wed, Sep 03, 2014 at 01:54:54PM +0800, Junxiao Bi wrote: > commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O > during memory allocation") > introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memory allocation, > __GFP_IO is cleared > when this flag is set, but __

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-04 Thread Dave Chinner
On Wed, Sep 03, 2014 at 04:10:00PM -0700, Andrew Morton wrote: > On Wed, 3 Sep 2014 13:54:54 +0800 Junxiao Bi wrote: > > > commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O > > during memory allocation") > > introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memor

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-04 Thread Anton Altaparmakov
On 4 Sep 2014, at 03:30, Andrew Morton wrote: > __GFP_FS and __GFP_IO are (or were) for communicating to vmscan: don't > enter the fs for writepage, don't write back swapcache. > > I guess those concepts have grown over time without a ton of thought > going into it. Yes, I suppose that if a file

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-03 Thread Junxiao Bi
On 09/04/2014 10:30 AM, Andrew Morton wrote: > On Thu, 04 Sep 2014 10:08:09 +0800 Junxiao Bi wrote: > >> On 09/04/2014 07:10 AM, Andrew Morton wrote: >>> On Wed, 3 Sep 2014 13:54:54 +0800 Junxiao Bi wrote: >>> commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O d

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-03 Thread Andrew Morton
On Thu, 04 Sep 2014 10:08:09 +0800 Junxiao Bi wrote: > On 09/04/2014 07:10 AM, Andrew Morton wrote: > > On Wed, 3 Sep 2014 13:54:54 +0800 Junxiao Bi wrote: > > > >> commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O > >> during memory allocation") > >> introduces PF_MEMA

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-03 Thread Junxiao Bi
On 09/03/2014 08:20 PM, Trond Myklebust wrote: > On Wed, Sep 3, 2014 at 1:54 AM, Junxiao Bi wrote: >> commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O >> during memory allocation") >> introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memory >> allocation, __GFP_I

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-03 Thread Junxiao Bi
On 09/04/2014 07:10 AM, Andrew Morton wrote: > On Wed, 3 Sep 2014 13:54:54 +0800 Junxiao Bi wrote: > >> commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O >> during memory allocation") >> introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memory >> allocation, __G

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-03 Thread Andrew Morton
On Wed, 3 Sep 2014 13:54:54 +0800 Junxiao Bi wrote: > commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O > during memory allocation") > introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memory allocation, > __GFP_IO is cleared > when this flag is set, but __GFP_F

Re: [PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-03 Thread Trond Myklebust
On Wed, Sep 3, 2014 at 1:54 AM, Junxiao Bi wrote: > commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O > during memory allocation") > introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memory allocation, > __GFP_IO is cleared > when this flag is set, but __GFP_FS im

[PATCH] mm: clear __GFP_FS when PF_MEMALLOC_NOIO is set

2014-09-02 Thread Junxiao Bi
commit 21caf2fc1931 ("mm: teach mm by current context info to not do I/O during memory allocation") introduces PF_MEMALLOC_NOIO flag to avoid doing I/O inside memory allocation, __GFP_IO is cleared when this flag is set, but __GFP_FS implies __GFP_IO, it should also be cleared. Or it may still r