diff options
| author | Sean Christopherson <[email protected]> | 2024-11-01 18:35:52 +0000 |
|---|---|---|
| committer | Sean Christopherson <[email protected]> | 2024-11-05 04:57:46 +0000 |
| commit | 7d1cb7cee94ffd913cb3b70aa1c3538f195c1f23 (patch) | |
| tree | 45ca88b358a9f418626344afbcdef73862b2b1e6 /rust/helpers/helpers.c | |
| parent | KVM: x86: Move kvm_set_apic_base() implementation to lapic.c (from x86.c) (diff) | |
| download | kernel-7d1cb7cee94ffd913cb3b70aa1c3538f195c1f23.tar.gz kernel-7d1cb7cee94ffd913cb3b70aa1c3538f195c1f23.zip | |
KVM: x86: Rename APIC base setters to better capture their relationship
Rename kvm_set_apic_base() and kvm_lapic_set_base() to kvm_apic_set_base()
and __kvm_apic_set_base() respectively to capture that the underscores
version is a "special" variant (it exists purely to avoid recalculating
the optimized map multiple times when stuffing the RESET value).
Opportunistically add a comment explaining why kvm_lapic_reset() uses the
inner helper. Note, KVM deliberately invokes kvm_arch_vcpu_create() while
kvm->lock is NOT held so that vCPU setup isn't serialized if userspace is
creating multiple/all vCPUs in parallel. I.e. triggering an extra
recalculation is not limited to theoretical/rare edge cases, and so is
worth avoiding.
No functional change intended.
Reviewed-by: Kai Huang <[email protected]>
Reviewed-by: Paolo Bonzini <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Sean Christopherson <[email protected]>
Diffstat (limited to 'rust/helpers/helpers.c')
0 files changed, 0 insertions, 0 deletions
