All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
@ 2013-06-20 16:43 ` Will Deacon
  0 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-20 16:43 UTC (permalink / raw)
  To: linux-arm-kernel

Hi all,

This is version two of the patches I originally posted here:

  http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html

Comments received there largely confirmed that it's not possible to choose
an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
and removed the line altogether.

In the meantime, I've only had one complaint this month about BogoMIPs
being wrong, so perhaps the initial posting served some purpose without
even being merged!

Comments welcome,

Will


Will Deacon (2):
  ARM: delay: don't bother reporting bogomips in /proc/cpuinfo
  init: calibrate: don't print out bogomips value on boot

 arch/arm/kernel/setup.c |  9 ---------
 arch/arm/kernel/smp.c   | 13 ++-----------
 init/calibrate.c        |  8 +++-----
 3 files changed, 5 insertions(+), 25 deletions(-)

-- 
1.8.2.2

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
@ 2013-06-20 16:43 ` Will Deacon
  0 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-20 16:43 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel; +Cc: nico, cov, marc.zyngier, Will Deacon

Hi all,

This is version two of the patches I originally posted here:

  http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html

Comments received there largely confirmed that it's not possible to choose
an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
and removed the line altogether.

In the meantime, I've only had one complaint this month about BogoMIPs
being wrong, so perhaps the initial posting served some purpose without
even being merged!

Comments welcome,

Will


Will Deacon (2):
  ARM: delay: don't bother reporting bogomips in /proc/cpuinfo
  init: calibrate: don't print out bogomips value on boot

 arch/arm/kernel/setup.c |  9 ---------
 arch/arm/kernel/smp.c   | 13 ++-----------
 init/calibrate.c        |  8 +++-----
 3 files changed, 5 insertions(+), 25 deletions(-)

-- 
1.8.2.2


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH v2 1/2] ARM: delay: don't bother reporting bogomips in /proc/cpuinfo
  2013-06-20 16:43 ` Will Deacon
@ 2013-06-20 16:43   ` Will Deacon
  -1 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-20 16:43 UTC (permalink / raw)
  To: linux-arm-kernel

Now that we support a timer-backed delay loop, I'm quickly getting sick
and tired of people complaining that their beloved bogomips value has
decreased. You know who you are!

This patch removes the bogomips line from /proc/cpuinfo, based on the
reasoning that any program parsing this is already broken and, as such,
won't be further broken if the field is removed.

Cc: Nicolas Pitre <nico@fluxnic.net>
Signed-off-by: Will Deacon <will.deacon@arm.com>
---
 arch/arm/kernel/setup.c |  9 ---------
 arch/arm/kernel/smp.c   | 13 ++-----------
 2 files changed, 2 insertions(+), 20 deletions(-)

diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c
index 559b976..9d80aeb 100644
--- a/arch/arm/kernel/setup.c
+++ b/arch/arm/kernel/setup.c
@@ -902,15 +902,6 @@ static int c_show(struct seq_file *m, void *v)
 		seq_printf(m, "model name\t: %s rev %d (%s)\n",
 			   cpu_name, cpuid & 15, elf_platform);
 
-#if defined(CONFIG_SMP)
-		seq_printf(m, "BogoMIPS\t: %lu.%02lu\n",
-			   per_cpu(cpu_data, i).loops_per_jiffy / (500000UL/HZ),
-			   (per_cpu(cpu_data, i).loops_per_jiffy / (5000UL/HZ)) % 100);
-#else
-		seq_printf(m, "BogoMIPS\t: %lu.%02lu\n",
-			   loops_per_jiffy / (500000/HZ),
-			   (loops_per_jiffy / (5000/HZ)) % 100);
-#endif
 		/* dump out the processor features */
 		seq_puts(m, "Features\t: ");
 
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
index 550d63c..bd23678 100644
--- a/arch/arm/kernel/smp.c
+++ b/arch/arm/kernel/smp.c
@@ -375,17 +375,8 @@ asmlinkage void __cpuinit secondary_start_kernel(void)
 
 void __init smp_cpus_done(unsigned int max_cpus)
 {
-	int cpu;
-	unsigned long bogosum = 0;
-
-	for_each_online_cpu(cpu)
-		bogosum += per_cpu(cpu_data, cpu).loops_per_jiffy;
-
-	printk(KERN_INFO "SMP: Total of %d processors activated "
-	       "(%lu.%02lu BogoMIPS).\n",
-	       num_online_cpus(),
-	       bogosum / (500000/HZ),
-	       (bogosum / (5000/HZ)) % 100);
+	printk(KERN_INFO "SMP: Total of %d processors activated.\n",
+	       num_online_cpus());
 
 	hyp_mode_check();
 }
