From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f72.google.com (mail-wm0-f72.google.com [74.125.82.72]) by kanga.kvack.org (Postfix) with ESMTP id C59C66B0008 for ; Tue, 26 Jun 2018 14:01:07 -0400 (EDT) Received: by mail-wm0-f72.google.com with SMTP id q12-v6so1217537wmf.9 for ; Tue, 26 Jun 2018 11:01:07 -0700 (PDT) Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id f1-v6sor1086953wrp.72.2018.06.26.11.01.06 for (Google Transport Security); Tue, 26 Jun 2018 11:01:06 -0700 (PDT) MIME-Version: 1.0 References: <20180625230659.139822-1-shakeelb@google.com> <20180625230659.139822-2-shakeelb@google.com> In-Reply-To: From: Shakeel Butt Date: Tue, 26 Jun 2018 11:00:53 -0700 Message-ID: Subject: Re: [PATCH 1/2] fs: fsnotify: account fsnotify metadata to kmemcg Content-Type: text/plain; charset="UTF-8" Sender: owner-linux-mm@kvack.org List-ID: To: Amir Goldstein Cc: Andrew Morton , Michal Hocko , Johannes Weiner , Vladimir Davydov , Jan Kara , Greg Thelen , Roman Gushchin , Alexander Viro , LKML , Cgroups , linux-fsdevel , Linux MM , Jan Kara On Mon, Jun 25, 2018 at 10:49 PM Amir Goldstein wrote: > ... > > The verb 'unuse' takes an argument memcg and 'uses' it - too weird. > You can use 'override'/'revert' verbs like override_creds or just call > memalloc_use_memcg(old_memcg) since there is no reference taken > anyway in use_memcg and no reference released in unuse_memcg. > > Otherwise looks good to me. > Thanks for your feedback. Just using memalloc_use_memcg(old_memcg) and ignoring the return seems more simple. I will wait for feedback from other before changing anything. thanks, Shakeel