Blame SOURCES/kvm-redhat-Update-linux-headers-linux-kvm.h-to-v5.18-rc6.patch

62547e
From 21b19213328826327eba18199b790425659af7d8 Mon Sep 17 00:00:00 2001
62547e
From: Thomas Huth <thuth@redhat.com>
62547e
Date: Fri, 29 Jul 2022 16:55:34 +0200
62547e
Subject: [PATCH 1/3] redhat: Update linux-headers/linux/kvm.h to v5.18-rc6
62547e
MIME-Version: 1.0
62547e
Content-Type: text/plain; charset=UTF-8
62547e
Content-Transfer-Encoding: 8bit
62547e
62547e
RH-Author: Cédric Le Goater <None>
62547e
RH-MergeRequest: 220: s390x: Fix skey test in kvm_unit_test
62547e
RH-Bugzilla: 2124757
62547e
RH-Acked-by: Thomas Huth <thuth@redhat.com>
62547e
RH-Acked-by: David Hildenbrand <david@redhat.com>
62547e
RH-Acked-by: Cornelia Huck <cohuck@redhat.com>
62547e
RH-Commit: [1/2] e514a00305cb0caab9d3acc0efb325853daa6d51
62547e
62547e
Upstream Status: RHEL-only
62547e
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2124757
62547e
62547e
Based on upstream commit e4082063e47e9731dbeb1c26174c17f6038f577f
62547e
("linux-headers: Update to v5.18-rc6"), but this is focusing on
62547e
the file linux-headers/linux/kvm.h only (since the other changes
62547e
related to the VFIO renaming might break some stuff).
62547e
62547e
Signed-off-by: Thomas Huth <thuth@redhat.com>
62547e
(cherry picked from commit 71516db15469a02600932a5c1f0d4a9626a91193)
62547e
Signed-off-by: Cédric Le Goater <clg@redhat.com>
62547e
---
62547e
 linux-headers/linux/kvm.h | 27 +++++++++++++++++++++------
62547e
 1 file changed, 21 insertions(+), 6 deletions(-)
62547e
62547e
diff --git a/linux-headers/linux/kvm.h b/linux-headers/linux/kvm.h
62547e
index d232feaae9..0d05d02ee4 100644
62547e
--- a/linux-headers/linux/kvm.h
62547e
+++ b/linux-headers/linux/kvm.h
62547e
@@ -445,7 +445,11 @@ struct kvm_run {
62547e
 #define KVM_SYSTEM_EVENT_RESET          2
62547e
 #define KVM_SYSTEM_EVENT_CRASH          3
62547e
 			__u32 type;
62547e
-			__u64 flags;
62547e
+			__u32 ndata;
62547e
+			union {
62547e
+				__u64 flags;
62547e
+				__u64 data[16];
62547e
+			};
62547e
 		} system_event;
62547e
 		/* KVM_EXIT_S390_STSI */
62547e
 		struct {
62547e
@@ -562,9 +566,12 @@ struct kvm_s390_mem_op {
62547e
 	__u32 op;		/* type of operation */
62547e
 	__u64 buf;		/* buffer in userspace */
62547e
 	union {
62547e
-		__u8 ar;	/* the access register number */
62547e
+		struct {
62547e
+			__u8 ar;	/* the access register number */
62547e
+			__u8 key;	/* access key, ignored if flag unset */
62547e
+		};
62547e
 		__u32 sida_offset; /* offset into the sida */
62547e
-		__u8 reserved[32]; /* should be set to 0 */
62547e
+		__u8 reserved[32]; /* ignored */
62547e
 	};
62547e
 };
62547e
 /* types for kvm_s390_mem_op->op */
62547e
@@ -572,9 +579,12 @@ struct kvm_s390_mem_op {
62547e
 #define KVM_S390_MEMOP_LOGICAL_WRITE	1
62547e
 #define KVM_S390_MEMOP_SIDA_READ	2
62547e
 #define KVM_S390_MEMOP_SIDA_WRITE	3
62547e
+#define KVM_S390_MEMOP_ABSOLUTE_READ	4
62547e
+#define KVM_S390_MEMOP_ABSOLUTE_WRITE	5
62547e
 /* flags for kvm_s390_mem_op->flags */
62547e
 #define KVM_S390_MEMOP_F_CHECK_ONLY		(1ULL << 0)
62547e
 #define KVM_S390_MEMOP_F_INJECT_EXCEPTION	(1ULL << 1)
62547e
+#define KVM_S390_MEMOP_F_SKEY_PROTECTION	(1ULL << 2)
62547e
 
62547e
 /* for KVM_INTERRUPT */
62547e
 struct kvm_interrupt {
62547e
@@ -1134,6 +1144,12 @@ struct kvm_ppc_resize_hpt {
62547e
 #define KVM_CAP_VM_GPA_BITS 207
62547e
 #define KVM_CAP_XSAVE2 208
62547e
 #define KVM_CAP_SYS_ATTRIBUTES 209
62547e
+#define KVM_CAP_PPC_AIL_MODE_3 210
62547e
+#define KVM_CAP_S390_MEM_OP_EXTENSION 211
62547e
+#define KVM_CAP_PMU_CAPABILITY 212
62547e
+#define KVM_CAP_DISABLE_QUIRKS2 213
62547e
+/* #define KVM_CAP_VM_TSC_CONTROL 214 */
62547e
+#define KVM_CAP_SYSTEM_EVENT_DATA 215
62547e
 
62547e
 #ifdef KVM_CAP_IRQ_ROUTING
62547e
 
62547e
@@ -1624,9 +1640,6 @@ struct kvm_enc_region {
62547e
 #define KVM_S390_NORMAL_RESET	_IO(KVMIO,   0xc3)
62547e
 #define KVM_S390_CLEAR_RESET	_IO(KVMIO,   0xc4)
62547e
 
62547e
-/* Available with KVM_CAP_XSAVE2 */
62547e
-#define KVM_GET_XSAVE2		  _IOR(KVMIO,  0xcf, struct kvm_xsave)
62547e
-
62547e
 struct kvm_s390_pv_sec_parm {
62547e
 	__u64 origin;
62547e
 	__u64 length;
62547e
@@ -1973,6 +1986,8 @@ struct kvm_dirty_gfn {
62547e
 #define KVM_BUS_LOCK_DETECTION_OFF             (1 << 0)
62547e
 #define KVM_BUS_LOCK_DETECTION_EXIT            (1 << 1)
62547e
 
62547e
+#define KVM_PMU_CAP_DISABLE                    (1 << 0)
62547e
+
62547e
 /**
62547e
  * struct kvm_stats_header - Header of per vm/vcpu binary statistics data.
62547e
  * @flags: Some extra information for header, always 0 for now.
62547e
-- 
62547e
2.35.3
62547e