OSDN Git Service

KVM: Update halt-polling stats if and only if halt-polling was attempted
authorSean Christopherson <seanjc@google.com>
Sat, 9 Oct 2021 02:11:58 +0000 (19:11 -0700)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 8 Dec 2021 09:24:47 +0000 (04:24 -0500)
commit8df6a61c04038fa481a717fc86af38304aa600a3
tree7034636766d1044824e34478e44adc060aa4ae6e
parent510958e997217e39a16b47afb5a44dfa39013964
KVM: Update halt-polling stats if and only if halt-polling was attempted

Don't update halt-polling stats if halt-polling wasn't attempted.  This is
a nop as @poll_ns is guaranteed to be '0' (poll_end == start); in a future
patch (to move the histogram stats into the helper), it will avoid to
avoid a discrepancy in what is considered a "successful" halt-poll.

No functional change intended.

Reviewed-by: David Matlack <dmatlack@google.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20211009021236.4122790-6-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
virt/kvm/kvm_main.c