80 lines
2.8 KiB
Diff
80 lines
2.8 KiB
Diff
|
Subject: [PATCH] [FEAT VS1804] zipl/sclp: add macros for the control-program masks
|
||
|
From: Marc Hartmayer <mhartmay@linux.ibm.com>
|
||
|
|
||
|
Summary: genprotimg: Introduce new tool for the creation of PV images
|
||
|
Description: genprotimg takes a kernel, host-key documents, optionally an
|
||
|
initrd, optionally a file with the kernel command line, and it
|
||
|
generates a single, loadable image file. The image consists of a
|
||
|
concatenation of a plain text boot loader, the encrypted
|
||
|
components for kernel, initrd, and cmdline, and the
|
||
|
integrity-protected PV header, containing metadata necessary for
|
||
|
running the guest in PV mode. It's possible to use this image file
|
||
|
as a kernel for zIPL or for a direct kernel boot using QEMU.
|
||
|
Upstream-ID: 303a3707e2e59e0ad581876db426a52fffa606b0
|
||
|
Problem-ID: VS1804
|
||
|
|
||
|
Upstream-Description:
|
||
|
|
||
|
zipl/sclp: add macros for the control-program masks
|
||
|
|
||
|
Add macros for the control-program masks and use them.
|
||
|
|
||
|
Reviewed-by: Philipp Rudo <prudo@linux.ibm.com>
|
||
|
Reviewed-by: Stefan Haberland <sth@linux.ibm.com>
|
||
|
Signed-off-by: Marc Hartmayer <mhartmay@linux.ibm.com>
|
||
|
Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
|
||
|
|
||
|
|
||
|
Signed-off-by: Marc Hartmayer <mhartmay@linux.ibm.com>
|
||
|
---
|
||
|
zipl/boot/sclp.c | 16 ++++++++--------
|
||
|
zipl/boot/sclp.h | 6 ++++++
|
||
|
2 files changed, 14 insertions(+), 8 deletions(-)
|
||
|
|
||
|
--- a/zipl/boot/sclp.c
|
||
|
+++ b/zipl/boot/sclp.c
|
||
|
@@ -126,20 +126,20 @@ int sclp_setup(int initialise)
|
||
|
|
||
|
switch (initialise) {
|
||
|
case SCLP_INIT:
|
||
|
- sccb->receive_mask = 0x80000000;
|
||
|
- sccb->send_mask = 0x40000000;
|
||
|
+ sccb->receive_mask = SCLP_EVENT_MASK_OPCMD;
|
||
|
+ sccb->send_mask = SCLP_EVENT_MASK_MSG;
|
||
|
break;
|
||
|
case SCLP_DISABLE:
|
||
|
- sccb->receive_mask = 0x0;
|
||
|
- sccb->send_mask = 0x0;
|
||
|
+ sccb->receive_mask = SCLP_EVENT_MASK_DISABLE;
|
||
|
+ sccb->send_mask = SCLP_EVENT_MASK_DISABLE;
|
||
|
break;
|
||
|
case SCLP_HSA_INIT:
|
||
|
- sccb->receive_mask = 0x0;
|
||
|
- sccb->send_mask = 0x40000010;
|
||
|
+ sccb->receive_mask = SCLP_EVENT_MASK_DISABLE;
|
||
|
+ sccb->send_mask = SCLP_EVENT_MASK_MSG | SCLP_EVENT_MASK_SDIAS;
|
||
|
break;
|
||
|
case SCLP_HSA_INIT_ASYNC:
|
||
|
- sccb->receive_mask = 0x00000010;
|
||
|
- sccb->send_mask = 0x40000010;
|
||
|
+ sccb->receive_mask = SCLP_EVENT_MASK_SDIAS;
|
||
|
+ sccb->send_mask = SCLP_EVENT_MASK_MSG | SCLP_EVENT_MASK_SDIAS;
|
||
|
break;
|
||
|
}
|
||
|
|
||
|
--- a/zipl/boot/sclp.h
|
||
|
+++ b/zipl/boot/sclp.h
|
||
|
@@ -28,6 +28,12 @@
|
||
|
#define SCLP_CMD_READ_INFO2 0x00020001
|
||
|
#define SCLP_CMD_READ_DATA 0x00770005
|
||
|
|
||
|
+/* SCLP event masks */
|
||
|
+#define SCLP_EVENT_MASK_DISABLE 0x00000000
|
||
|
+#define SCLP_EVENT_MASK_SDIAS 0x00000010
|
||
|
+#define SCLP_EVENT_MASK_MSG 0x40000000
|
||
|
+#define SCLP_EVENT_MASK_OPCMD 0x80000000
|
||
|
+
|
||
|
#define PSW_EXT_MASK 0x00080000ULL
|
||
|
#define PSW_EXT_ADDR 0x80000000ULL
|
||
|
#define PSW_WAIT_MASK 0x010a0000ULL
|