public inbox for linux-s390@vger.kernel.org
 help / color / mirror / Atom feed
From: David Hildenbrand <david@redhat.com>
To: linux-s390@vger.kernel.org, kvm@vger.kernel.org
Subject: Re: [PATCH 2/2] KVM: add machine check counter kvm_stat
Date: Mon, 05 Mar 2018 12:56:59 +0000	[thread overview]
Message-ID: <f2a49129-1674-eb46-67ac-23a577ef4d31@redhat.com> (raw)
In-Reply-To: <20180305122222.37f2ceb7.cohuck@redhat.com>

On 05.03.2018 12:16, Christian Borntraeger wrote:
> From: QingFeng Hao <haoqf@linux.vnet.ibm.com>
> 
> This counter can be used for administration, debug or test purpose.
> 
> Suggested-by: Vladislav Mironov <mironov@de.ibm.com>
> Signed-off-by: QingFeng Hao <haoqf@linux.vnet.ibm.com>
> Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
> ---
>  arch/s390/include/asm/kvm_host.h | 1 +
>  arch/s390/kvm/interrupt.c        | 1 +
>  arch/s390/kvm/kvm-s390.c         | 1 +
>  3 files changed, 3 insertions(+)
> 
> diff --git a/arch/s390/include/asm/kvm_host.h b/arch/s390/include/asm/kvm_host.h
> index 22615af0b6e6..77a49de9c511 100644
> --- a/arch/s390/include/asm/kvm_host.h
> +++ b/arch/s390/include/asm/kvm_host.h
> @@ -320,6 +320,7 @@ struct kvm_vcpu_stat {
>  	u64 deliver_restart_signal;
>  	u64 deliver_program_int;
>  	u64 deliver_io_int;
> +	u64 deliver_machine_check;
>  	u64 exit_wait_state;
>  	u64 instruction_epsw;
>  	u64 instruction_gs;
> diff --git a/arch/s390/kvm/interrupt.c b/arch/s390/kvm/interrupt.c
> index b04616b57a94..bde04a6191ca 100644
> --- a/arch/s390/kvm/interrupt.c
> +++ b/arch/s390/kvm/interrupt.c
> @@ -595,6 +595,7 @@ static int __must_check __deliver_machine_check(struct kvm_vcpu *vcpu)
>  		trace_kvm_s390_deliver_interrupt(vcpu->vcpu_id,
>  						 KVM_S390_MCHK,
>  						 mchk.cr14, mchk.mcic);
> +		vcpu->stat.deliver_machine_check++;
>  		rc = __write_machine_check(vcpu, &mchk);
>  	}
>  	return rc;
> diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c
> index 6ee1d13a72f9..432277ad2114 100644
> --- a/arch/s390/kvm/kvm-s390.c
> +++ b/arch/s390/kvm/kvm-s390.c
> @@ -88,6 +88,7 @@ struct kvm_stats_debugfs_item debugfs_entries[] = {
>  	{ "deliver_restart_signal", VCPU_STAT(deliver_restart_signal) },
>  	{ "deliver_program_interruption", VCPU_STAT(deliver_program_int) },
>  	{ "deliver_io_interrupt", VCPU_STAT(deliver_io_int) },
> +	{ "deliver_machine_check", VCPU_STAT(deliver_machine_check) },
>  	{ "exit_wait_state", VCPU_STAT(exit_wait_state) },
>  	{ "instruction_epsw", VCPU_STAT(instruction_epsw) },
>  	{ "instruction_gs", VCPU_STAT(instruction_gs) },
> 


Reviewed-by: David Hildenbrand <david@redhat.com>

-- 

Thanks,

David / dhildenb

           reply	other threads:[~2018-03-05 12:56 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <20180305122222.37f2ceb7.cohuck@redhat.com>]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f2a49129-1674-eb46-67ac-23a577ef4d31@redhat.com \
    --to=david@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-s390@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox