]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
ARM: 7483/1: vfp: only advertise VFPv4 in hwcaps if CONFIG_VFPv3 is enabled
authorWill Deacon <will.deacon@arm.com>
Fri, 3 Aug 2012 16:24:14 +0000 (17:24 +0100)
committerBen Hutchings <ben@decadent.org.uk>
Wed, 12 Sep 2012 02:36:56 +0000 (03:36 +0100)
commit 3d9fb0038a9b02febb01efc79a4a5d97f1822a90 upstream.

VFPv4 support depends on the VFPv3 context save/restore code, so only
advertise support in the hwcaps if the kernel can actually handle it.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
arch/arm/vfp/vfpmodule.c

index ad83dadd151da45c352a3eba741f2d04f9fcb7d2..f0702f384f464dee764edb6e87bd687a73042e3f 100644 (file)
@@ -628,8 +628,10 @@ static int __init vfp_init(void)
                        if ((fmrx(MVFR1) & 0x000fff00) == 0x00011100)
                                elf_hwcap |= HWCAP_NEON;
 #endif
+#ifdef CONFIG_VFPv3
                        if ((fmrx(MVFR1) & 0xf0000000) == 0x10000000)
                                elf_hwcap |= HWCAP_VFPv4;
+#endif
                }
        }
        return 0;