summaryrefslogtreecommitdiffstats
path: root/arch/arm64/include/asm/kvm_coproc.h
diff options
context:
space:
mode:
authorJames Morse <james.morse@arm.com>2020-06-22 11:33:13 +0000
committerMarc Zyngier <maz@kernel.org>2020-07-05 18:20:45 +0100
commit6b33e0d64f8501b51d32069e08d3ed68c58c25b4 (patch)
treeeba81e25cf7fa39a93ad97e5fd6479018611ac0b /arch/arm64/include/asm/kvm_coproc.h
parentb3a9e3b9622ae10064826dccb4f7a52bd88c7407 (diff)
downloadlinux-6b33e0d64f8501b51d32069e08d3ed68c58c25b4.tar.bz2
KVM: arm64: Drop the target_table[] indirection
KVM for 32bit arm had a get/set target mechanism to allow for micro-architecture differences that are visible in system registers to be described. KVM's user-space can query the supported targets for a CPU, and create vCPUs for that target. The target can override the handling of system registers to provide different reset or RES0 behaviour. On 32bit arm this was used to provide different ACTLR reset values for A7 and A15. On 64bit arm, the first few CPUs out of the gate used this mechanism, before it was deemed redundant in commit bca556ac468a ("arm64/kvm: Add generic v8 KVM target"). All future CPUs use the KVM_ARM_TARGET_GENERIC_V8 target. The 64bit target_table[] stuff exists to preserve the ABI to user-space. As all targets registers genericv8_target_table, there is no reason to look the target up. Until we can merge genericv8_target_table with the main sys_regs array, kvm_register_target_sys_reg_table() becomes kvm_check_target_sys_reg_table(), which uses BUG_ON() in keeping with the other callers in this file. Signed-off-by: James Morse <james.morse@arm.com> Signed-off-by: Marc Zyngier <maz@kernel.org> Link: https://lore.kernel.org/r/20200622113317.20477-2-james.morse@arm.com
Diffstat (limited to 'arch/arm64/include/asm/kvm_coproc.h')
-rw-r--r--arch/arm64/include/asm/kvm_coproc.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/arm64/include/asm/kvm_coproc.h b/arch/arm64/include/asm/kvm_coproc.h
index 0185ee8b8b5e..4bf0d6d05e0f 100644
--- a/arch/arm64/include/asm/kvm_coproc.h
+++ b/arch/arm64/include/asm/kvm_coproc.h
@@ -24,8 +24,7 @@ struct kvm_sys_reg_target_table {
struct kvm_sys_reg_table table32;
};
-void kvm_register_target_sys_reg_table(unsigned int target,
- struct kvm_sys_reg_target_table *table);
+void kvm_check_target_sys_reg_table(struct kvm_sys_reg_target_table *table);
int kvm_handle_cp14_load_store(struct kvm_vcpu *vcpu, struct kvm_run *run);
int kvm_handle_cp14_32(struct kvm_vcpu *vcpu, struct kvm_run *run);