Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1272482 > unrolled thread
| Started by | Yang Shi <yang.shi@linaro.org> |
|---|---|
| First post | 2015-11-18 20:10 +0100 |
| Last post | 2015-11-20 01:30 +0100 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
[V2 PATCH] arm64: restore bogomips information in /proc/cpuinfo Yang Shi <yang.shi@linaro.org> - 2015-11-18 20:10 +0100
Re: [V2 PATCH] arm64: restore bogomips information in /proc/cpuinfo Catalin Marinas <catalin.marinas@arm.com> - 2015-11-19 19:00 +0100
Re: [V2 PATCH] arm64: restore bogomips information in /proc/cpuinfo "Shi, Yang" <yang.shi@linaro.org> - 2015-11-20 01:30 +0100
| From | Yang Shi <yang.shi@linaro.org> |
|---|---|
| Date | 2015-11-18 20:10 +0100 |
| Subject | [V2 PATCH] arm64: restore bogomips information in /proc/cpuinfo |
| Message-ID | <qwghb-77w-3@gated-at.bofh.it> |
As what Pavel Machek reported [1], some userspace applications depend on
bogomips showed by /proc/cpuinfo.
Although there is much less legacy impact on aarch64 than arm, but it does
break libvirt.
Basically, this patch reverts commit 326b16db9f69fd0d279be873c6c00f88c0a4aad5
("arm64: delay: don't bother reporting bogomips in /proc/cpuinfo"), but with
some tweak due to context change.
[1] https://lkml.org/lkml/2015/1/4/132
Acked-by: Will Deacon <will.deacon@arm.com>
Cc: <stable@vger.kernel.org> #3.12+
Signed-off-by: Yang Shi <yang.shi@linaro.org>
---
V2 --> V1:
* Remove double new line and unnecessary bogomips sum info
arch/arm64/kernel/cpuinfo.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/arm64/kernel/cpuinfo.c b/arch/arm64/kernel/cpuinfo.c
index 706679d..212ae63 100644
--- a/arch/arm64/kernel/cpuinfo.c
+++ b/arch/arm64/kernel/cpuinfo.c
@@ -30,6 +30,7 @@
#include <linux/seq_file.h>
#include <linux/sched.h>
#include <linux/smp.h>
+#include <linux/delay.h>
/*
* In case the boot CPU is hotpluggable, we record its initial state and
@@ -112,6 +113,10 @@ static int c_show(struct seq_file *m, void *v)
*/
seq_printf(m, "processor\t: %d\n", i);
+ seq_printf(m, "BogoMIPS\t: %lu.%02lu\n",
+ loops_per_jiffy / (500000UL/HZ),
+ loops_per_jiffy / (5000UL/HZ) % 100);
+
/*
* Dump out the common processor features in a single line.
* Userspace should read the hwcaps with getauxval(AT_HWCAP)
--
2.0.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Catalin Marinas <catalin.marinas@arm.com> |
|---|---|
| Date | 2015-11-19 19:00 +0100 |
| Message-ID | <qwBF1-44P-37@gated-at.bofh.it> |
| In reply to | #1272482 |
On Wed, Nov 18, 2015 at 10:48:55AM -0800, Yang Shi wrote:
> As what Pavel Machek reported [1], some userspace applications depend on
> bogomips showed by /proc/cpuinfo.
>
> Although there is much less legacy impact on aarch64 than arm, but it does
> break libvirt.
>
> Basically, this patch reverts commit 326b16db9f69fd0d279be873c6c00f88c0a4aad5
> ("arm64: delay: don't bother reporting bogomips in /proc/cpuinfo"), but with
> some tweak due to context change.
>
> [1] https://lkml.org/lkml/2015/1/4/132
>
> Acked-by: Will Deacon <will.deacon@arm.com>
> Cc: <stable@vger.kernel.org> #3.12+
> Signed-off-by: Yang Shi <yang.shi@linaro.org>
Patch applied as a fix for stable, basically returning back to the
pre-3.12 behaviour. If there is a need for some more useful information
here, it can be done as an additional patch, though without cc: stable.
Thanks.
--
Catalin
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | "Shi, Yang" <yang.shi@linaro.org> |
|---|---|
| Date | 2015-11-20 01:30 +0100 |
| Message-ID | <qwHKq-8fa-19@gated-at.bofh.it> |
| In reply to | #1273323 |
On 11/19/2015 9:59 AM, Catalin Marinas wrote:
> On Wed, Nov 18, 2015 at 10:48:55AM -0800, Yang Shi wrote:
>> As what Pavel Machek reported [1], some userspace applications depend on
>> bogomips showed by /proc/cpuinfo.
>>
>> Although there is much less legacy impact on aarch64 than arm, but it does
>> break libvirt.
>>
>> Basically, this patch reverts commit 326b16db9f69fd0d279be873c6c00f88c0a4aad5
>> ("arm64: delay: don't bother reporting bogomips in /proc/cpuinfo"), but with
>> some tweak due to context change.
>>
>> [1] https://lkml.org/lkml/2015/1/4/132
>>
>> Acked-by: Will Deacon <will.deacon@arm.com>
>> Cc: <stable@vger.kernel.org> #3.12+
>> Signed-off-by: Yang Shi <yang.shi@linaro.org>
>
> Patch applied as a fix for stable, basically returning back to the
> pre-3.12 behaviour. If there is a need for some more useful information
> here, it can be done as an additional patch, though without cc: stable.
Thanks. This approach sounds safer to usersapce.
Yang
>
> Thanks.
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web