-- 
1.8.2.2

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH v2 1/2] ARM: delay: don't bother reporting bogomips in /proc/cpuinfo
@ 2013-06-20 16:43   ` Will Deacon
  0 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-20 16:43 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel; +Cc: nico, cov, marc.zyngier, Will Deacon

Now that we support a timer-backed delay loop, I'm quickly getting sick
and tired of people complaining that their beloved bogomips value has
decreased. You know who you are!

This patch removes the bogomips line from /proc/cpuinfo, based on the
reasoning that any program parsing this is already broken and, as such,
won't be further broken if the field is removed.

Cc: Nicolas Pitre <nico@fluxnic.net>
Signed-off-by: Will Deacon <will.deacon@arm.com>
---
 arch/arm/kernel/setup.c |  9 ---------
 arch/arm/kernel/smp.c   | 13 ++-----------
 2 files changed, 2 insertions(+), 20 deletions(-)

diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c
index 559b976..9d80aeb 100644
--- a/arch/arm/kernel/setup.c
+++ b/arch/arm/kernel/setup.c
@@ -902,15 +902,6 @@ static int c_show(struct seq_file *m, void *v)
 		seq_printf(m, "model name\t: %s rev %d (%s)\n",
 			   cpu_name, cpuid & 15, elf_platform);
 
-#if defined(CONFIG_SMP)
-		seq_printf(m, "BogoMIPS\t: %lu.%02lu\n",
-			   per_cpu(cpu_data, i).loops_per_jiffy / (500000UL/HZ),
-			   (per_cpu(cpu_data, i).loops_per_jiffy / (5000UL/HZ)) % 100);
-#else
-		seq_printf(m, "BogoMIPS\t: %lu.%02lu\n",
-			   loops_per_jiffy / (500000/HZ),
-			   (loops_per_jiffy / (5000/HZ)) % 100);
-#endif
 		/* dump out the processor features */
 		seq_puts(m, "Features\t: ");
 
diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
index 550d63c..bd23678 100644
--- a/arch/arm/kernel/smp.c
+++ b/arch/arm/kernel/smp.c
@@ -375,17 +375,8 @@ asmlinkage void __cpuinit secondary_start_kernel(void)
 
 void __init smp_cpus_done(unsigned int max_cpus)
 {
-	int cpu;
-	unsigned long bogosum = 0;
-
-	for_each_online_cpu(cpu)
-		bogosum += per_cpu(cpu_data, cpu).loops_per_jiffy;
-
-	printk(KERN_INFO "SMP: Total of %d processors activated "
-	       "(%lu.%02lu BogoMIPS).\n",
-	       num_online_cpus(),
-	       bogosum / (500000/HZ),
-	       (bogosum / (5000/HZ)) % 100);
+	printk(KERN_INFO "SMP: Total of %d processors activated.\n",
+	       num_online_cpus());
 
 	hyp_mode_check();
 }
-- 
1.8.2.2


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH v2 2/2] init: calibrate: don't print out bogomips value on boot
  2013-06-20 16:43 ` Will Deacon
@ 2013-06-20 16:43   ` Will Deacon
  -1 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-20 16:43 UTC (permalink / raw)
  To: linux-arm-kernel

BogoMIPs is a confusing concept to the ill-informed, so allow
architectures to print it only if they find it worthwhile. The delay
calibration code should stick to lpj and avoid trying to draw any
correlation with BogoMIPs, which may be a fixed value derived from a
timer frequency independent of the CPU clock speed.

Signed-off-by: Will Deacon <will.deacon@arm.com>
---
 init/calibrate.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/init/calibrate.c b/init/calibrate.c
index fda0a7b..cf48068 100644
--- a/init/calibrate.c
+++ b/init/calibrate.c
@@ -135,13 +135,13 @@ static unsigned long __cpuinit calibrate_delay_direct(void)
 		if ((measured_times[max] - estimate) <
 				(estimate - measured_times[min])) {
 			printk(KERN_NOTICE "calibrate_delay_direct() dropping "
-					"min bogoMips estimate %d = %lu\n",
+					"min delay estimate %d = %lu\n",
 				min, measured_times[min]);
 			measured_times[min] = 0;
 			min = max;
 		} else {
 			printk(KERN_NOTICE "calibrate_delay_direct() dropping "
-					"max bogoMips estimate %d = %lu\n",
+					"max delay estimate %d = %lu\n",
 				max, measured_times[max]);
 			measured_times[max] = 0;
 			max = min;
@@ -292,9 +292,7 @@ void __cpuinit calibrate_delay(void)
 	}
 	per_cpu(cpu_loops_per_jiffy, this_cpu) = lpj;
 	if (!printed)
-		pr_cont("%lu.%02lu BogoMIPS (lpj=%lu)\n",
-			lpj/(500000/HZ),
-			(lpj/(5000/HZ)) % 100, lpj);
+		pr_cont("lpj=%lu\n", lpj);
 
 	loops_per_jiffy = lpj;
 	printed = true;
-- 
1.8.2.2

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH v2 2/2] init: calibrate: don't print out bogomips value on boot
@ 2013-06-20 16:43   ` Will Deacon
  0 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-20 16:43 UTC (permalink / raw)
  To: linux-arm-kernel, linux-kernel; +Cc: nico, cov, marc.zyngier, Will Deacon

