Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 105913
b: refs/heads/master
c: f9b4fb8
h: refs/heads/master
i:
  105911: 84594ab
v: v3
  • Loading branch information
Miao Xie authored and Linus Torvalds committed Jul 25, 2008
1 parent 7c0ec92 commit ad8458c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0b2f630a28d53b5a2082a5275bc3334b10373508
refs/heads/master: f9b4fb8dabf38fb456c97f01aace07cb6e7c1723
7 changes: 7 additions & 0 deletions trunk/kernel/cpuset.c
Original file line number Diff line number Diff line change
Expand Up @@ -1851,6 +1851,7 @@ static void scan_for_empty_cpusets(const struct cpuset *root)
struct cpuset *child; /* scans child cpusets of cp */
struct list_head queue;
struct cgroup *cont;
nodemask_t oldmems;

INIT_LIST_HEAD(&queue);

Expand All @@ -1870,6 +1871,8 @@ static void scan_for_empty_cpusets(const struct cpuset *root)
nodes_subset(cp->mems_allowed, node_states[N_HIGH_MEMORY]))
continue;

oldmems = cp->mems_allowed;

/* Remove offline cpus and mems from this cpuset. */
mutex_lock(&callback_mutex);
cpus_and(cp->cpus_allowed, cp->cpus_allowed, cpu_online_map);
Expand All @@ -1881,6 +1884,10 @@ static void scan_for_empty_cpusets(const struct cpuset *root)
if (cpus_empty(cp->cpus_allowed) ||
nodes_empty(cp->mems_allowed))
remove_tasks_in_empty_cpuset(cp);
else {
update_tasks_cpumask(cp);
update_tasks_nodemask(cp, &oldmems);
}
}
}

Expand Down

0 comments on commit ad8458c

Please sign in to comment.