Skip to content

Commit

Permalink
[PATCH] s390: show_cpuinfo fix
Browse files Browse the repository at this point in the history
Disable preemption in show_cpuinfo to avoid problems and the warning about
smp_processor_id.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Heiko Carstens authored and Linus Torvalds committed Sep 17, 2005
1 parent 90f4e12 commit b7ae9dd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/s390/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -634,6 +634,7 @@ static int show_cpuinfo(struct seq_file *m, void *v)
struct cpuinfo_S390 *cpuinfo;
unsigned long n = (unsigned long) v - 1;

preempt_disable();
if (!n) {
seq_printf(m, "vendor_id : IBM/S390\n"
"# processors : %i\n"
Expand All @@ -658,6 +659,7 @@ static int show_cpuinfo(struct seq_file *m, void *v)
cpuinfo->cpu_id.ident,
cpuinfo->cpu_id.machine);
}
preempt_enable();
return 0;
}

Expand Down

0 comments on commit b7ae9dd

Please sign in to comment.