BogoMIPs is a confusing concept to the ill-informed, so allow
architectures to print it only if they find it worthwhile. The delay
calibration code should stick to lpj and avoid trying to draw any
correlation with BogoMIPs, which may be a fixed value derived from a
timer frequency independent of the CPU clock speed.

Signed-off-by: Will Deacon <will.deacon@arm.com>
---
 init/calibrate.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/init/calibrate.c b/init/calibrate.c
index fda0a7b..cf48068 100644
--- a/init/calibrate.c
+++ b/init/calibrate.c
@@ -135,13 +135,13 @@ static unsigned long __cpuinit calibrate_delay_direct(void)
 		if ((measured_times[max] - estimate) <
 				(estimate - measured_times[min])) {
 			printk(KERN_NOTICE "calibrate_delay_direct() dropping "
-					"min bogoMips estimate %d = %lu\n",
+					"min delay estimate %d = %lu\n",
 				min, measured_times[min]);
 			measured_times[min] = 0;
 			min = max;
 		} else {
 			printk(KERN_NOTICE "calibrate_delay_direct() dropping "
-					"max bogoMips estimate %d = %lu\n",
+					"max delay estimate %d = %lu\n",
 				max, measured_times[max]);
 			measured_times[max] = 0;
 			max = min;
@@ -292,9 +292,7 @@ void __cpuinit calibrate_delay(void)
 	}
 	per_cpu(cpu_loops_per_jiffy, this_cpu) = lpj;
 	if (!printed)
-		pr_cont("%lu.%02lu BogoMIPS (lpj=%lu)\n",
-			lpj/(500000/HZ),
-			(lpj/(5000/HZ)) % 100, lpj);
+		pr_cont("lpj=%lu\n", lpj);
 
 	loops_per_jiffy = lpj;
 	printed = true;
-- 
1.8.2.2


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
  2013-06-20 16:43 ` Will Deacon
@ 2013-06-20 18:54   ` Nicolas Pitre
  -1 siblings, 0 replies; 12+ messages in thread
From: Nicolas Pitre @ 2013-06-20 18:54 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, 20 Jun 2013, Will Deacon wrote:

> Hi all,
> 
> This is version two of the patches I originally posted here:
> 
>   http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html
> 
> Comments received there largely confirmed that it's not possible to choose
> an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
> and removed the line altogether.
> 
> In the meantime, I've only had one complaint this month about BogoMIPs
> being wrong, so perhaps the initial posting served some purpose without
> even being merged!
> 
> Comments welcome,

Enthusiastic ACK for both patches.


Nicolas

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
@ 2013-06-20 18:54   ` Nicolas Pitre
  0 siblings, 0 replies; 12+ messages in thread
From: Nicolas Pitre @ 2013-06-20 18:54 UTC (permalink / raw)
  To: Will Deacon; +Cc: linux-arm-kernel, linux-kernel, cov, marc.zyngier

On Thu, 20 Jun 2013, Will Deacon wrote:

> Hi all,
> 
> This is version two of the patches I originally posted here:
> 
>   http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html
> 
> Comments received there largely confirmed that it's not possible to choose
> an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
> and removed the line altogether.
> 
> In the meantime, I've only had one complaint this month about BogoMIPs
> being wrong, so perhaps the initial posting served some purpose without
> even being merged!
> 
> Comments welcome,

Enthusiastic ACK for both patches.


Nicolas

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
  2013-06-20 18:54   ` Nicolas Pitre
