KVM: arm64: Rely on index_to_param() for size checks on userspace access
authorMarc Zyngier <maz@kernel.org>
Mon, 4 Jul 2022 16:01:50 +0000 (17:01 +0100)
committerMarc Zyngier <maz@kernel.org>
Sun, 17 Jul 2022 10:55:33 +0000 (11:55 +0100)
commite48407ff9796529a1e5048b9e4d6ea8a0334468e
tree537a4673270b63605fd31c89afa0d6d89b9429b6
parentba23aec9f4f27c00ac7a504aae60cae8a4087a19
KVM: arm64: Rely on index_to_param() for size checks on userspace access

index_to_param() already checks that we use 64bit accesses for all
registers accessed from userspace.

However, we have extra checks in other places (such as index_to_params),
which is pretty confusing. Get rid off these redundant checks.

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