aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/include/asm/hwcap.h2
-rw-r--r--arch/arm/kernel/setup.c2
-rw-r--r--arch/arm/vfp/vfpmodule.c12
3 files changed, 16 insertions, 0 deletions
diff --git a/arch/arm/include/asm/hwcap.h b/arch/arm/include/asm/hwcap.h
index bda489f9f017..f7bd52b1c365 100644
--- a/arch/arm/include/asm/hwcap.h
+++ b/arch/arm/include/asm/hwcap.h
@@ -17,6 +17,8 @@
17#define HWCAP_CRUNCH 1024 17#define HWCAP_CRUNCH 1024
18#define HWCAP_THUMBEE 2048 18#define HWCAP_THUMBEE 2048
19#define HWCAP_NEON 4096 19#define HWCAP_NEON 4096
20#define HWCAP_VFPv3 8192
21#define HWCAP_VFPv3D16 16384
20 22
21#if defined(__KERNEL__) && !defined(__ASSEMBLY__) 23#if defined(__KERNEL__) && !defined(__ASSEMBLY__)
22/* 24/*
diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c
index 7049815d66d5..645ec7436681 100644
--- a/arch/arm/kernel/setup.c
+++ b/arch/arm/kernel/setup.c
@@ -779,6 +779,8 @@ static const char *hwcap_str[] = {
779 "crunch", 779 "crunch",
780 "thumbee", 780 "thumbee",
781 "neon", 781 "neon",
782 "vfpv3",
783 "vfpv3d16",
782 NULL 784 NULL
783}; 785};
784 786
diff --git a/arch/arm/vfp/vfpmodule.c b/arch/arm/vfp/vfpmodule.c
index 7e1239041b39..75457b30d813 100644
--- a/arch/arm/vfp/vfpmodule.c
+++ b/arch/arm/vfp/vfpmodule.c
@@ -476,6 +476,18 @@ static int __init vfp_init(void)
476 * in place; report VFP support to userspace. 476 * in place; report VFP support to userspace.
477 */ 477 */
478 elf_hwcap |= HWCAP_VFP; 478 elf_hwcap |= HWCAP_VFP;
479#ifdef CONFIG_VFPv3
480 if (VFP_arch >= 3) {
481 elf_hwcap |= HWCAP_VFPv3;
482
483 /*
484 * Check for VFPv3 D16. CPUs in this configuration
485 * only have 16 x 64bit registers.
486 */
487 if (((fmrx(MVFR0) & MVFR0_A_SIMD_MASK)) == 1)
488 elf_hwcap |= HWCAP_VFPv3D16;
489 }
490#endif
479#ifdef CONFIG_NEON 491#ifdef CONFIG_NEON
480 /* 492 /*
481 * Check for the presence of the Advanced SIMD 493 * Check for the presence of the Advanced SIMD