diff options
author | KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> | 2006-03-28 04:56:37 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-28 12:16:05 -0500 |
commit | 0a945022778f100115d0cb6234eb28fc1b15ccaf (patch) | |
tree | 85df4b5f7dd8bf59557091379c59b23b09115bf6 /kernel/sched.c | |
parent | 631d6747e1d877a4baa924cb373b8b9511a53e5e (diff) |
[PATCH] for_each_possible_cpu: fixes for generic part
replaces for_each_cpu with for_each_possible_cpu().
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'kernel/sched.c')
-rw-r--r-- | kernel/sched.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index 7854ee516b92..a9ecac398bb9 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -1625,7 +1625,7 @@ unsigned long nr_uninterruptible(void) | |||
1625 | { | 1625 | { |
1626 | unsigned long i, sum = 0; | 1626 | unsigned long i, sum = 0; |
1627 | 1627 | ||
1628 | for_each_cpu(i) | 1628 | for_each_possible_cpu(i) |
1629 | sum += cpu_rq(i)->nr_uninterruptible; | 1629 | sum += cpu_rq(i)->nr_uninterruptible; |
1630 | 1630 | ||
1631 | /* | 1631 | /* |
@@ -1642,7 +1642,7 @@ unsigned long long nr_context_switches(void) | |||
1642 | { | 1642 | { |
1643 | unsigned long long i, sum = 0; | 1643 | unsigned long long i, sum = 0; |
1644 | 1644 | ||
1645 | for_each_cpu(i) | 1645 | for_each_possible_cpu(i) |
1646 | sum += cpu_rq(i)->nr_switches; | 1646 | sum += cpu_rq(i)->nr_switches; |
1647 | 1647 | ||
1648 | return sum; | 1648 | return sum; |
@@ -1652,7 +1652,7 @@ unsigned long nr_iowait(void) | |||
1652 | { | 1652 | { |
1653 | unsigned long i, sum = 0; | 1653 | unsigned long i, sum = 0; |
1654 | 1654 | ||
1655 | for_each_cpu(i) | 1655 | for_each_possible_cpu(i) |
1656 | sum += atomic_read(&cpu_rq(i)->nr_iowait); | 1656 | sum += atomic_read(&cpu_rq(i)->nr_iowait); |
1657 | 1657 | ||
1658 | return sum; | 1658 | return sum; |
@@ -6080,7 +6080,7 @@ void __init sched_init(void) | |||
6080 | runqueue_t *rq; | 6080 | runqueue_t *rq; |
6081 | int i, j, k; | 6081 | int i, j, k; |
6082 | 6082 | ||
6083 | for_each_cpu(i) { | 6083 | for_each_possible_cpu(i) { |
6084 | prio_array_t *array; | 6084 | prio_array_t *array; |
6085 | 6085 | ||
6086 | rq = cpu_rq(i); | 6086 | rq = cpu_rq(i); |