Re: [PATCH v2 1/5] mm: memcontrol: generalize locking for the page->mem_cgroup binding

From: Vladimir Davydov
Date: Tue Feb 02 2016 - 09:18:49 EST


On Fri, Jan 29, 2016 at 12:54:03PM -0500, Johannes Weiner wrote:
> So far the only sites that needed to exclude charge migration to
> stabilize page->mem_cgroup have been per-cgroup page statistics, hence
> the name mem_cgroup_begin_page_stat(). But per-cgroup thrash detection
> will add another site that needs to ensure page->mem_cgroup lifetime.
>
> Rename these locking functions to the more generic lock_page_memcg()
> and unlock_page_memcg(). Since charge migration is a cgroup1 feature
> only, we might be able to delete it at some point, and these now easy
> to identify locking sites along with it.
>
> Suggested-by: Vladimir Davydov <vdavydov@xxxxxxxxxxxxx>
> Signed-off-by: Johannes Weiner <hannes@xxxxxxxxxxx>

Acked-by: Vladimir Davydov <vdavydov@xxxxxxxxxxxxx>