Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-15 Thread Michal Hocko
On Sat 14-01-17 21:42:48, David Rientjes wrote: > On Sat, 14 Jan 2017, Johannes Weiner wrote: > > > The OOM killer livelock was the motivation for this patch. With that > > ruled out, what's the point of this patch? Try a bit less hard to move > > charges during task migration? > > > > Most

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-15 Thread Michal Hocko
On Sat 14-01-17 21:42:48, David Rientjes wrote: > On Sat, 14 Jan 2017, Johannes Weiner wrote: > > > The OOM killer livelock was the motivation for this patch. With that > > ruled out, what's the point of this patch? Try a bit less hard to move > > charges during task migration? > > > > Most

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-15 Thread Johannes Weiner
On Sat, Jan 14, 2017 at 09:42:48PM -0800, David Rientjes wrote: > On Sat, 14 Jan 2017, Johannes Weiner wrote: > > > The OOM killer livelock was the motivation for this patch. With that > > ruled out, what's the point of this patch? Try a bit less hard to move > > charges during task migration? >

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-15 Thread Johannes Weiner
On Sat, Jan 14, 2017 at 09:42:48PM -0800, David Rientjes wrote: > On Sat, 14 Jan 2017, Johannes Weiner wrote: > > > The OOM killer livelock was the motivation for this patch. With that > > ruled out, what's the point of this patch? Try a bit less hard to move > > charges during task migration? >

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-14 Thread David Rientjes
On Sat, 14 Jan 2017, Johannes Weiner wrote: > The OOM killer livelock was the motivation for this patch. With that > ruled out, what's the point of this patch? Try a bit less hard to move > charges during task migration? > Most important part is to fail ->can_attach() instead of oom killing

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-14 Thread David Rientjes
On Sat, 14 Jan 2017, Johannes Weiner wrote: > The OOM killer livelock was the motivation for this patch. With that > ruled out, what's the point of this patch? Try a bit less hard to move > charges during task migration? > Most important part is to fail ->can_attach() instead of oom killing

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-14 Thread Johannes Weiner
On Fri, Jan 13, 2017 at 02:09:53AM -0800, David Rientjes wrote: > When memory.move_charge_at_immigrate is enabled and precharges are > depleted during move, mem_cgroup_move_charge_pte_range() will attempt to > increase the size of the precharge. > > Prevent precharges from ever looping by setting

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-14 Thread Johannes Weiner
On Fri, Jan 13, 2017 at 02:09:53AM -0800, David Rientjes wrote: > When memory.move_charge_at_immigrate is enabled and precharges are > depleted during move, mem_cgroup_move_charge_pte_range() will attempt to > increase the size of the precharge. > > Prevent precharges from ever looping by setting

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-13 Thread David Rientjes
When memory.move_charge_at_immigrate is enabled and precharges are depleted during move, mem_cgroup_move_charge_pte_range() will attempt to increase the size of the precharge. Prevent precharges from ever looping by setting __GFP_NORETRY. This was probably the intention of the GFP_KERNEL &

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-13 Thread David Rientjes
When memory.move_charge_at_immigrate is enabled and precharges are depleted during move, mem_cgroup_move_charge_pte_range() will attempt to increase the size of the precharge. Prevent precharges from ever looping by setting __GFP_NORETRY. This was probably the intention of the GFP_KERNEL &

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-13 Thread Michal Hocko
On Thu 12-01-17 14:46:34, David Rientjes wrote: > When memory.move_charge_at_immigrate is enabled and precharges are > depleted during move, mem_cgroup_move_charge_pte_range() will attempt to > increase the size of the precharge. > > This can be allowed to do reclaim, but should not call the oom

Re: [patch v2] mm, memcg: do not retry precharge charges

2017-01-13 Thread Michal Hocko
On Thu 12-01-17 14:46:34, David Rientjes wrote: > When memory.move_charge_at_immigrate is enabled and precharges are > depleted during move, mem_cgroup_move_charge_pte_range() will attempt to > increase the size of the precharge. > > This can be allowed to do reclaim, but should not call the oom

[patch v2] mm, memcg: do not retry precharge charges

2017-01-12 Thread David Rientjes
When memory.move_charge_at_immigrate is enabled and precharges are depleted during move, mem_cgroup_move_charge_pte_range() will attempt to increase the size of the precharge. This can be allowed to do reclaim, but should not call the oom killer to oom kill a process. It's better to fail the

[patch v2] mm, memcg: do not retry precharge charges

2017-01-12 Thread David Rientjes
When memory.move_charge_at_immigrate is enabled and precharges are depleted during move, mem_cgroup_move_charge_pte_range() will attempt to increase the size of the precharge. This can be allowed to do reclaim, but should not call the oom killer to oom kill a process. It's better to fail the