* [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize
@ 2018-03-07 16:29 Nia Alarie
2018-03-08 15:20 ` Cornelia Huck
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Nia Alarie @ 2018-03-07 16:29 UTC (permalink / raw)
To: qemu-devel
Cc: qemu-s390x, cohuck, borntraeger, stefanha, jim, joel, Nia Alarie
Signed-off-by: Nia Alarie <nia.alarie@gmail.com>
---
hw/s390x/virtio-ccw.c | 34 +++++++++++++++++-----------------
hw/s390x/virtio-ccw.h | 2 +-
2 files changed, 18 insertions(+), 18 deletions(-)
diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c
index 8f7fbc2ab7..e51fbefd23 100644
--- a/hw/s390x/virtio-ccw.c
+++ b/hw/s390x/virtio-ccw.c
@@ -752,7 +752,7 @@ out_err:
g_free(sch);
}
-static int virtio_ccw_exit(VirtioCcwDevice *dev)
+static void virtio_ccw_unrealize(VirtioCcwDevice *dev, Error **errp)
{
CcwDevice *ccw_dev = CCW_DEVICE(dev);
SubchDev *sch = ccw_dev->sch;
@@ -760,12 +760,12 @@ static int virtio_ccw_exit(VirtioCcwDevice *dev)
if (sch) {
css_subch_assign(sch->cssid, sch->ssid, sch->schid, sch->devno, NULL);
g_free(sch);
+ ccw_dev->sch = NULL;
}
if (dev->indicators) {
release_indicator(&dev->routes.adapter, dev->indicators);
dev->indicators = NULL;
}
- return 0;
}
static void virtio_ccw_net_realize(VirtioCcwDevice *ccw_dev, Error **errp)
@@ -1344,7 +1344,7 @@ static void virtio_ccw_net_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_net_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_net_properties;
set_bit(DEVICE_CATEGORY_NETWORK, dc->categories);
@@ -1372,7 +1372,7 @@ static void virtio_ccw_blk_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_blk_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_blk_properties;
set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);
@@ -1400,7 +1400,7 @@ static void virtio_ccw_serial_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_serial_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_serial_properties;
set_bit(DEVICE_CATEGORY_INPUT, dc->categories);
@@ -1428,7 +1428,7 @@ static void virtio_ccw_balloon_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_balloon_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_balloon_properties;
set_bit(DEVICE_CATEGORY_MISC, dc->categories);
@@ -1456,7 +1456,7 @@ static void virtio_ccw_scsi_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_scsi_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_scsi_properties;
set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);
@@ -1483,7 +1483,7 @@ static void vhost_ccw_scsi_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = vhost_ccw_scsi_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = vhost_ccw_scsi_properties;
set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);
@@ -1520,7 +1520,7 @@ static void virtio_ccw_rng_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_rng_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_rng_properties;
set_bit(DEVICE_CATEGORY_MISC, dc->categories);
@@ -1558,7 +1558,7 @@ static void virtio_ccw_crypto_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_crypto_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_crypto_properties;
set_bit(DEVICE_CATEGORY_MISC, dc->categories);
@@ -1596,7 +1596,7 @@ static void virtio_ccw_gpu_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_gpu_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_gpu_properties;
dc->hotpluggable = false;
@@ -1625,7 +1625,7 @@ static void virtio_ccw_input_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = virtio_ccw_input_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_input_properties;
set_bit(DEVICE_CATEGORY_INPUT, dc->categories);
@@ -1705,12 +1705,12 @@ static void virtio_ccw_busdev_realize(DeviceState *dev, Error **errp)
virtio_ccw_device_realize(_dev, errp);
}
-static int virtio_ccw_busdev_exit(DeviceState *dev)
+static void virtio_ccw_busdev_unrealize(DeviceState *dev, Error **errp)
{
VirtioCcwDevice *_dev = (VirtioCcwDevice *)dev;
VirtIOCCWDeviceClass *_info = VIRTIO_CCW_DEVICE_GET_CLASS(dev);
- return _info->exit(_dev);
+ _info->unrealize(_dev, errp);
}
static void virtio_ccw_busdev_unplug(HotplugHandler *hotplug_dev,
@@ -1728,7 +1728,7 @@ static void virtio_ccw_device_class_init(ObjectClass *klass, void *data)
k->unplug = virtio_ccw_busdev_unplug;
dc->realize = virtio_ccw_busdev_realize;
- dc->exit = virtio_ccw_busdev_exit;
+ dc->unrealize = virtio_ccw_busdev_unrealize;
dc->bus_type = TYPE_VIRTUAL_CSS_BUS;
}
@@ -1804,7 +1804,7 @@ static void virtio_ccw_9p_class_init(ObjectClass *klass, void *data)
DeviceClass *dc = DEVICE_CLASS(klass);
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
k->realize = virtio_ccw_9p_realize;
dc->reset = virtio_ccw_reset;
dc->props = virtio_ccw_9p_properties;
@@ -1853,7 +1853,7 @@ static void vhost_vsock_ccw_class_init(ObjectClass *klass, void *data)
VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
k->realize = vhost_vsock_ccw_realize;
- k->exit = virtio_ccw_exit;
+ k->unrealize = virtio_ccw_unrealize;
set_bit(DEVICE_CATEGORY_MISC, dc->categories);
dc->props = vhost_vsock_ccw_properties;
dc->reset = virtio_ccw_reset;
diff --git a/hw/s390x/virtio-ccw.h b/hw/s390x/virtio-ccw.h
index 3905f3a3d6..2fc513001e 100644
--- a/hw/s390x/virtio-ccw.h
+++ b/hw/s390x/virtio-ccw.h
@@ -76,7 +76,7 @@ typedef struct VirtioCcwDevice VirtioCcwDevice;
typedef struct VirtIOCCWDeviceClass {
CCWDeviceClass parent_class;
void (*realize)(VirtioCcwDevice *dev, Error **errp);
- int (*exit)(VirtioCcwDevice *dev);
+ void (*unrealize)(VirtioCcwDevice *dev, Error **errp);
} VirtIOCCWDeviceClass;
/* Performance improves when virtqueue kick processing is decoupled from the
--
2.16.2
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize
2018-03-07 16:29 [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize Nia Alarie
@ 2018-03-08 15:20 ` Cornelia Huck
2018-03-08 16:13 ` Stefan Hajnoczi
2018-03-09 9:23 ` Pierre Morel
2 siblings, 0 replies; 7+ messages in thread
From: Cornelia Huck @ 2018-03-08 15:20 UTC (permalink / raw)
To: Nia Alarie; +Cc: qemu-devel, qemu-s390x, borntraeger, stefanha, jim, joel
On Wed, 7 Mar 2018 16:29:58 +0000
Nia Alarie <nia.alarie@gmail.com> wrote:
> Signed-off-by: Nia Alarie <nia.alarie@gmail.com>
> ---
> hw/s390x/virtio-ccw.c | 34 +++++++++++++++++-----------------
> hw/s390x/virtio-ccw.h | 2 +-
> 2 files changed, 18 insertions(+), 18 deletions(-)
Thanks, applied.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize
2018-03-07 16:29 [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize Nia Alarie
2018-03-08 15:20 ` Cornelia Huck
@ 2018-03-08 16:13 ` Stefan Hajnoczi
2018-03-08 19:24 ` nee
2018-03-09 9:23 ` Pierre Morel
2 siblings, 1 reply; 7+ messages in thread
From: Stefan Hajnoczi @ 2018-03-08 16:13 UTC (permalink / raw)
To: Nia Alarie; +Cc: qemu-devel, qemu-s390x, cohuck, borntraeger, jim, joel
[-- Attachment #1: Type: text/plain, Size: 658 bytes --]
On Wed, Mar 07, 2018 at 04:29:58PM +0000, Nia Alarie wrote:
> @@ -760,12 +760,12 @@ static int virtio_ccw_exit(VirtioCcwDevice *dev)
> if (sch) {
> css_subch_assign(sch->cssid, sch->ssid, sch->schid, sch->devno, NULL);
> g_free(sch);
> + ccw_dev->sch = NULL;
This change is unrelated to the topic of the patch and not mentioned in
the commit description. I think it was probably made for consistency,
rather than a bug fix or functional change. That's a valid reason too
but please mention secondary changes like this in future patches so
reviewers know why you made them.
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 455 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize
2018-03-08 16:13 ` Stefan Hajnoczi
@ 2018-03-08 19:24 ` nee
0 siblings, 0 replies; 7+ messages in thread
From: nee @ 2018-03-08 19:24 UTC (permalink / raw)
To: Stefan Hajnoczi
Cc: qemu-devel, qemu-s390x, Cornelia Huck, borntraeger, Jim Mussared,
Joel Stanley
On Thu, Mar 8, 2018 at 4:13 PM, Stefan Hajnoczi <stefanha@gmail.com> wrote:
> On Wed, Mar 07, 2018 at 04:29:58PM +0000, Nia Alarie wrote:
>> @@ -760,12 +760,12 @@ static int virtio_ccw_exit(VirtioCcwDevice *dev)
>> if (sch) {
>> css_subch_assign(sch->cssid, sch->ssid, sch->schid, sch->devno, NULL);
>> g_free(sch);
>> + ccw_dev->sch = NULL;
>
> This change is unrelated to the topic of the patch and not mentioned in
> the commit description. I think it was probably made for consistency,
> rather than a bug fix or functional change. That's a valid reason too
> but please mention secondary changes like this in future patches so
> reviewers know why you made them.
>
> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Indeed, this was done for consistency (but also, it feels like a good
practice to follow). Thanks for the review.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize
2018-03-07 16:29 [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize Nia Alarie
2018-03-08 15:20 ` Cornelia Huck
2018-03-08 16:13 ` Stefan Hajnoczi
@ 2018-03-09 9:23 ` Pierre Morel
2018-03-09 10:27 ` Cornelia Huck
2 siblings, 1 reply; 7+ messages in thread
From: Pierre Morel @ 2018-03-09 9:23 UTC (permalink / raw)
To: Nia Alarie, qemu-devel
Cc: jim, stefanha, cohuck, borntraeger, qemu-s390x, joel
On 07/03/2018 17:29, Nia Alarie wrote:
> Signed-off-by: Nia Alarie <nia.alarie@gmail.com>
What you do seems right to me, naming seems more logical, but can you
please
add a little commit message explaining why you change the interface?
Thanks,
Pierre
> ---
> hw/s390x/virtio-ccw.c | 34 +++++++++++++++++-----------------
> hw/s390x/virtio-ccw.h | 2 +-
> 2 files changed, 18 insertions(+), 18 deletions(-)
>
> diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c
> index 8f7fbc2ab7..e51fbefd23 100644
> --- a/hw/s390x/virtio-ccw.c
> +++ b/hw/s390x/virtio-ccw.c
> @@ -752,7 +752,7 @@ out_err:
> g_free(sch);
> }
>
> -static int virtio_ccw_exit(VirtioCcwDevice *dev)
> +static void virtio_ccw_unrealize(VirtioCcwDevice *dev, Error **errp)
> {
> CcwDevice *ccw_dev = CCW_DEVICE(dev);
> SubchDev *sch = ccw_dev->sch;
> @@ -760,12 +760,12 @@ static int virtio_ccw_exit(VirtioCcwDevice *dev)
> if (sch) {
> css_subch_assign(sch->cssid, sch->ssid, sch->schid, sch->devno, NULL);
> g_free(sch);
> + ccw_dev->sch = NULL;
> }
> if (dev->indicators) {
> release_indicator(&dev->routes.adapter, dev->indicators);
> dev->indicators = NULL;
> }
> - return 0;
> }
>
> static void virtio_ccw_net_realize(VirtioCcwDevice *ccw_dev, Error **errp)
> @@ -1344,7 +1344,7 @@ static void virtio_ccw_net_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_net_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_net_properties;
> set_bit(DEVICE_CATEGORY_NETWORK, dc->categories);
> @@ -1372,7 +1372,7 @@ static void virtio_ccw_blk_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_blk_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_blk_properties;
> set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);
> @@ -1400,7 +1400,7 @@ static void virtio_ccw_serial_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_serial_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_serial_properties;
> set_bit(DEVICE_CATEGORY_INPUT, dc->categories);
> @@ -1428,7 +1428,7 @@ static void virtio_ccw_balloon_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_balloon_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_balloon_properties;
> set_bit(DEVICE_CATEGORY_MISC, dc->categories);
> @@ -1456,7 +1456,7 @@ static void virtio_ccw_scsi_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_scsi_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_scsi_properties;
> set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);
> @@ -1483,7 +1483,7 @@ static void vhost_ccw_scsi_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = vhost_ccw_scsi_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = vhost_ccw_scsi_properties;
> set_bit(DEVICE_CATEGORY_STORAGE, dc->categories);
> @@ -1520,7 +1520,7 @@ static void virtio_ccw_rng_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_rng_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_rng_properties;
> set_bit(DEVICE_CATEGORY_MISC, dc->categories);
> @@ -1558,7 +1558,7 @@ static void virtio_ccw_crypto_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_crypto_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_crypto_properties;
> set_bit(DEVICE_CATEGORY_MISC, dc->categories);
> @@ -1596,7 +1596,7 @@ static void virtio_ccw_gpu_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_gpu_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_gpu_properties;
> dc->hotpluggable = false;
> @@ -1625,7 +1625,7 @@ static void virtio_ccw_input_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = virtio_ccw_input_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_input_properties;
> set_bit(DEVICE_CATEGORY_INPUT, dc->categories);
> @@ -1705,12 +1705,12 @@ static void virtio_ccw_busdev_realize(DeviceState *dev, Error **errp)
> virtio_ccw_device_realize(_dev, errp);
> }
>
> -static int virtio_ccw_busdev_exit(DeviceState *dev)
> +static void virtio_ccw_busdev_unrealize(DeviceState *dev, Error **errp)
> {
> VirtioCcwDevice *_dev = (VirtioCcwDevice *)dev;
> VirtIOCCWDeviceClass *_info = VIRTIO_CCW_DEVICE_GET_CLASS(dev);
>
> - return _info->exit(_dev);
> + _info->unrealize(_dev, errp);
> }
>
> static void virtio_ccw_busdev_unplug(HotplugHandler *hotplug_dev,
> @@ -1728,7 +1728,7 @@ static void virtio_ccw_device_class_init(ObjectClass *klass, void *data)
>
> k->unplug = virtio_ccw_busdev_unplug;
> dc->realize = virtio_ccw_busdev_realize;
> - dc->exit = virtio_ccw_busdev_exit;
> + dc->unrealize = virtio_ccw_busdev_unrealize;
> dc->bus_type = TYPE_VIRTUAL_CSS_BUS;
> }
>
> @@ -1804,7 +1804,7 @@ static void virtio_ccw_9p_class_init(ObjectClass *klass, void *data)
> DeviceClass *dc = DEVICE_CLASS(klass);
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> k->realize = virtio_ccw_9p_realize;
> dc->reset = virtio_ccw_reset;
> dc->props = virtio_ccw_9p_properties;
> @@ -1853,7 +1853,7 @@ static void vhost_vsock_ccw_class_init(ObjectClass *klass, void *data)
> VirtIOCCWDeviceClass *k = VIRTIO_CCW_DEVICE_CLASS(klass);
>
> k->realize = vhost_vsock_ccw_realize;
> - k->exit = virtio_ccw_exit;
> + k->unrealize = virtio_ccw_unrealize;
> set_bit(DEVICE_CATEGORY_MISC, dc->categories);
> dc->props = vhost_vsock_ccw_properties;
> dc->reset = virtio_ccw_reset;
> diff --git a/hw/s390x/virtio-ccw.h b/hw/s390x/virtio-ccw.h
> index 3905f3a3d6..2fc513001e 100644
> --- a/hw/s390x/virtio-ccw.h
> +++ b/hw/s390x/virtio-ccw.h
> @@ -76,7 +76,7 @@ typedef struct VirtioCcwDevice VirtioCcwDevice;
> typedef struct VirtIOCCWDeviceClass {
> CCWDeviceClass parent_class;
> void (*realize)(VirtioCcwDevice *dev, Error **errp);
> - int (*exit)(VirtioCcwDevice *dev);
> + void (*unrealize)(VirtioCcwDevice *dev, Error **errp);
> } VirtIOCCWDeviceClass;
>
> /* Performance improves when virtqueue kick processing is decoupled from the
--
Pierre Morel
Linux/KVM/QEMU in Böblingen - Germany
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize
2018-03-09 9:23 ` Pierre Morel
@ 2018-03-09 10:27 ` Cornelia Huck
2018-03-09 11:28 ` Pierre Morel
0 siblings, 1 reply; 7+ messages in thread
From: Cornelia Huck @ 2018-03-09 10:27 UTC (permalink / raw)
To: Pierre Morel
Cc: Nia Alarie, qemu-devel, jim, stefanha, borntraeger, qemu-s390x,
joel
On Fri, 9 Mar 2018 10:23:31 +0100
Pierre Morel <pmorel@linux.vnet.ibm.com> wrote:
> On 07/03/2018 17:29, Nia Alarie wrote:
> > Signed-off-by: Nia Alarie <nia.alarie@gmail.com>
>
> What you do seems right to me, naming seems more logical, but can you
> please
> add a little commit message explaining why you change the interface?
I had asked Nia to do this; see the comments in qdev-core.h regarding
usage of exit vs. unrealize.
(I have already queued this for a pull request, since I'll be out
starting tomorrow.)
>
> Thanks,
>
> Pierre
>
> > ---
> > hw/s390x/virtio-ccw.c | 34 +++++++++++++++++-----------------
> > hw/s390x/virtio-ccw.h | 2 +-
> > 2 files changed, 18 insertions(+), 18 deletions(-)
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize
2018-03-09 10:27 ` Cornelia Huck
@ 2018-03-09 11:28 ` Pierre Morel
0 siblings, 0 replies; 7+ messages in thread
From: Pierre Morel @ 2018-03-09 11:28 UTC (permalink / raw)
To: qemu-devel
On 09/03/2018 11:27, Cornelia Huck wrote:
> On Fri, 9 Mar 2018 10:23:31 +0100
> Pierre Morel <pmorel@linux.vnet.ibm.com> wrote:
>
>> On 07/03/2018 17:29, Nia Alarie wrote:
>>> Signed-off-by: Nia Alarie <nia.alarie@gmail.com>
>> What you do seems right to me, naming seems more logical, but can you
>> please
>> add a little commit message explaining why you change the interface?
> I had asked Nia to do this; see the comments in qdev-core.h regarding
> usage of exit vs. unrealize.
OK thanks.
>
> (I have already queued this for a pull request, since I'll be out
> starting tomorrow.)
have fun where you go. :)
See you.
bye
>
>> Thanks,
>>
>> Pierre
>>
>>> ---
>>> hw/s390x/virtio-ccw.c | 34 +++++++++++++++++-----------------
>>> hw/s390x/virtio-ccw.h | 2 +-
>>> 2 files changed, 18 insertions(+), 18 deletions(-)
--
Pierre Morel
Linux/KVM/QEMU in Böblingen - Germany
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2018-03-09 11:28 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-07 16:29 [Qemu-devel] [PATCH] s390x/virtio: Convert virtio-ccw from *_exit to *_unrealize Nia Alarie
2018-03-08 15:20 ` Cornelia Huck
2018-03-08 16:13 ` Stefan Hajnoczi
2018-03-08 19:24 ` nee
2018-03-09 9:23 ` Pierre Morel
2018-03-09 10:27 ` Cornelia Huck
2018-03-09 11:28 ` Pierre Morel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).