diff options
author | Eric Sesterhenn <snakebyte@gmx.de> | 2006-03-06 16:48:40 -0500 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2006-03-20 04:14:19 -0500 |
commit | 9132983ae140a8ca81e95e081d5a4c0dd7a7f670 (patch) | |
tree | f3aec20b1bb5a2cc111bbbf6775a0f8d84d28994 /arch/sparc64/kernel/setup.c | |
parent | f7c00338cfeef125032aa12aa8ebeacf9e117e81 (diff) |
[SPARC64]: kzalloc() conversion
this patch converts arch/sparc64 to kzalloc usage.
Crosscompile tested with allyesconfig.
Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64/kernel/setup.c')
-rw-r--r-- | arch/sparc64/kernel/setup.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/arch/sparc64/kernel/setup.c b/arch/sparc64/kernel/setup.c index 0c68a76143af..2a2a8a6cd17d 100644 --- a/arch/sparc64/kernel/setup.c +++ b/arch/sparc64/kernel/setup.c | |||
@@ -536,15 +536,11 @@ static int __init topology_init(void) | |||
536 | while (!cpu_find_by_instance(ncpus_probed, NULL, NULL)) | 536 | while (!cpu_find_by_instance(ncpus_probed, NULL, NULL)) |
537 | ncpus_probed++; | 537 | ncpus_probed++; |
538 | 538 | ||
539 | for (i = 0; i < NR_CPUS; i++) { | 539 | for_each_cpu(i) { |
540 | if (cpu_possible(i)) { | 540 | struct cpu *p = kzalloc(sizeof(*p), GFP_KERNEL); |
541 | struct cpu *p = kmalloc(sizeof(*p), GFP_KERNEL); | 541 | if (p) { |
542 | 542 | register_cpu(p, i, NULL); | |
543 | if (p) { | 543 | err = 0; |
544 | memset(p, 0, sizeof(*p)); | ||
545 | register_cpu(p, i, NULL); | ||
546 | err = 0; | ||
547 | } | ||
548 | } | 544 | } |
549 | } | 545 | } |
550 | 546 | ||