lkml.org 
[lkml]   [2021]   [Jan]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mm/filemap: Adding missing mem_cgroup_uncharge() to __add_to_page_cache_locked()
On Mon 25-01-21 13:23:58, Waiman Long wrote:
> On 1/25/21 1:14 PM, Michal Hocko wrote:
[...]
> > With the proposed simplification by Willy
> > Acked-by: Michal Hocko <mhocko@suse.com>
>
> Thank for the ack. However, I am a bit confused about what you mean by
> simplification. There is another linux-next patch that changes the condition
> for mem_cgroup_charge() to

This is obviously a fix and I believe should go in the next rc while
secretmem is a new feature which should wait at least to the next merge
window.

> -       if (!huge) {
> +       if (!huge && !page_is_secretmem(page)) {
>                 error = mem_cgroup_charge(page, current->mm, gfp);
>
> That is the main reason why I introduced the boolean variable as I don't
> want to call the external page_is_secretmem() function twice.
>
> Cheers,
> Longman
>

--
Michal Hocko
SUSE Labs

\
 
 \ /
  Last update: 2021-01-25 19:34    [W:0.181 / U:0.888 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site