arm64: capabilities: Optimize this_cpu_has_cap
authorSuzuki K Poulose <suzuki.poulose@arm.com>
Fri, 30 Nov 2018 17:18:04 +0000 (17:18 +0000)
committerWill Deacon <will.deacon@arm.com>
Thu, 6 Dec 2018 15:12:25 +0000 (15:12 +0000)
commitf7bfc14a0819962bc0767f33ce17d4b366b46dd6
treeecf7354be09bed5586c633200adfb3e356db2e17
parent82a3a21b236f96f84b715c46ac1b2a669da8916f
arm64: capabilities: Optimize this_cpu_has_cap

Make use of the sorted capability list to access the capability
entry in this_cpu_has_cap() to avoid iterating over the two
tables.

Reviewed-by: Vladimir Murzin <vladimir.murzin@arm.com>
Tested-by: Vladimir Murzin <vladimir.murzin@arm.com>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/kernel/cpufeature.c