Skip to content

s390x: sie: Add PV snippet support

Janosch Frank kvm linux-s390 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest10 patches 5 repliesIn review
  2. v18 patches 13 repliesSuperseded

Changes in v2 from the cover letter

- Moved snippet management code into library uv.h and snippet.h files
- Added a fixpatch for mvpg-sie.c making it use the snippet helpers

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/10lib: s390x: sie: Add sca allocation and freeinglib/s390x/sie.c lib/s390x/sie.h+14 -00 replies
2/10s390x: sie: Add PV fields to SIE control blocklib/s390x/sie.h+34 -70 replies
3/10s390x: sie: Add UV information into VM structlib/s390x/sie.h+6 -00 replies
4/10s390x: uv: Add more UV call functionslib/s390x/asm/uv.h+85 -00 replies
5/10s390x: lib: Extend UV library with PV guest managementlib/s390x/asm/uv.h lib/s390x/sie.h lib/s390x/uv.c +1 more+152 -00 replies
6/10lib: s390: sie: Add PV guest register handlinglib/s390x/sie.c lib/s390x/sie.h+10 -00 replies
7/10s390x: snippets: Add PV support.gitignore configure lib/s390x/snippet.h +1 more+73 -111 reply
8/10lib: s390x: Introduce snippet helperslib/s390x/snippet.h lib/s390x/uv.h+124 -02 replies
9/10s390x: mvpg-sie: Use snippet helperss390x/mvpg-sie.c+8 -161 reply
10/10s390x: sie: Add PV diag tests390x/Makefile s390x/pv-diags.c s390x/snippets/asm/snippet-pv-diag-288.S +2 more+264 -01 reply

Reviews trailers per patch

All 10 patches have a Reviewed-by or Acked-by.

PatchClaudio Imbrenda
1/10R-b
2/10R-b
3/10R-b
4/10R-b
5/10R-b
6/10R-b
7/10A-b
8/10R-b
9/10R-b
10/10R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [kvm-unit-tests PATCH v2 00/10] s390x: sie: Add PV snippet support

Adding PV virtualization support was only a matter of time so here it is.

The biggest problem that needed solving was having the SE header as a separate file. The genprotimg tool generates the header and adds a short bit of code to the image which will put the guest into PV mode via the diagnose 308 PV subcodes. We don't have and want an emulation for the diagnose so we don't support this way of starting a PV guest.

Therefore we needed a new tool that generates the PV image separate from the SE header so we can link both as binary blobs. Marc created this tool by writing a library which lets users create a SE header and has bindings to multiple languages. Unfortunately we didn't yet have time to upstream this but we plan to publish it once we find some.

The first PV snippet test checks the "easy" diagnose calls 0x44, 0x9c, 0x288 and 0x500. We check register contents and responses to PGM injects.

v2:
- Moved snippet management code into library uv.h and snippet.h files
- Added a fixpatch for mvpg-sie.c making it use the snippet helpers

Janosch Frank (10):
lib: s390x: sie: Add sca allocation and freeing
s390x: sie: Add PV fields to SIE control block
s390x: sie: Add UV information into VM struct
s390x: uv: Add more UV call functions
s390x: lib: Extend UV library with PV guest management
lib: s390: sie: Add PV guest register handling
s390x: snippets: Add PV support
lib: s390x: Introduce snippet helpers
s390x: mvpg-sie: Use snippet helpers
s390x: sie: Add PV diag test

 .gitignore                                 |   2 +
 configure                                  |   8 +
 lib/s390x/asm/uv.h                         |  99 +++++++++++
 lib/s390x/sie.c                            |  20 +++
 lib/s390x/sie.h                            |  54 +++++-
 lib/s390x/snippet.h                        | 110 ++++++++++++
 lib/s390x/uv.c                             | 128 ++++++++++++++
 lib/s390x/uv.h                             |  28 +++
 s390x/Makefile                             |  73 ++++++--
 s390x/mvpg-sie.c                           |  24 +--
 s390x/pv-diags.c                           | 187 +++++++++++++++++++++
 s390x/snippets/asm/snippet-pv-diag-288.S   |  25 +++
 s390x/snippets/asm/snippet-pv-diag-500.S   |  39 +++++
 s390x/snippets/asm/snippet-pv-diag-yield.S |   7 +
 14 files changed, 770 insertions(+), 34 deletions(-)
 create mode 100644 s390x/pv-diags.c
 create mode 100644 s390x/snippets/asm/snippet-pv-diag-288.S
 create mode 100644 s390x/snippets/asm/snippet-pv-diag-500.S
 create mode 100644 s390x/snippets/asm/snippet-pv-diag-yield.S
Signature · 1 line
2.32.0