diff options
author | Will Deacon <will.deacon@arm.com> | 2011-06-03 09:09:37 -0400 |
---|---|---|
committer | Will Deacon <will.deacon@arm.com> | 2011-07-07 14:20:51 -0400 |
commit | 194a7f720f6f009867a01b760f311b68f1e81872 (patch) | |
tree | 75c1aa60120ed22b893acf7bdef9f43ce6dc860c /arch | |
parent | 305edadbfbc46f1d194d27e93e4237284b95fbb0 (diff) |
ARM: hwcaps: use shifts instead of hardcoded constants
The HWCAP numbers are defined as constants, each one being a power of 2.
This has become slightly unwieldy now that we have reached 32k.
This patch changes the HWCAP defines to use (1 << n) instead of coding
the constant directly. The values remain unchanged.
Signed-off-by: Will Deacon <will.deacon@arm.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/include/asm/hwcap.h | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/arch/arm/include/asm/hwcap.h b/arch/arm/include/asm/hwcap.h index c1062c317103..81512db2b628 100644 --- a/arch/arm/include/asm/hwcap.h +++ b/arch/arm/include/asm/hwcap.h | |||
@@ -4,22 +4,22 @@ | |||
4 | /* | 4 | /* |
5 | * HWCAP flags - for elf_hwcap (in kernel) and AT_HWCAP | 5 | * HWCAP flags - for elf_hwcap (in kernel) and AT_HWCAP |
6 | */ | 6 | */ |
7 | #define HWCAP_SWP 1 | 7 | #define HWCAP_SWP (1 << 0) |
8 | #define HWCAP_HALF 2 | 8 | #define HWCAP_HALF (1 << 1) |
9 | #define HWCAP_THUMB 4 | 9 | #define HWCAP_THUMB (1 << 2) |
10 | #define HWCAP_26BIT 8 /* Play it safe */ | 10 | #define HWCAP_26BIT (1 << 3) /* Play it safe */ |
11 | #define HWCAP_FAST_MULT 16 | 11 | #define HWCAP_FAST_MULT (1 << 4) |
12 | #define HWCAP_FPA 32 | 12 | #define HWCAP_FPA (1 << 5) |
13 | #define HWCAP_VFP 64 | 13 | #define HWCAP_VFP (1 << 6) |
14 | #define HWCAP_EDSP 128 | 14 | #define HWCAP_EDSP (1 << 7) |
15 | #define HWCAP_JAVA 256 | 15 | #define HWCAP_JAVA (1 << 8) |
16 | #define HWCAP_IWMMXT 512 | 16 | #define HWCAP_IWMMXT (1 << 9) |
17 | #define HWCAP_CRUNCH 1024 | 17 | #define HWCAP_CRUNCH (1 << 10) |
18 | #define HWCAP_THUMBEE 2048 | 18 | #define HWCAP_THUMBEE (1 << 11) |
19 | #define HWCAP_NEON 4096 | 19 | #define HWCAP_NEON (1 << 12) |
20 | #define HWCAP_VFPv3 8192 | 20 | #define HWCAP_VFPv3 (1 << 13) |
21 | #define HWCAP_VFPv3D16 16384 | 21 | #define HWCAP_VFPv3D16 (1 << 14) |
22 | #define HWCAP_TLS 32768 | 22 | #define HWCAP_TLS (1 << 15) |
23 | 23 | ||
24 | #if defined(__KERNEL__) && !defined(__ASSEMBLY__) | 24 | #if defined(__KERNEL__) && !defined(__ASSEMBLY__) |
25 | /* | 25 | /* |