[2.6 patch] kernel/cpuset.c: cleanups

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patch contains the following cleanups:
- make the following needlessly global functions static:
  - cpuset_can_attach()
  - cpuset_attach()
  - cpuset_populate()
  - cpuset_post_clone()
  - cpuset_create()
  - cpuset_destroy()
- remove the unused EXPORT_SYMBOL_GPL(cpuset_mem_spread_node)

Signed-off-by: Adrian Bunk <[email protected]>

---

 kernel/cpuset.c |   21 ++++++++++-----------
 1 file changed, 10 insertions(+), 11 deletions(-)

--- linux-2.6.22-rc6-mm1/kernel/cpuset.c.old	2007-07-03 15:40:33.000000000 +0200
+++ linux-2.6.22-rc6-mm1/kernel/cpuset.c	2007-07-04 23:32:06.000000000 +0200
@@ -873,8 +873,8 @@
 	return val;
 }
 
-int cpuset_can_attach(struct container_subsys *ss,
-		      struct container *cont, struct task_struct *tsk)
+static int cpuset_can_attach(struct container_subsys *ss,
+			     struct container *cont, struct task_struct *tsk)
 {
 	struct cpuset *cs = container_cs(cont);
 
@@ -884,9 +884,9 @@
 	return security_task_setscheduler(tsk, 0, NULL);
 }
 
-void cpuset_attach(struct container_subsys *ss,
-		   struct container *cont, struct container *oldcont,
-		   struct task_struct *tsk)
+static void cpuset_attach(struct container_subsys *ss,
+			  struct container *cont, struct container *oldcont,
+			  struct task_struct *tsk)
 {
 	cpumask_t cpus;
 	nodemask_t from, to;
@@ -1163,7 +1163,7 @@
 	.private = FILE_SPREAD_SLAB,
 };
 
-int cpuset_populate(struct container_subsys *ss, struct container *cont)
+static int cpuset_populate(struct container_subsys *ss, struct container *cont)
 {
 	int err;
 
@@ -1205,8 +1205,8 @@
  * changed to grant parent->cpus_allowed-sibling_cpus_exclusive
  * (and likewise for mems) to the new container.
  */
-void cpuset_post_clone(struct container_subsys *ss,
-		struct container *container)
+static void cpuset_post_clone(struct container_subsys *ss,
+			      struct container *container)
 {
 	struct container *parent, *child;
 	struct cpuset *cs, *parent_cs;
@@ -1234,7 +1234,7 @@
  *	Must be called with the mutex on the parent inode held
  */
 
-int cpuset_create(struct container_subsys *ss, struct container *cont)
+static int cpuset_create(struct container_subsys *ss, struct container *cont)
 {
 	struct cpuset *cs;
 	struct cpuset *parent;
@@ -1269,7 +1269,7 @@
 	return 0;
 }
 
-void cpuset_destroy(struct container_subsys *ss, struct container *cont)
+static void cpuset_destroy(struct container_subsys *ss, struct container *cont)
 {
 	struct cpuset *cs = container_cs(cont);
 
@@ -1726,7 +1726,6 @@
 	current->cpuset_mem_spread_rotor = node;
 	return node;
 }
-EXPORT_SYMBOL_GPL(cpuset_mem_spread_node);
 
 /**
  * cpuset_excl_nodes_overlap - Do we overlap @p's mem_exclusive ancestors?

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux