Message ID | CADyday34OOHk2gWpzzuLAPMO+FvOL_dgdLGoxcTfFth4Q264Gg@mail.gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Tue, 12 Apr 2016 23:57:06 +0530 Nutan Shinde <nutanshinde1992@gmail.com> wrote: > This change is required because the return type of exit(error) function is > not used. > This patch only has changes for files in hw/s390x package. Some meta-notes (I saw the related discussion on qemu-devel; the comments there apply to this patch as well): - The change is not 'required'. It's a cleanup because everybody returns 0 anyway. - It often makes sense to cc: everybody on the cover letter so they can find out what the series is about without needing to dig it up on the mailing list. - A patch series needs to preserve bisectability, i.e. at every point in the series the code must compile. To achieve this, it often makes sense to split out self-contained changes restricted to a component (here: changes following from VirtIOCCWDeviceClass changes) from whole-tree changes (here: changes following from DeviceClass). > > Signed-off-by: Nutan Shinde <nutanshinde1992@gmail.com> > --- > hw/s390x/virtio-ccw.c | 7 +++---- > hw/s390x/virtio-ccw.h | 2 +- > 2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c index d51642d..e8b5a38 100644 --- a/hw/s390x/virtio-ccw.c +++ b/hw/s390x/virtio-ccw.c @@ -878,7 +878,7 @@ out_err: g_free(sch); } -static int virtio_ccw_exit(VirtioCcwDevice *dev) +static void virtio_ccw_exit(VirtioCcwDevice *dev) { SubchDev *sch = dev->sch; @@ -890,7 +890,6 @@ static int virtio_ccw_exit(VirtioCcwDevice *dev) release_indicator(&dev->routes.adapter, dev->indicators); dev->indicators = NULL; } - return 0; } static void virtio_ccw_net_realize(VirtioCcwDevice *ccw_dev, Error **errp) @@ -1735,12 +1734,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_exit(DeviceState *dev) { VirtioCcwDevice *_dev = (VirtioCcwDevice *)dev; VirtIOCCWDeviceClass *_info = VIRTIO_CCW_DEVICE_GET_CLASS(dev); - return _info->exit(_dev); + _info->exit(_dev); } static void virtio_ccw_busdev_unplug(HotplugHandler *hotplug_dev, diff --git a/hw/s390x/virtio-ccw.h b/hw/s390x/virtio-ccw.h index 66c831b..854602f 100644 --- a/hw/s390x/virtio-ccw.h +++ b/hw/s390x/virtio-ccw.h @@ -68,7 +68,7 @@ typedef struct VirtioCcwDevice VirtioCcwDevice; typedef struct VirtIOCCWDeviceClass { DeviceClass parent_class; void (*realize)(VirtioCcwDevice *dev, Error **errp); - int (*exit)(VirtioCcwDevice *dev); + void (*exit)(VirtioCcwDevice *dev); } VirtIOCCWDeviceClass; /* Performance improves when virtqueue kick processing is decoupled from
This change is required because the return type of exit(error) function is not used. This patch only has changes for files in hw/s390x package. Signed-off-by: Nutan Shinde <nutanshinde1992@gmail.com> --- hw/s390x/virtio-ccw.c | 7 +++---- hw/s390x/virtio-ccw.h | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) the -- 1.9.1