]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86/mmu: constify uses of struct kvm_mmu_role_regs
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 10 Feb 2022 12:30:20 +0000 (07:30 -0500)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 29 Apr 2022 16:49:17 +0000 (12:49 -0400)
commitde23e7cf5a12c31021cadada337c757e9c9cfa94
tree14f9e67e4a7e4208d68bdc210e19fa94ceeb68a3
parent1ce3a589a1f0fe053b97fc6bc622ecf3b5402ff5
KVM: x86/mmu: constify uses of struct kvm_mmu_role_regs

struct kvm_mmu_role_regs is computed just once and then accessed.  Use
const to make this clearer, even though the const fields of struct
kvm_mmu_role_regs already prevent (or make it harder...) to modify
the contents of the struct.

Reviewed-by: David Matlack <dmatlack@google.com>
Reviewed-by: Sean Christopherson <seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/mmu/mmu.c