arm64: constify icache_policy_str[]
authorMark Rutland <mark.rutland@arm.com>
Tue, 13 Aug 2019 14:16:37 +0000 (15:16 +0100)
committerWill Deacon <will@kernel.org>
Tue, 13 Aug 2019 17:32:17 +0000 (18:32 +0100)
The icache_policy_str[] array contains compile-time constant data, and
is never intentionally modified, so let's mark it as const.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Will Deacon <will@kernel.org>
arch/arm64/kernel/cpuinfo.c

index 876055e373525999e1775dbd2a1bc482c9359b62..05933c065732b8cc5dac245d2baea0f1ccd4147f 100644 (file)
@@ -33,7 +33,7 @@
 DEFINE_PER_CPU(struct cpuinfo_arm64, cpu_data);
 static struct cpuinfo_arm64 boot_cpu_data;
 
-static char *icache_policy_str[] = {
+static const char *icache_policy_str[] = {
        [0 ... ICACHE_POLICY_PIPT]      = "RESERVED/UNKNOWN",
        [ICACHE_POLICY_VIPT]            = "VIPT",
        [ICACHE_POLICY_PIPT]            = "PIPT",