Re: [PATCH v7 1/4] KVM: stats: Separate generic stats from architecture specific ones

Christian Borntraeger
2021-06-11T06:58:07Z

On 03.06.21 23:14, Jing Zhang wrote:
> Put all generic statistics in a separate structure to ease
> statistics handling for the incoming new statistics API.
>
> No functional change intended.
>
> Reviewed-by: David Matlack <dmatlack@google.com>
> Reviewed-by: Ricardo Koller <ricarkol@google.com>
> Signed-off-by: Jing Zhang <jingzhangos@google.com>
[...]
> diff --git a/arch/s390/include/asm/kvm_host.h b/arch/s390/include/asm/kvm_host.h
> index 8925f3969478..9b4473f76e56 100644
> --- a/arch/s390/include/asm/kvm_host.h
> +++ b/arch/s390/include/asm/kvm_host.h
[...]
> @@ -755,12 +750,12 @@ struct kvm_vcpu_arch {
> };
>
> struct kvm_vm_stat {
> + struct kvm_vm_stat_generic generic;

s390 does not have remote_tlb_flush. I guess this does not hurt?

> u64 inject_io;
> u64 inject_float_mchk;
> u64 inject_pfault_done;
> u64 inject_service_signal;
> u64 inject_virtio;
> - u64 remote_tlb_flush;
> };
[...]
> +struct kvm_vm_stat_generic {
> + ulong remote_tlb_flush;
> +};