summaryrefslogtreecommitdiff
path: root/hw/s390x/ipl.h
diff options
context:
space:
mode:
authorAlexander Yarygin <yarygin@linux.vnet.ibm.com>2016-06-09 15:54:10 +0300
committerCornelia Huck <cornelia.huck@de.ibm.com>2016-07-11 09:48:05 +0200
commite468b6730cb36a475fd4e71f57b020ca37ebd8ae (patch)
tree986bd04c1f999cd4eaa5f0db888419615de17219 /hw/s390x/ipl.h
parent07c6f329bdf37595777ddd334de9bbd24d4eed7c (diff)
downloadqemu-e468b6730cb36a475fd4e71f57b020ca37ebd8ae.tar.gz
s390x/ipl: Support IPL from selected SCSI device
If bootindex is specified for a device, we need to IPL from it. Currently it works for ccw devices, but not for SCSI. To be able to IPL from the specific device, pc-bios needs to know its address. For this reason we add special QEMU_SCSI IPL type into the IPLB structure, that contains the scsi device address. We enhance the ipl block with a currently qemu-only parameter block that allows us to specify a concrete scsi device. Signed-off-by: Alexander Yarygin <yarygin@linux.vnet.ibm.com> Reviewed-by: Eric Farman <farman@linux.vnet.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Diffstat (limited to 'hw/s390x/ipl.h')
-rw-r--r--hw/s390x/ipl.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/hw/s390x/ipl.h b/hw/s390x/ipl.h
index 9aa4d942a7..ed3f2c8a43 100644
--- a/hw/s390x/ipl.h
+++ b/hw/s390x/ipl.h
@@ -46,6 +46,16 @@ struct IplBlockFcp {
} QEMU_PACKED;
typedef struct IplBlockFcp IplBlockFcp;
+struct IplBlockQemuScsi {
+ uint32_t lun;
+ uint16_t target;
+ uint16_t channel;
+ uint8_t reserved0[77];
+ uint8_t ssid;
+ uint16_t devno;
+} QEMU_PACKED;
+typedef struct IplBlockQemuScsi IplBlockQemuScsi;
+
union IplParameterBlock {
struct {
uint32_t len;
@@ -59,6 +69,7 @@ union IplParameterBlock {
union {
IplBlockCcw ccw;
IplBlockFcp fcp;
+ IplBlockQemuScsi scsi;
};
} QEMU_PACKED;
struct {
@@ -102,10 +113,12 @@ typedef struct S390IPLState S390IPLState;
#define S390_IPL_TYPE_FCP 0x00
#define S390_IPL_TYPE_CCW 0x02
+#define S390_IPL_TYPE_QEMU_SCSI 0xff
#define S390_IPLB_HEADER_LEN 8
#define S390_IPLB_MIN_CCW_LEN 200
#define S390_IPLB_MIN_FCP_LEN 384
+#define S390_IPLB_MIN_QEMU_SCSI_LEN 200
static inline bool iplb_valid_len(IplParameterBlock *iplb)
{