[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [qemu-s390x] [PATCH v5 01/15] s390 vfio-ccw: Add bootin
From: |
Thomas Huth |
Subject: |
Re: [Qemu-devel] [qemu-s390x] [PATCH v5 01/15] s390 vfio-ccw: Add bootindex property and IPLB data |
Date: |
Tue, 26 Mar 2019 13:49:41 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.0 |
On 13/03/2019 17.31, Jason J. Herne wrote:
> Add bootindex property and iplb data for vfio-ccw devices. This allows us to
> forward boot information into the bios for vfio-ccw devices.
>
> Refactor s390_get_ccw_device() to return device type. This prevents us from
> having to use messy casting logic in several places.
>
> Signed-off-by: Jason J. Herne <address@hidden>
> Acked-by: Halil Pasic <address@hidden>
> Reviewed-by: Cornelia Huck <address@hidden>
> ---
[...]
> diff --git a/hw/s390x/ipl.c b/hw/s390x/ipl.c
> index 896888b..2307e5b 100644
> --- a/hw/s390x/ipl.c
> +++ b/hw/s390x/ipl.c
> @@ -19,6 +19,7 @@
> #include "hw/loader.h"
> #include "hw/boards.h"
> #include "hw/s390x/virtio-ccw.h"
> +#include "hw/s390x/vfio-ccw.h"
> #include "hw/s390x/css.h"
> #include "hw/s390x/ebcdic.h"
> #include "ipl.h"
> @@ -305,16 +306,36 @@ static void s390_ipl_set_boot_menu(S390IPLState *ipl)
> *timeout = cpu_to_be32(splash_time);
> }
>
> -static CcwDevice *s390_get_ccw_device(DeviceState *dev_st)
> +#define CCW_DEVTYPE_NONE 0x00
> +#define CCW_DEVTYPE_VIRTIO 0x01
> +#define CCW_DEVTYPE_VIRTIO_NET 0x02
> +#define CCW_DEVTYPE_SCSI 0x03
> +#define CCW_DEVTYPE_VFIO 0x04
Could be an enum, too... but #defines are OK, too.
[...]
> diff --git a/include/hw/s390x/vfio-ccw.h b/include/hw/s390x/vfio-ccw.h
> new file mode 100644
> index 0000000..2fceaa2
> --- /dev/null
> +++ b/include/hw/s390x/vfio-ccw.h
> @@ -0,0 +1,28 @@
> +/*
> + * vfio based subchannel assignment support
> + *
> + * Copyright 2017 IBM Corp.
Maybe bump the year to 2019 ?
> + * Author(s): Dong Jia Shi <address@hidden>
> + * Xiao Feng Ren <address@hidden>
> + * Pierre Morel <address@hidden>
> + *
> + * This work is licensed under the terms of the GNU GPL, version 2 or (at
> + * your option) any later version. See the COPYING file in the top-level
> + * directory.
> + */
> +
> +#ifndef HW_VFIO_CCW_H
> +#define HW_VFIO_CCW_H
> +
> +#include "hw/vfio/vfio-common.h"
> +#include "hw/s390x/s390-ccw.h"
> +#include "hw/s390x/ccw-device.h"
> +
> +#define TYPE_VFIO_CCW "vfio-ccw"
> +#define VFIO_CCW(obj) \
> + OBJECT_CHECK(VFIOCCWDevice, (obj), TYPE_VFIO_CCW)
> +
> +#define TYPE_VFIO_CCW "vfio-ccw"
> +typedef struct VFIOCCWDevice VFIOCCWDevice;
> +
> +#endif
Reviewed-by: Thomas Huth <address@hidden>
- Re: [Qemu-devel] [PATCH v5 10/15] s390-bios: Support for running format-0/1 channel programs, (continued)
- [Qemu-devel] [PATCH v5 06/15] s390-bios: Clean up cio.h, Jason J. Herne, 2019/03/13
- [Qemu-devel] [PATCH v5 05/15] s390-bios: Factor finding boot device out of virtio code path, Jason J. Herne, 2019/03/13
- [Qemu-devel] [PATCH v5 14/15] s390-bios: Add channel command codes/structs needed for dasd-ipl, Jason J. Herne, 2019/03/13
- [Qemu-devel] [PATCH v5 07/15] s390-bios: Decouple channel i/o logic from virtio, Jason J. Herne, 2019/03/13
- [Qemu-devel] [PATCH v5 08/15] s390-bios: Map low core memory, Jason J. Herne, 2019/03/13
- [Qemu-devel] [PATCH v5 04/15] s390-bios: Extend find_dev() for non-virtio devices, Jason J. Herne, 2019/03/13
- [Qemu-devel] [PATCH v5 02/15] s390-bios: decouple cio setup from virtio, Jason J. Herne, 2019/03/13
- [Qemu-devel] [PATCH v5 01/15] s390 vfio-ccw: Add bootindex property and IPLB data, Jason J. Herne, 2019/03/13
- Re: [Qemu-devel] [qemu-s390x] [PATCH v5 01/15] s390 vfio-ccw: Add bootindex property and IPLB data,
Thomas Huth <=
- [Qemu-devel] [PATCH v5 03/15] s390-bios: decouple common boot logic from virtio, Jason J. Herne, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13
- Re: [Qemu-devel] [PATCH v5 00/15] s390: vfio-ccw dasd ipl support, no-reply, 2019/03/13