All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] Remove duplicated stats definitions for debugfs
@ 2021-06-14  2:53 ` Jing Zhang
  0 siblings, 0 replies; 34+ messages in thread
From: Jing Zhang @ 2021-06-14  2:53 UTC (permalink / raw)
  To: KVM, KVMARM, LinuxMIPS, KVMPPC, LinuxS390, Paolo Bonzini, Fuad Tabba
  Cc: Jing Zhang

This is a follow-up patchset to binary stats interface patchset as below:
https://lore.kernel.org/kvm/20210611124624.1404010-1-jingzhangos@google.com

This patchset contains a commit to fix some missing stats and add static
check to make sure we have the right number of stats descriptors and add an
'offset' field in stats descriptor to make sure the or order of stats
descriptors is not relevant to the order of stats in vm/vcpu stats
structure. This will totally avoid the possibility of missing stats and
mismatched stats definitions.

The binary stats interface defines stats in another array of descriptors,
while the original stats debugfs interface uses array of kvm_stats_debugfs
item. To remove the duplicated stats definition, this patchset would
utilize only the stats descriptors to provide stats information to debugfs
interface. This patchset adds a 'mode' flag to support the read/write mode
of stats, which can be used to indicate the file permission of debugfs
stats files. It removes the usage of kvm_stats_debugfs_item and all the
debugfs_entries defined in all archs.

The patch also fixes an issue that read only stats could be cleared in
global level, though not permitted in VM level in the original debugfs
code.

---

Jing Zhang (4):
  KVM: stats: Make sure no missing or mismatched binary stats definition
  KVM: stats: Use binary stats descriptors for debugfs interface
  KVM: stats: Update documentation supporting stats mode and offset
  KVM: selftests: Update binary stats test for stats mode

 Documentation/virt/kvm/api.rst                |  33 +-
 arch/arm64/kvm/guest.c                        |  32 +-
 arch/mips/kvm/mips.c                          |  99 ++----
 arch/powerpc/kvm/book3s.c                     | 101 ++----
 arch/powerpc/kvm/booke.c                      |  79 ++---
 arch/s390/kvm/kvm-s390.c                      | 307 ++++++------------
 arch/x86/kvm/x86.c                            | 120 +++----
 include/linux/kvm_host.h                      | 186 ++++++-----
 include/uapi/linux/kvm.h                      |  11 +-
 .../selftests/kvm/kvm_binary_stats_test.c     |  13 +-
 virt/kvm/kvm_main.c                           | 105 ++++--
 11 files changed, 477 insertions(+), 609 deletions(-)


base-commit: 39be2e28180a2e87af5fbb8d83643812e1a3b371
-- 
2.32.0.272.g935e593368-goog


^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2021-06-16 12:55 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-14  2:53 [PATCH 0/4] Remove duplicated stats definitions for debugfs Jing Zhang
2021-06-14  2:53 ` Jing Zhang
2021-06-14  2:53 ` [PATCH 1/4] KVM: stats: Make sure no missing or mismatched binary stats definition Jing Zhang
2021-06-14  2:53   ` Jing Zhang
2021-06-14  2:53   ` Jing Zhang
2021-06-14  9:49   ` Fuad Tabba
2021-06-14  9:49     ` Fuad Tabba
2021-06-14  9:49     ` Fuad Tabba
2021-06-14 13:28     ` Jing Zhang
2021-06-14 13:28       ` Jing Zhang
2021-06-14 13:28       ` Jing Zhang
2021-06-16 12:55   ` kernel test robot
2021-06-16 12:55     ` kernel test robot
2021-06-16 12:55     ` kernel test robot
2021-06-16 12:55     ` kernel test robot
2021-06-14  2:53 ` [PATCH 2/4] KVM: stats: Use binary stats descriptors for debugfs interface Jing Zhang
2021-06-14  2:53   ` Jing Zhang
2021-06-14  2:53   ` Jing Zhang
2021-06-14  9:51   ` Paolo Bonzini
2021-06-14  9:51     ` Paolo Bonzini
2021-06-14  9:51     ` Paolo Bonzini
2021-06-14 13:36     ` Jing Zhang
2021-06-14 13:36       ` Jing Zhang
2021-06-14 13:36       ` Jing Zhang
2021-06-14  2:53 ` [PATCH 3/4] KVM: stats: Update documentation supporting stats mode and offset Jing Zhang
2021-06-14  2:53   ` Jing Zhang
2021-06-14  2:53 ` [PATCH 4/4] KVM: selftests: Update binary stats test for stats mode Jing Zhang
2021-06-14  2:53   ` Jing Zhang
2021-06-14  9:53 ` [PATCH 0/4] Remove duplicated stats definitions for debugfs Paolo Bonzini
2021-06-14  9:53   ` Paolo Bonzini
2021-06-14  9:53   ` Paolo Bonzini
2021-06-14 13:38   ` Jing Zhang
2021-06-14 13:38     ` Jing Zhang
2021-06-14 13:38     ` Jing Zhang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.