]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: arm64: Consolidate sysreg userspace accesses
authorMarc Zyngier <maz@kernel.org>
Mon, 4 Jul 2022 16:27:00 +0000 (17:27 +0100)
committerMarc Zyngier <maz@kernel.org>
Sun, 17 Jul 2022 10:55:33 +0000 (11:55 +0100)
commitdc5f425e54303d0ed68deb99a355cdfb3f404ff3
tree12ab69ff026780227bdb956b4b51cef9354ac26f
parent85f07bdd721ec661f3a1c3b69b46e101c6175c3f
KVM: arm64: Consolidate sysreg userspace accesses

Until now, the .set_user and .get_user callbacks have to implement
(directly or not) the userspace memory accesses. Although this gives
us maximem flexibility, this is also a maintenance burden, making it
hard to audit, and I'd feel much better if it was all located in
a single place.

So let's do just that, simplifying most of the function signatures
in the process (the callbacks are now only concerned with the
data itself, and not with userspace).

Reviewed-by: Reiji Watanabe <reijiw@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
arch/arm64/kvm/sys_regs.c
arch/arm64/kvm/sys_regs.h