From: Hugh Dickins <hughd@google.com>
To: Oleg Nesterov <oleg@redhat.com>
Cc: Kelley Nielsen <kelleynnn@gmail.com>, Pavel Machek <pavel@ucw.cz>,
Andrew Morton <akpm@linux-foundation.org>,
Peter Chiang <pchiang@nvidia.com>,
KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>,
Balbir Singh <bsingharora@gmail.com>,
Michal Hocko <mhocko@suse.cz>,
Johannes Weiner <hannes@cmpxchg.org>,
"ccross@android.com" <ccross@android.com>,
"lizefan@huawei.com" <lizefan@huawei.com>,
"tj@kernel.org" <tj@kernel.org>,
"ebiederm@xmission.com" <ebiederm@xmission.com>,
"guillaume@morinfr.org" <guillaume@morinfr.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 0/2] memcg: mm_update_next_owner() should skip kthreads
Date: Sat, 19 Apr 2014 14:23:38 -0700 (PDT) [thread overview]
Message-ID: <alpine.LSU.2.11.1404191404510.15123@eggly.anvils> (raw)
In-Reply-To: <20140419181407.GB982@redhat.com>
On Sat, 19 Apr 2014, Oleg Nesterov wrote:
> On 04/19, Pavel Machek wrote:
> >
> > > > Hmm. I seem to see a bug in this function, it can be fulled by use_mm,
> > > > but I am not sure this can explain the problem. I'll send a patch.
> > >
> > > Untested, please review. But it really looks "obviously wrong", and note
> > > that unuse_mm() doesn't do mm_update_next_owner(). (just in case, do not
> > > confuse it with unuse_mm() in mm/swapfile.c).
> >
> > Having two functions, one exported, one static with same name -- that
> > sounds quite evil, right?
>
> Yes, agreed.
Doubly agreed; though it seems to have escaped causing confusion
for several years, so no great hurry to resolve it.
>
> > mmu_context.c: * unuse_mm
> > mmu_context.c:void unuse_mm(struct mm_struct *mm)
> > mmu_context.c:EXPORT_SYMBOL_GPL(unuse_mm);
> > swapfile.c:static int unuse_mm(struct mm_struct *mm,
>
> Yes, I was thinking about s/unuse_mm/unswap_mm/ change in swapfile.c,
> but then we should probaly rename other "unuse" functions there, and
> shmem_unuse/try_to_unuse are not static.
My preference is "swapoff" instead of "unuse" throughout there:
it saves having to explain that "unuse" implies "swapoff" each
time we send in a patch making a change to that code.
But I'd prefer you hold off for the moment: Kelley Nielsen is currently
preparing a patchset reworking try_to_unuse, and I suggested a few days
ago to include such renaming in that patchset.
Partly driven by s390's recent 45961722f8e3 "mm: add support for
discard of unused ptes" which adds further confusion with pte_unused().
Hugh
prev parent reply other threads:[~2014-04-19 21:25 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-16 3:02 [PATCH] mm : Avoid candidate task is equal to current task Peter Chiang
2014-04-16 12:31 ` Peter Chiang
2014-04-16 12:52 ` Peter Chiang
2014-04-16 13:57 ` Oleg Nesterov
2014-04-17 6:48 ` Peter Chiang
2014-04-18 16:23 ` Oleg Nesterov
2014-04-18 17:26 ` [PATCH 0/2] memcg: mm_update_next_owner() should skip kthreads Oleg Nesterov
2014-04-18 17:26 ` [PATCH 1/2] " Oleg Nesterov
2014-04-18 17:27 ` [PATCH 2/2] memcg: optimize the "Search everything else" loop in mm_update_next_owner() Oleg Nesterov
2014-04-18 18:24 ` [PATCH 0/2] memcg: mm_update_next_owner() should skip kthreads Michal Hocko
2014-04-18 18:44 ` Oleg Nesterov
2014-04-18 19:12 ` [PATCH 0/1] memcg: kill start_kernel()->mm_init_owner(init_mm) Oleg Nesterov
2014-04-18 19:13 ` [PATCH 1/1] " Oleg Nesterov
2014-04-22 13:34 ` Michal Hocko
2014-04-22 13:23 ` [PATCH 0/1] " Michal Hocko
2014-04-22 16:15 ` [PATCH 0/1] memcg: kill CONFIG_MM_OWNER Oleg Nesterov
2014-04-22 16:15 ` [PATCH 1/1] " Oleg Nesterov
2014-04-22 16:39 ` Johannes Weiner
2014-04-22 16:59 ` [PATCH 0/1] " Michal Hocko
2014-04-22 10:52 ` [PATCH 0/2] memcg: mm_update_next_owner() should skip kthreads Michal Hocko
2014-04-22 13:21 ` Michal Hocko
2014-04-22 21:35 ` Hugh Dickins
2014-04-23 7:04 ` Michal Hocko
2014-04-19 8:34 ` Pavel Machek
2014-04-19 18:14 ` Oleg Nesterov
2014-04-19 21:23 ` Hugh Dickins [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.LSU.2.11.1404191404510.15123@eggly.anvils \
--to=hughd@google.com \
--cc=akpm@linux-foundation.org \
--cc=bsingharora@gmail.com \
--cc=ccross@android.com \
--cc=ebiederm@xmission.com \
--cc=guillaume@morinfr.org \
--cc=hannes@cmpxchg.org \
--cc=kamezawa.hiroyu@jp.fujitsu.com \
--cc=kelleynnn@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lizefan@huawei.com \
--cc=mhocko@suse.cz \
--cc=oleg@redhat.com \
--cc=pavel@ucw.cz \
--cc=pchiang@nvidia.com \
--cc=tj@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®