All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v2 0/6] s390x/vfio: VFIO-AP interrupt control interception
@ 2018-11-22 16:35 Pierre Morel
  2018-11-22 16:35 ` [Qemu-devel] [PATCH v2 1/6] s390x/vfio: ap: Finding the AP bridge Pierre Morel
                   ` (6 more replies)
  0 siblings, 7 replies; 28+ messages in thread
From: Pierre Morel @ 2018-11-22 16:35 UTC (permalink / raw)
  To: borntraeger
  Cc: cohuck, agraf, rth, david, qemu-s390x, qemu-devel, peter.maydell,
	pbonzini, mst, eric.auger, akrowiak, pasic

This series has 3 different type of patches:

The first two:
  s390x/vfio: ap: Finding the AP bridge
  s390x/vfio: ap: Use the APdevice as a child of the APBus

Are dealing with the QEMU Object Model and how we retrieve the
AP devices from instruction interception.
A lifting of the AP bridge, bus and device was necessary to
ease the process and allow future extensions.

The third one is a place holder to ease reviewing:
  s390x/vfio: ap: Linux uapi VFIO place holder

The last three are really dealing with PQAP/AQIC instruction
interception and associate IOCTL calls to the VFIO AP device
driver.
  s390x/cpumodel: Set up CPU model for AQIC interception
  s390x/vfio: ap: Definition for AP Adapter type
  s390x/vfio: ap: Implementing AP Queue Interrupt Control

The S390 APQP/AQIC instruction is intercepted by the host
to configure the AP queues interruption redirection.
It retrieves the ISC used by the host and the one used
by the guest and setup the indicator address.

This patch series
- define the AQIC feature in the cpumodel,
- extend the APDevice type for per card and queue interrupt handling,
- intercept the APQP/AQIC instruction, uses the S390 adapter interface
  to setup the adapter 
- and use a VFIO ioctl to let the VFIO-AP driver handle the host
  instruction associated with the intercepted guest instruction.

This patch serie can be tested with the Linux/KVM patch series
for the VFIO-AP driver: "s390: vfio: ap: Using GISA for AP Interrupt"


Pierre Morel (6):
  s390x/vfio: ap: Finding the AP bridge
  s390x/vfio: ap: Use the APdevice as a child of the APBus
  s390x/vfio: ap: Linux uapi VFIO place holder
  s390x/cpumodel: Set up CPU model for AQIC interception
  s390x/vfio: ap: Definition for AP Adapter type
  s390x/vfio: ap: Implementing AP Queue Interrupt Control

 hw/s390x/ap-bridge.c            |  12 ++++
 hw/s390x/ap-device.c            |  22 +++++++
 hw/vfio/ap.c                    | 131 +++++++++++++++++++++++++++++++++++++---
 include/hw/s390x/ap-bridge.h    |   1 +
 include/hw/s390x/ap-device.h    |  65 ++++++++++++++++++++
 include/hw/s390x/css.h          |   1 +
 linux-headers/linux/vfio.h      |  25 ++++++++
 target/s390x/cpu_features.c     |   1 +
 target/s390x/cpu_features_def.h |   1 +
 target/s390x/cpu_models.c       |   1 +
 target/s390x/gen-features.c     |   1 +
 target/s390x/kvm.c              |  31 ++++++++++
 12 files changed, 282 insertions(+), 10 deletions(-)

-- 
2.7.4

Changelog from v1:
- legitimate "Huh" from Conny on global lead me to reconsider
  the QOM for AP Device, BUS and Bridge and remove globals
- squash patches for kvm.c and hw/vfio/ap.c
  (Conny) so related changes are easier to see
- modified the UAPI (Also comes from Linux)
- suppressed complicated structures to integer conversions
  and use masks to avoid endianess considerations,
  I did not change anything for endianess since we get all
  from the registers, AFAIU we do not need to.
  Tell me if I am wrong (I know you will :) )
- simplified the implementation of the ioctl

Tested with according Linux patch.
Take care that the UAPI changed betwen V1 and V2!
and do NOT use with the older version.

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

end of thread, other threads:[~2018-12-05 17:23 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-22 16:35 [Qemu-devel] [PATCH v2 0/6] s390x/vfio: VFIO-AP interrupt control interception Pierre Morel
2018-11-22 16:35 ` [Qemu-devel] [PATCH v2 1/6] s390x/vfio: ap: Finding the AP bridge Pierre Morel
2018-11-29 11:41   ` Cornelia Huck
2018-11-29 20:30   ` Tony Krowiak
2018-11-30  9:09     ` Pierre Morel
2018-11-22 16:35 ` [Qemu-devel] [PATCH v2 2/6] s390x/vfio: ap: Use the APdevice as a child of the APBus Pierre Morel
2018-11-29 11:45   ` Cornelia Huck
2018-11-29 12:36     ` Pierre Morel
2018-11-29 15:02     ` Tony Krowiak
2018-11-29 15:11       ` Cornelia Huck
2018-11-29 16:26         ` Pierre Morel
2018-11-29 20:42   ` Tony Krowiak
2018-11-30  9:31     ` Pierre Morel
2018-11-30 12:03       ` Pierre Morel
2018-11-30 15:58       ` Tony Krowiak
2018-12-03  8:02         ` Pierre Morel
2018-12-05 17:22   ` [Qemu-devel] [qemu-s390x] " Halil Pasic
2018-11-22 16:35 ` [Qemu-devel] [PATCH v2 3/6] s390x/vfio: ap: Linux uapi VFIO place holder Pierre Morel
2018-11-22 16:35 ` [Qemu-devel] [PATCH v2 4/6] s390x/cpumodel: Set up CPU model for AQIC interception Pierre Morel
2018-11-29 20:43   ` Tony Krowiak
2018-11-22 16:35 ` [Qemu-devel] [PATCH v2 5/6] s390x/vfio: ap: Definition for AP Adapter type Pierre Morel
2018-11-22 16:35 ` [Qemu-devel] [PATCH v2 6/6] s390x/vfio: ap: Implementing AP Queue Interrupt Control Pierre Morel
2018-11-29 21:53   ` Tony Krowiak
2018-11-30  8:36     ` Cornelia Huck
2018-11-30 11:54     ` Pierre Morel
2018-11-29 15:55 ` [Qemu-devel] [PATCH v2 0/6] s390x/vfio: VFIO-AP interrupt control interception Halil Pasic
2018-11-30 13:01   ` Pierre Morel
2018-11-30 13:31     ` Halil Pasic

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.