lkml.org 
[lkml]   [2015]   [May]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] memcg: do not call reclaim if !__GFP_WAIT
On Thu 28-05-15 12:59:34, Andrew Morton wrote:
> On Thu, 28 May 2015 20:26:06 +0300 Vladimir Davydov <vdavydov@parallels.com> wrote:
>
> > When trimming memcg consumption excess (see memory.high), we call
> > try_to_free_mem_cgroup_pages without checking if we are allowed to sleep
> > in the current context, which can result in a deadlock. Fix this.
>
> Why does it deadlock? try_to_free_mem_cgroup_pages() is passed the
> gfp_mask and should honour its __GFP_WAIT setting?

The only instance of __GFP_WAIT check in vmscan code is in zone_reclaim.
Page allocations and memcg reclaim avoids calling reclaim if __GFP_WAIT
is not set. Maybe we can move the check to do_try_to_free_pages?

--
Michal Hocko
SUSE Labs


\
 
 \ /
  Last update: 2015-05-29 09:41    [W:0.037 / U:1.032 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site