Messages in this thread | | | Date | Tue, 2 Mar 2021 16:42:16 +0100 | From | Michal Hocko <> | Subject | Re: [PATCH] mm/memcg: set memcg when split pages |
| |
On Tue 02-03-21 10:37:13, Zi Yan wrote: [...] > I have a question on copy_page_memcg above. By reading __memcg_kmem_charge_page > and __memcg_kmem_uncharge_page, it seems to me that every single page requires > a css_get(&memcg->css) at charge time and a css_put(&memcg->css) at uncharge time. > But your copy_page_memcg does not do css_get for split subpages. Will it cause > memcg->css underflow when subpages are uncharged?
yes, well spotted. I have completely missed that. This will also discard my comment on testing the memcg.
-- Michal Hocko SUSE Labs
| |