From 974de4d7e70a6d759457722a6f322cc86b480eea Mon Sep 17 00:00:00 2001 From: Heiko Carstens Date: Wed, 5 Jan 2011 12:48:16 +0100 Subject: [S390] smp: remove cpu hotplug messages Get rid of messages that indicate if a cpu went online or offline. There is nothing special about this anymore and these messages might flood the kernel log buffer which makes debugging harder since more important messages might be overwritten. Signed-off-by: Heiko Carstens Signed-off-by: Martin Schwidefsky --- arch/s390/kernel/processor.c | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'arch/s390/kernel/processor.c') diff --git a/arch/s390/kernel/processor.c b/arch/s390/kernel/processor.c index 644548e615c..eeb651b48db 100644 --- a/arch/s390/kernel/processor.c +++ b/arch/s390/kernel/processor.c @@ -34,17 +34,6 @@ void __cpuinit cpu_init(void) enter_lazy_tlb(&init_mm, current); } -/* - * print_cpu_info - print basic information about a cpu - */ -void __cpuinit print_cpu_info(void) -{ - struct cpuid *id = &per_cpu(cpu_id, smp_processor_id()); - - pr_info("Processor %d started, address %d, identification %06X\n", - S390_lowcore.cpu_nr, stap(), id->ident); -} - /* * show_cpuinfo - Get information on one CPU for use by procfs. */ -- cgit v1.2.3-70-g09d2 From 19726cec63aeadad127f9e72ee69240336e37f15 Mon Sep 17 00:00:00 2001 From: Heiko Carstens Date: Wed, 5 Jan 2011 12:48:17 +0100 Subject: [S390] cpuinfo: use get_online_cpus() instead of preempt_disable() Use get_online_cpus() instead of preempt_disable() to make sure cpus don't go offline while accessing their per cpu data. The preempt_disable() stuff is old code which was used before get_online_cpus() was available. Signed-off-by: Heiko Carstens Signed-off-by: Martin Schwidefsky --- arch/s390/kernel/processor.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'arch/s390/kernel/processor.c') diff --git a/arch/s390/kernel/processor.c b/arch/s390/kernel/processor.c index eeb651b48db..753623bde8e 100644 --- a/arch/s390/kernel/processor.c +++ b/arch/s390/kernel/processor.c @@ -13,7 +13,7 @@ #include #include #include - +#include #include #include #include @@ -47,7 +47,6 @@ static int show_cpuinfo(struct seq_file *m, void *v) int i; s390_adjust_jiffies(); - preempt_disable(); if (!n) { seq_printf(m, "vendor_id : IBM/S390\n" "# processors : %i\n" @@ -60,7 +59,7 @@ static int show_cpuinfo(struct seq_file *m, void *v) seq_printf(m, "%s ", hwcap_str[i]); seq_puts(m, "\n"); } - + get_online_cpus(); if (cpu_online(n)) { struct cpuid *id = &per_cpu(cpu_id, n); seq_printf(m, "processor %li: " @@ -69,7 +68,7 @@ static int show_cpuinfo(struct seq_file *m, void *v) "machine = %04X\n", n, id->version, id->ident, id->machine); } - preempt_enable(); + put_online_cpus(); return 0; } -- cgit v1.2.3-70-g09d2 From 8e1023016cf17152972b98bce6c144834a4916d5 Mon Sep 17 00:00:00 2001 From: Heiko Carstens Date: Wed, 5 Jan 2011 12:48:18 +0100 Subject: [S390] prevent unneccesary loops_per_jiffy recalculation When the seqfile /proc/cpuinfo gets accesses for each possible cpu loops_per_jiffy gets recalculated. However its value is only needed on first access. In addition loops_per_jiffy should be recalculated when the machine reports a capability change. Signed-off-by: Heiko Carstens Signed-off-by: Martin Schwidefsky --- arch/s390/kernel/processor.c | 2 +- drivers/s390/char/sclp_config.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'arch/s390/kernel/processor.c') diff --git a/arch/s390/kernel/processor.c b/arch/s390/kernel/processor.c index 753623bde8e..311e9d71288 100644 --- a/arch/s390/kernel/processor.c +++ b/arch/s390/kernel/processor.c @@ -46,8 +46,8 @@ static int show_cpuinfo(struct seq_file *m, void *v) unsigned long n = (unsigned long) v - 1; int i; - s390_adjust_jiffies(); if (!n) { + s390_adjust_jiffies(); seq_printf(m, "vendor_id : IBM/S390\n" "# processors : %i\n" "bogomips per cpu: %lu.%02lu\n", diff --git a/drivers/s390/char/sclp_config.c b/drivers/s390/char/sclp_config.c index b497afe061c..16e232a99fb 100644 --- a/drivers/s390/char/sclp_config.c +++ b/drivers/s390/char/sclp_config.c @@ -33,6 +33,7 @@ static void sclp_cpu_capability_notify(struct work_struct *work) int cpu; struct sys_device *sysdev; + s390_adjust_jiffies(); pr_warning("cpu capability changed.\n"); get_online_cpus(); for_each_online_cpu(cpu) { -- cgit v1.2.3-70-g09d2