]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: SEV-ES: clean up kvm_sev_es_ins/outs
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 12 Oct 2021 14:51:55 +0000 (10:51 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 22 Oct 2021 14:02:20 +0000 (10:02 -0400)
commitb53a4c088254606fc3089bc3ee525cfe98f67c9d
tree6cdd8a52469f6fb7f9ea4bee09b3eb7c94965ade
parent10309f244bf0bac0fbdef70af23e9b2e2c199259
KVM: SEV-ES: clean up kvm_sev_es_ins/outs

A few very small cleanups to the functions, smushed together because
the patch is already very small like this:

- inline emulator_pio_in_emulated and emulator_pio_out_emulated,
  since we already have the vCPU

- remove the data argument and pull setting vcpu->arch.sev_pio_data into
  the caller

- remove unnecessary clearing of vcpu->arch.pio.count when
  emulation is done by the kernel (and therefore vcpu->arch.pio.count
  is already clear on exit from emulator_pio_in and emulator_pio_out).

No functional change intended.

Cc: stable@vger.kernel.org
Fixes: a15bb587483f ("KVM: SVM: Support string IO operations for an SEV-ES guest")
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c