linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] arm64: trivial constification patches
@ 2019-08-13 14:16 Mark Rutland
  2019-08-13 14:16 ` [PATCH 1/3] arm64: constify icache_policy_str[] Mark Rutland
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Mark Rutland @ 2019-08-13 14:16 UTC (permalink / raw)
  To: linux-arm-kernel; +Cc: mark.rutland, catalin.marinas, will.deacon

I spotted a few arrays under arm64 that we can mark const, as their
contents are never intentionally modified at runtime. Doing this will
make it a bit easier to spot bugs, and (in the case of sys64_hook) will
make it marginally harder to get the kernel to execute the wrong thing.

Our crypto algorithm and undef_hook arrays all have runtime-modified state, so
these cannot be made const.

Thanks,
Mark.

Mark Rutland (3):
  arm64: constify icache_policy_str[]
  arm64: constify aarch64_insn_encoding_class[]
  arm64: constify sys64_hook instances

 arch/arm64/kernel/cpuinfo.c |  2 +-
 arch/arm64/kernel/insn.c    |  2 +-
 arch/arm64/kernel/traps.c   | 10 +++++-----
 3 files changed, 7 insertions(+), 7 deletions(-)

-- 
2.11.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-08-14  9:12 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-13 14:16 [PATCH 0/3] arm64: trivial constification patches Mark Rutland
2019-08-13 14:16 ` [PATCH 1/3] arm64: constify icache_policy_str[] Mark Rutland
2019-08-14  9:07   ` Dave Martin
2019-08-13 14:16 ` [PATCH 2/3] arm64: constify aarch64_insn_encoding_class[] Mark Rutland
2019-08-14  9:10   ` Dave Martin
2019-08-13 14:16 ` [PATCH 3/3] arm64: constify sys64_hook instances Mark Rutland
2019-08-14  9:12   ` Dave Martin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).