public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [kvm-unit-tests PATCH 0/1] s390x: stsi: Define vm_is_kvm to be used in different tests
@ 2022-02-15 10:46 Pierre Morel
  2022-02-15 10:46 ` [kvm-unit-tests PATCH 1/1] " Pierre Morel
  0 siblings, 1 reply; 9+ messages in thread
From: Pierre Morel @ 2022-02-15 10:46 UTC (permalink / raw)
  To: linux-s390; +Cc: frankja, thuth, kvm, cohuck, imbrenda, david, nrb

Several tests are in need of a way to check on which hypervisor
and virtualization level they are running on to be able to fence
certain tests. This patch adds functions that return true if a
vm is running under KVM, LPAR or generally as a level 2 guest.
 
To check if we're running under KVM we use the STSI 3.2.2
instruction, let's define it's response structure in a central
header.

Pierre Morel (1):
  s390x: stsi: Define vm_is_kvm to be used in different tests

 lib/s390x/stsi.h | 32 ++++++++++++++++++++++++++++
 lib/s390x/vm.c   | 55 ++++++++++++++++++++++++++++++++++++++++++++++--
 lib/s390x/vm.h   |  3 +++
 s390x/stsi.c     | 23 ++------------------
 4 files changed, 90 insertions(+), 23 deletions(-)
 create mode 100644 lib/s390x/stsi.h

-- 
2.27.0


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

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

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-02-15 10:46 [kvm-unit-tests PATCH 0/1] s390x: stsi: Define vm_is_kvm to be used in different tests Pierre Morel
2022-02-15 10:46 ` [kvm-unit-tests PATCH 1/1] " Pierre Morel
2022-02-15 12:06   ` Claudio Imbrenda
2022-02-15 15:08     ` Janosch Frank
2022-02-15 15:21       ` Claudio Imbrenda
2022-02-15 17:30         ` Pierre Morel
2022-02-16  8:13           ` Janosch Frank
2022-02-16 12:26             ` Pierre Morel
2022-02-16 12:55               ` Janosch Frank

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox