riscv: Introduce set_kernel_memory helper
authorAlexandre Ghiti <alex@ghiti.fr>
Thu, 24 Jun 2021 12:00:40 +0000 (14:00 +0200)
committerPalmer Dabbelt <palmerdabbelt@google.com>
Thu, 1 Jul 2021 03:56:50 +0000 (20:56 -0700)
commitc10bc260e7c030364b5150aac7ebf048ddfb9502
tree73c0c95f9270ad03463ab4e0483b85e692f4469f
parent7094e6acaf7ab869a1f1c34825ba1fe3173fe350
riscv: Introduce set_kernel_memory helper

This helper should be used for setting permissions to the kernel
mapping as it takes pointers as arguments and then avoids explicit cast
to unsigned long needed for the set_memory_* API.

Suggested-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Alexandre Ghiti <alex@ghiti.fr>
Reviewed-by: Anup Patel <anup@brainfault.org>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
Reviewed-by: Jisheng Zhang <jszhang@kernel.org>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
arch/riscv/include/asm/set_memory.h