@ 2013-06-21  8:40     ` Will Deacon
  -1 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-21  8:40 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jun 20, 2013 at 07:54:21PM +0100, Nicolas Pitre wrote:
> On Thu, 20 Jun 2013, Will Deacon wrote:
> 
> > Hi all,
> > 
> > This is version two of the patches I originally posted here:
> > 
> >   http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html
> > 
> > Comments received there largely confirmed that it's not possible to choose
> > an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
> > and removed the line altogether.
> > 
> > In the meantime, I've only had one complaint this month about BogoMIPs
> > being wrong, so perhaps the initial posting served some purpose without
> > even being merged!
> > 
> > Comments welcome,
> 
> Enthusiastic ACK for both patches.

Thanks Nicolas!

Will

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
@ 2013-06-21  8:40     ` Will Deacon
  0 siblings, 0 replies; 12+ messages in thread
From: Will Deacon @ 2013-06-21  8:40 UTC (permalink / raw)
  To: Nicolas Pitre
  Cc: linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, cov@codeaurora.org, Marc Zyngier

On Thu, Jun 20, 2013 at 07:54:21PM +0100, Nicolas Pitre wrote:
> On Thu, 20 Jun 2013, Will Deacon wrote:
> 
> > Hi all,
> > 
> > This is version two of the patches I originally posted here:
> > 
> >   http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html
> > 
> > Comments received there largely confirmed that it's not possible to choose
> > an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
> > and removed the line altogether.
> > 
> > In the meantime, I've only had one complaint this month about BogoMIPs
> > being wrong, so perhaps the initial posting served some purpose without
> > even being merged!
> > 
> > Comments welcome,
> 
> Enthusiastic ACK for both patches.

Thanks Nicolas!

Will

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
  2013-06-20 16:43 ` Will Deacon
@ 2013-06-21  9:47   ` Marc Zyngier
  -1 siblings, 0 replies; 12+ messages in thread
From: Marc Zyngier @ 2013-06-21  9:47 UTC (permalink / raw)
  To: linux-arm-kernel

On 20/06/13 17:43, Will Deacon wrote:
> Hi all,
> 
> This is version two of the patches I originally posted here:
> 
>   http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html
> 
> Comments received there largely confirmed that it's not possible to choose
> an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
> and removed the line altogether.
> 
> In the meantime, I've only had one complaint this month about BogoMIPs
> being wrong, so perhaps the initial posting served some purpose without
> even being merged!

For the whole series, and cheering loudly:
Acked-by: Marc Zyngier <marc.zyngier@arm.com>

	M.
-- 
Jazz is not dead. It just smells funny...

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value
@ 2013-06-21  9:47   ` Marc Zyngier
  0 siblings, 0 replies; 12+ messages in thread
From: Marc Zyngier @ 2013-06-21  9:47 UTC (permalink / raw)
  To: Will Deacon
  Cc: linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, nico@fluxnic.net,
	cov@codeaurora.org

On 20/06/13 17:43, Will Deacon wrote:
> Hi all,
> 
> This is version two of the patches I originally posted here:
> 
>   http://lists.infradead.org/pipermail/linux-arm-kernel/2013-May/166728.html
> 
> Comments received there largely confirmed that it's not possible to choose
> an `obviously bogus' value for BogoMIPs, so instead I've bitten the bullet
> and removed the line altogether.
> 
> In the meantime, I've only had one complaint this month about BogoMIPs
> being wrong, so perhaps the initial posting served some purpose without
> even being merged!

For the whole series, and cheering loudly:
Acked-by: Marc Zyngier <marc.zyngier@arm.com>

	M.
-- 
Jazz is not dead. It just smells funny...


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2013-06-21  9:47 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-20 16:43 [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value Will Deacon
2013-06-20 16:43 ` Will Deacon
2013-06-20 16:43 ` [PATCH v2 1/2] ARM: delay: don't bother reporting bogomips in /proc/cpuinfo Will Deacon
2013-06-20 16:43   ` Will Deacon
2013-06-20 16:43 ` [PATCH v2 2/2] init: calibrate: don't print out bogomips value on boot Will Deacon
2013-06-20 16:43   ` Will Deacon
2013-06-20 18:54 ` [PATCH v2 0/2] ARM: Remove any correlation between IPC and BogoMips value Nicolas Pitre
2013-06-20 18:54   ` Nicolas Pitre
2013-06-21  8:40   ` Will Deacon
2013-06-21  8:40     ` Will Deacon
2013-06-21  9:47 ` Marc Zyngier
2013-06-21  9:47   ` Marc Zyngier

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.