yeahuh / rpms / qemu-kvm

Forked from rpms/qemu-kvm 2 years ago
Clone
ddf19c
From cd7da3cf1b19fef0a497fd556562040a85e579a7 Mon Sep 17 00:00:00 2001
ddf19c
From: Thomas Huth <thuth@redhat.com>
ddf19c
Date: Fri, 29 May 2020 05:53:57 -0400
ddf19c
Subject: [PATCH 15/42] s390/sclp: improve special wait psw logic
ddf19c
MIME-Version: 1.0
ddf19c
Content-Type: text/plain; charset=UTF-8
ddf19c
Content-Transfer-Encoding: 8bit
ddf19c
ddf19c
RH-Author: Thomas Huth <thuth@redhat.com>
ddf19c
Message-id: <20200529055420.16855-16-thuth@redhat.com>
ddf19c
Patchwork-id: 97037
ddf19c
O-Subject: [RHEL-8.3.0 qemu-kvm PATCH v2 15/38] s390/sclp: improve special wait psw logic
ddf19c
Bugzilla: 1828317
ddf19c
RH-Acked-by: Claudio Imbrenda <cimbrend@redhat.com>
ddf19c
RH-Acked-by: Philippe Mathieu-Daudé <philmd@redhat.com>
ddf19c
RH-Acked-by: Cornelia Huck <cohuck@redhat.com>
ddf19c
RH-Acked-by: David Hildenbrand <david@redhat.com>
ddf19c
ddf19c
From: Christian Borntraeger <borntraeger@de.ibm.com>
ddf19c
ddf19c
There is a special quiesce PSW that we check for "shutdown". Otherwise disabled
ddf19c
wait is detected as "crashed". Architecturally we must only check PSW bits
ddf19c
116-127. Fix this.
ddf19c
ddf19c
Cc: qemu-stable@nongnu.org
ddf19c
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
ddf19c
Message-Id: <1582204582-22995-1-git-send-email-borntraeger@de.ibm.com>
ddf19c
Reviewed-by: David Hildenbrand <david@redhat.com>
ddf19c
Acked-by: Janosch Frank <frankja@linux.ibm.com>
ddf19c
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
ddf19c
(cherry picked from commit 8b51c0961cc13e55b26bb6665ec3a341abdc7658)
ddf19c
Signed-off-by: Danilo C. L. de Paula <ddepaula@redhat.com>
ddf19c
---
ddf19c
 target/s390x/helper.c | 2 +-
ddf19c
 1 file changed, 1 insertion(+), 1 deletion(-)
ddf19c
ddf19c
diff --git a/target/s390x/helper.c b/target/s390x/helper.c
ddf19c
index a3a49164e4..6808dfda01 100644
ddf19c
--- a/target/s390x/helper.c
ddf19c
+++ b/target/s390x/helper.c
ddf19c
@@ -89,7 +89,7 @@ hwaddr s390_cpu_get_phys_addr_debug(CPUState *cs, vaddr vaddr)
ddf19c
 static inline bool is_special_wait_psw(uint64_t psw_addr)
ddf19c
 {
ddf19c
     /* signal quiesce */
ddf19c
-    return psw_addr == 0xfffUL;
ddf19c
+    return (psw_addr & 0xfffUL) == 0xfffUL;
ddf19c
 }
ddf19c
 
ddf19c
 void s390_handle_wait(S390CPU *cpu)
ddf19c
-- 
ddf19c
2.27.0
ddf19c