From: Yunfeng Ye Date: Thu, 9 Dec 2021 01:46:03 +0000 (+0800) Subject: arm64: mm: Use asid feature macro for cheanup X-Git-Tag: baikal/mips/sdk6.1~6758^2^2~8 X-Git-Url: https://git.baikalelectronics.ru/sdk/?a=commitdiff_plain;h=c70919909ba6270af7ddfd86126fb161bdb06de4;p=kernel.git arm64: mm: Use asid feature macro for cheanup The commit ef25c51d09af ("KVM: arm64: Add feature register flag definitions") introduce the ID_AA64MMFR0_ASID_8 and ID_AA64MMFR0_ASID_16 macros. We can use these macros for cheanup in get_cpu_asid_bits(). No functional change. Signed-off-by: Yunfeng Ye Reviewed-by: Kefeng Wang Link: https://lore.kernel.org/r/f71c75d3-735e-b32a-8414-b3e513c77240@huawei.com Signed-off-by: Catalin Marinas --- diff --git a/arch/arm64/mm/context.c b/arch/arm64/mm/context.c index bbc2708fe9289..b8b4cf0bcf39b 100644 --- a/arch/arm64/mm/context.c +++ b/arch/arm64/mm/context.c @@ -50,10 +50,10 @@ static u32 get_cpu_asid_bits(void) pr_warn("CPU%d: Unknown ASID size (%d); assuming 8-bit\n", smp_processor_id(), fld); fallthrough; - case 0: + case ID_AA64MMFR0_ASID_8: asid = 8; break; - case 2: + case ID_AA64MMFR0_ASID_16: asid = 16; }