From: akpm@linux-foundation.org
To: lizf@cn.fujitsu.com, menage@google.com, miaox@cn.fujitsu.com,
rientjes@google.com, mm-commits@vger.kernel.org
Subject: [merged] cpuset-remove-unneeded-nodemask_alloc-in-cpuset_attch.patch removed from -mm tree
Date: Fri, 25 Mar 2011 00:25:27 -0700 [thread overview]
Message-ID: <201103250725.p2P7PLZB026014@imap1.linux-foundation.org> (raw)
The patch titled
cpuset: remove unneeded NODEMASK_ALLOC() in cpuset_attach()
has been removed from the -mm tree. Its filename was
cpuset-remove-unneeded-nodemask_alloc-in-cpuset_attch.patch
This patch was dropped because it was merged into mainline or a subsystem tree
The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/
------------------------------------------------------
Subject: cpuset: remove unneeded NODEMASK_ALLOC() in cpuset_attach()
From: Li Zefan <lizf@cn.fujitsu.com>
oldcs->mems_allowed is not modified during cpuset_attach(), so we don't
have to copy it to a buffer allocated by NODEMASK_ALLOC(). Just pass it
to cpuset_migrate_mm().
Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: Paul Menage <menage@google.com>
Acked-by: David Rientjes <rientjes@google.com>
Cc: Miao Xie <miaox@cn.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
kernel/cpuset.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff -puN kernel/cpuset.c~cpuset-remove-unneeded-nodemask_alloc-in-cpuset_attch kernel/cpuset.c
--- a/kernel/cpuset.c~cpuset-remove-unneeded-nodemask_alloc-in-cpuset_attch
+++ a/kernel/cpuset.c
@@ -1438,10 +1438,9 @@ static void cpuset_attach(struct cgroup_
struct mm_struct *mm;
struct cpuset *cs = cgroup_cs(cont);
struct cpuset *oldcs = cgroup_cs(oldcont);
- NODEMASK_ALLOC(nodemask_t, from, GFP_KERNEL);
NODEMASK_ALLOC(nodemask_t, to, GFP_KERNEL);
- if (from == NULL || to == NULL)
+ if (to == NULL)
goto alloc_fail;
if (cs == &top_cpuset) {
@@ -1463,18 +1462,16 @@ static void cpuset_attach(struct cgroup_
}
/* change mm; only needs to be done once even if threadgroup */
- *from = oldcs->mems_allowed;
*to = cs->mems_allowed;
mm = get_task_mm(tsk);
if (mm) {
mpol_rebind_mm(mm, to);
if (is_memory_migrate(cs))
- cpuset_migrate_mm(mm, from, to);
+ cpuset_migrate_mm(mm, &oldcs->mems_allowed, to);
mmput(mm);
}
alloc_fail:
- NODEMASK_FREE(from);
NODEMASK_FREE(to);
}
_
Patches currently in -mm which might be from lizf@cn.fujitsu.com are
origin.patch
cgroup-remove-the-ns_cgroup.patch
reply other threads:[~2011-03-25 7:25 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=201103250725.p2P7PLZB026014@imap1.linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lizf@cn.fujitsu.com \
--cc=menage@google.com \
--cc=miaox@cn.fujitsu.com \
--cc=mm-commits@vger.kernel.org \
--cc=rientjes@google.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.