[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJD7tkaAKPLCrZmZc0FDHj3s40rbZ5gp5gGpQEtiRvsE6vdWPg@mail.gmail.com>
Date: Sat, 23 Apr 2022 14:44:20 -0700
From: Yosry Ahmed <yosryahmed@...gle.com>
To: Shakeel Butt <shakeelb@...gle.com>
Cc: Johannes Weiner <hannes@...xchg.org>,
Michal Hocko <mhocko@...nel.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Roman Gushchin <roman.gushchin@...ux.dev>,
David Rientjes <rientjes@...gle.com>,
Tejun Heo <tj@...nel.org>, Zefan Li <lizefan.x@...edance.com>,
Jonathan Corbet <corbet@....net>,
Shuah Khan <shuah@...nel.org>, Yu Zhao <yuzhao@...gle.com>,
Dave Hansen <dave.hansen@...ux.intel.com>,
Wei Xu <weixugc@...gle.com>, Greg Thelen <gthelen@...gle.com>,
Chen Wandun <chenwandun@...wei.com>,
Vaibhav Jain <vaibhav@...ux.ibm.com>,
Michal Koutný <mkoutny@...e.com>,
Tim Chen <tim.c.chen@...ux.intel.com>,
Dan Schatzberg <schatzberg.dan@...il.com>,
cgroups@...r.kernel.org, linux-doc@...r.kernel.org,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Linux-MM <linux-mm@...ck.org>, linux-kselftest@...r.kernel.org,
Michal Hocko <mhocko@...e.com>
Subject: Re: [PATCH v4 1/4] memcg: introduce per-memcg reclaim interface
On Sat, Apr 23, 2022 at 6:30 AM Shakeel Butt <shakeelb@...gle.com> wrote:
>
> On Thu, Apr 21, 2022 at 11:44:23PM +0000, Yosry Ahmed wrote:
> > From: Shakeel Butt <shakeelb@...gle.com>
> [...]
> >
> > [yosryahmed@...gle.com: refreshed to current master, updated commit
> > message based on recent discussions and use cases]
> > Signed-off-by: Shakeel Butt <shakeelb@...gle.com>
> > Signed-off-by: Yosry Ahmed <yosryahmed@...gle.com>
>
> You should add "Co-developed-by" tag for yourself here.
>
> > Acked-by: Johannes Weiner <hannes@...xchg.org>
> > Acked-by: Michal Hocko <mhocko@...e.com>
> > Acked-by: Wei Xu <weixugc@...gle.com>
> > Acked-by: Roman Gushchin <roman.gushchin@...ux.dev>
> > ---
> >
> [...]
> > +static ssize_t memory_reclaim(struct kernfs_open_file *of, char *buf,
> > + size_t nbytes, loff_t off)
> > +{
> > + struct mem_cgroup *memcg = mem_cgroup_from_css(of_css(of));
> > + unsigned int nr_retries = MAX_RECLAIM_RETRIES;
> > + unsigned long nr_to_reclaim, nr_reclaimed = 0;
> > + int err;
> > +
> > + buf = strstrip(buf);
> > + err = page_counter_memparse(buf, "", &nr_to_reclaim);
> > + if (err)
> > + return err;
> > +
> > + while (nr_reclaimed < nr_to_reclaim) {
> > + unsigned long reclaimed;
> > +
> > + if (signal_pending(current))
> > + return -EINTR;
> > +
> > + /* This is the final attempt, drain percpu lru caches in the
>
> Fix the comment format. "/*" should be on its own line.
>
> > + * hope of introducing more evictable pages for
> > + * try_to_free_mem_cgroup_pages().
> > + */
>
> No need to send a new version if Andrew can fix these in the mm tree.
I will be sending v5 anyway to address your review comments on the
last patch. I will fix these as well. Thanks!
Powered by blists - more mailing lists