ARM: bugfix: Features of /proc/cpuinfo is wrong
PATCH 1/1 ARM: bugfix: Features of /proc/cpuinfo is wrong
Array hwcap_str[19] should be "vfpd32" and hwcap_str[20] should be "lpae". But actually "vfpd32" was missing and "lpae" was at wrong place.
---
Hello,
The output of features string of /proc/cpuinfo is changed at v3.11-rc1. In case of KZM-A9-GT board, which cpu is ARM Corex-A9
$ grep Features /proc/cpuinfo
Features : swp half thumb fastmult vfp edsp neon vfpv3 tls lpae
This is wrong. Cortex-A9 does not have lpae (Large Physical Address Extension).
I tried git bisect and found this commit is related.
a469abd0f868c902b75532579bf87553dcf1b360
ARM: elf: add new hwcap for identifying atomic ldrd/strd instructions
Variable elf_hwcap = 0x0008b0d7. This seems good.HWCAP_LPAE (1 << 20) is not set in elf_hwcap.
Finally I found "lpae" string was wrong place in the array hwcap_str[]. hwcap_str[19] should be "vfpd32" and hwcap_str[20] should be "lpae". But actually "vfpd32" was missing and "lpae" was@wrong place.
After this patch, features of /proc/cpuinfo of the same board is
Features : swp half thumb fastmult vfp edsp neon vfpv3 tls vfpd32
I tested only in Cortex-A9.
Someone, please test on Cortex-A15 or A7. "lpae" should be appeared.
arch/arm/kernel/setup.c | 1 + 1 file changed, 1 insertion(+)
arch/arm/kernel/setup.c +1 -0
@@ -971,6 +971,7 @@ static const char *hwcap_str[] = {"vfpv4" ,"idiva" ,"idivt" , +"vfpd32" ,"lpae" , NULL };
Signature · 1 line
1.7.9.5
PATCH 1/1 ARM: bugfix: Features of /proc/cpuinfo is wrong
Quoted 4 lines · Tetsuyuki Kobayashi
Array hwcap_str[19] should be "vfpd32" and hwcap_str[20] should be "lpae". But actually "vfpd32" was missing and "lpae" was at wrong place.
Signed-off-by Tetsuyuki Kobayashi <[email protected]>
[...]
arch/arm/kernel/setup.c static const char *hwcap_str[] = { · line 977
Quoted 13 lines
arch/arm/kernel/setup.c +1
-0@@ -971,6 +971,7 @@ static const char *hwcap_str[] = {"vfpv4" ,"idiva" ,"idivt" , +"vfpd32" ,"lpae" , NULL };
Please can you put this into the patch system? It needs to get in for 3.11.
Cheers,
Will
PATCH 1/1 ARM: bugfix: Features of /proc/cpuinfo is wrong
Quoted 24 lines · Will Deacon
Quoted 4 lines · Tetsuyuki Kobayashi
Array hwcap_str[19] should be "vfpd32" and hwcap_str[20] should be "lpae". But actually "vfpd32" was missing and "lpae" was at wrong place.
Signed-off-by Tetsuyuki Kobayashi <[email protected]>[...]
arch/arm/kernel/setup.c static const char *hwcap_str[] = { · line 977
Quoted 13 lines
arch/arm/kernel/setup.c +1
-0@@ -971,6 +971,7 @@ static const char *hwcap_str[] = {"vfpv4" ,"idiva" ,"idivt" , +"vfpd32" ,"lpae" , NULL };Acked-by Will Deacon <[email protected]>
Quoted 1 line
Please can you put this into the patch system? It needs to get in for 3.11.
I still can't see this in the patch system. I've tested it on A5, A7, A9 and A15 and it works as expected.
Will