[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0701121123410.2296@schroedinger.engr.sgi.com>
Date: Fri, 12 Jan 2007 11:25:02 -0800 (PST)
From: Christoph Lameter <clameter@....com>
To: akpm@...l.org
cc: Paul Jackson <pj@....com>, sander@...ilis.net,
linux-kernel@...r.kernel.org
Subject: Re: 'struct task_struct' has no member named 'mems_allowed' (was:
Re: 2.6.20-rc4-mm1)
On Fri, 12 Jan 2007, Paul Jackson wrote:
> I'll leave the honors to Christoph (added to CC), since this is his patch.
Ok. Here it is
mems_allowed only exists if CONFIG_CPUSETS is set. So put an #ifdef around
it. Also move the masking of the nodes behind the error check (looks
better) and add a comment.
Signed-off-by: Christoph Lameter <clameter@....com>
Index: linux-2.6.20-rc4-mm1/mm/mempolicy.c
===================================================================
--- linux-2.6.20-rc4-mm1.orig/mm/mempolicy.c 2007-01-12 13:20:17.000000000 -0600
+++ linux-2.6.20-rc4-mm1/mm/mempolicy.c 2007-01-12 13:21:30.220968608 -0600
@@ -882,9 +882,12 @@ asmlinkage long sys_mbind(unsigned long
int err;
err = get_nodes(&nodes, nmask, maxnode);
- nodes_and(nodes, nodes, current->mems_allowed);
if (err)
return err;
+#ifdef CONFIG_CPUSETS
+ /* Restrict the nodes to the allowed nodes in the cpuset */
+ nodes_and(nodes, nodes, current->mems_allowed);
+#endif
return do_mbind(start, len, mode, &nodes, flags);
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists