Re: [PATCH v2 15/30] KVM: s390: pci: do initial setup for AEN interpretation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 1/25/22 7:23 AM, Pierre Morel wrote:


On 1/14/22 21:31, Matthew Rosato wrote:
Initial setup for Adapter Event Notification Interpretation for zPCI
passthrough devices.  Specifically, allocate a structure for forwarding of
adapter events and pass the address of this structure to firmware.

Signed-off-by: Matthew Rosato <mjrosato@xxxxxxxxxxxxx>
---
  arch/s390/include/asm/pci.h      |   4 +
  arch/s390/include/asm/pci_insn.h |  12 +++
  arch/s390/kvm/interrupt.c        |  14 +++
  arch/s390/kvm/kvm-s390.c         |   9 ++
  arch/s390/kvm/pci.c              | 144 +++++++++++++++++++++++++++++++
  arch/s390/kvm/pci.h              |  42 +++++++++
  arch/s390/pci/pci.c              |   6 ++
  7 files changed, 231 insertions(+)
  create mode 100644 arch/s390/kvm/pci.h

...snip...

new file mode 100644
index 000000000000..b2000ed7b8c3
--- /dev/null
+++ b/arch/s390/kvm/pci.h
@@ -0,0 +1,42 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+/*
+ * s390 kvm PCI passthrough support
+ *
+ * Copyright IBM Corp. 2021
+ *
+ *    Author(s): Matthew Rosato <mjrosato@xxxxxxxxxxxxx>
+ */
+
+#ifndef __KVM_S390_PCI_H
+#define __KVM_S390_PCI_H
+
+#include <linux/pci.h>
+#include <linux/mutex.h>
+#include <asm/airq.h>
+#include <asm/kvm_pci.h>
+
+struct zpci_gaite {
+    u32 gisa;
+    u8 gisc;
+    u8 count;
+    u8 reserved;
+    u8 aisbo;
+    u64 aisb;
+};
+
+struct zpci_aift {
+    struct zpci_gaite *gait;
+    struct airq_iv *sbv;
+    struct kvm_zdev **kzdev;
+    spinlock_t gait_lock; /* Protects the gait, used during AEN forward */
+    struct mutex lock; /* Protects the other structures in aift */

To facilitate review and debug, can we please rename the lock aift_lock?



OK, sure




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux