diff options
Diffstat (limited to 'drivers/s390/cio')
-rw-r--r-- | drivers/s390/cio/ccwgroup.c | 6 | ||||
-rw-r--r-- | drivers/s390/cio/chsc_sch.c | 3 | ||||
-rw-r--r-- | drivers/s390/cio/css.c | 7 | ||||
-rw-r--r-- | drivers/s390/cio/css.h | 2 | ||||
-rw-r--r-- | drivers/s390/cio/device.c | 9 | ||||
-rw-r--r-- | drivers/s390/cio/eadm_sch.c | 4 | ||||
-rw-r--r-- | drivers/s390/cio/scm.c | 5 | ||||
-rw-r--r-- | drivers/s390/cio/vfio_ccw_drv.c | 3 |
8 files changed, 14 insertions, 25 deletions
diff --git a/drivers/s390/cio/ccwgroup.c b/drivers/s390/cio/ccwgroup.c index acbe76a76fb2..2ec741106cb6 100644 --- a/drivers/s390/cio/ccwgroup.c +++ b/drivers/s390/cio/ccwgroup.c @@ -439,17 +439,13 @@ module_exit(cleanup_ccwgroup); /************************** driver stuff ******************************/ -static int ccwgroup_remove(struct device *dev) +static void ccwgroup_remove(struct device *dev) { struct ccwgroup_device *gdev = to_ccwgroupdev(dev); struct ccwgroup_driver *gdrv = to_ccwgroupdrv(dev->driver); - if (!dev->driver) - return 0; if (gdrv->remove) gdrv->remove(gdev); - - return 0; } static void ccwgroup_shutdown(struct device *dev) diff --git a/drivers/s390/cio/chsc_sch.c b/drivers/s390/cio/chsc_sch.c index c42405c620b5..684348d82f08 100644 --- a/drivers/s390/cio/chsc_sch.c +++ b/drivers/s390/cio/chsc_sch.c @@ -100,7 +100,7 @@ static int chsc_subchannel_probe(struct subchannel *sch) return ret; } -static int chsc_subchannel_remove(struct subchannel *sch) +static void chsc_subchannel_remove(struct subchannel *sch) { struct chsc_private *private; @@ -112,7 +112,6 @@ static int chsc_subchannel_remove(struct subchannel *sch) put_device(&sch->dev); } kfree(private); - return 0; } static void chsc_subchannel_shutdown(struct subchannel *sch) diff --git a/drivers/s390/cio/css.c b/drivers/s390/cio/css.c index 0ce48a354e04..3377097e65de 100644 --- a/drivers/s390/cio/css.c +++ b/drivers/s390/cio/css.c @@ -1401,15 +1401,14 @@ static int css_probe(struct device *dev) return ret; } -static int css_remove(struct device *dev) +static void css_remove(struct device *dev) { struct subchannel *sch; - int ret; sch = to_subchannel(dev); - ret = sch->driver->remove ? sch->driver->remove(sch) : 0; + if (sch->driver->remove) + sch->driver->remove(sch); sch->driver = NULL; - return ret; } static void css_shutdown(struct device *dev) diff --git a/drivers/s390/cio/css.h b/drivers/s390/cio/css.h index 2eddfc47f687..c98522cbe276 100644 --- a/drivers/s390/cio/css.h +++ b/drivers/s390/cio/css.h @@ -81,7 +81,7 @@ struct css_driver { int (*chp_event)(struct subchannel *, struct chp_link *, int); int (*sch_event)(struct subchannel *, int); int (*probe)(struct subchannel *); - int (*remove)(struct subchannel *); + void (*remove)(struct subchannel *); void (*shutdown)(struct subchannel *); int (*settle)(void); }; diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c index 84f659cafe76..adf33b653d87 100644 --- a/drivers/s390/cio/device.c +++ b/drivers/s390/cio/device.c @@ -137,7 +137,7 @@ static int ccw_uevent(struct device *dev, struct kobj_uevent_env *env) static void io_subchannel_irq(struct subchannel *); static int io_subchannel_probe(struct subchannel *); -static int io_subchannel_remove(struct subchannel *); +static void io_subchannel_remove(struct subchannel *); static void io_subchannel_shutdown(struct subchannel *); static int io_subchannel_sch_event(struct subchannel *, int); static int io_subchannel_chp_event(struct subchannel *, struct chp_link *, @@ -1101,7 +1101,7 @@ out_schedule: return 0; } -static int io_subchannel_remove(struct subchannel *sch) +static void io_subchannel_remove(struct subchannel *sch) { struct io_subchannel_private *io_priv = to_io_private(sch); struct ccw_device *cdev; @@ -1120,7 +1120,6 @@ out_free: io_priv->dma_area, io_priv->dma_area_dma); kfree(io_priv); sysfs_remove_group(&sch->dev.kobj, &io_subchannel_attr_group); - return 0; } static void io_subchannel_verify(struct subchannel *sch) @@ -1742,7 +1741,7 @@ ccw_device_probe (struct device *dev) return 0; } -static int ccw_device_remove(struct device *dev) +static void ccw_device_remove(struct device *dev) { struct ccw_device *cdev = to_ccwdev(dev); struct ccw_driver *cdrv = cdev->drv; @@ -1776,8 +1775,6 @@ static int ccw_device_remove(struct device *dev) spin_unlock_irq(cdev->ccwlock); io_subchannel_quiesce(sch); __disable_cmf(cdev); - - return 0; } static void ccw_device_shutdown(struct device *dev) diff --git a/drivers/s390/cio/eadm_sch.c b/drivers/s390/cio/eadm_sch.c index c8964e0a23e7..15bdae5981ca 100644 --- a/drivers/s390/cio/eadm_sch.c +++ b/drivers/s390/cio/eadm_sch.c @@ -282,7 +282,7 @@ disable: spin_unlock_irq(sch->lock); } -static int eadm_subchannel_remove(struct subchannel *sch) +static void eadm_subchannel_remove(struct subchannel *sch) { struct eadm_private *private = get_eadm_private(sch); @@ -297,8 +297,6 @@ static int eadm_subchannel_remove(struct subchannel *sch) spin_unlock_irq(sch->lock); kfree(private); - - return 0; } static void eadm_subchannel_shutdown(struct subchannel *sch) diff --git a/drivers/s390/cio/scm.c b/drivers/s390/cio/scm.c index 9f26d4310bb3..b6b4589c70bd 100644 --- a/drivers/s390/cio/scm.c +++ b/drivers/s390/cio/scm.c @@ -28,12 +28,13 @@ static int scmdev_probe(struct device *dev) return scmdrv->probe ? scmdrv->probe(scmdev) : -ENODEV; } -static int scmdev_remove(struct device *dev) +static void scmdev_remove(struct device *dev) { struct scm_device *scmdev = to_scm_dev(dev); struct scm_driver *scmdrv = to_scm_drv(dev->driver); - return scmdrv->remove ? scmdrv->remove(scmdev) : -ENODEV; + if (scmdrv->remove) + scmdrv->remove(scmdev); } static int scmdev_uevent(struct device *dev, struct kobj_uevent_env *env) diff --git a/drivers/s390/cio/vfio_ccw_drv.c b/drivers/s390/cio/vfio_ccw_drv.c index 9b61e9b131ad..76099bcb765b 100644 --- a/drivers/s390/cio/vfio_ccw_drv.c +++ b/drivers/s390/cio/vfio_ccw_drv.c @@ -234,7 +234,7 @@ out_free: return ret; } -static int vfio_ccw_sch_remove(struct subchannel *sch) +static void vfio_ccw_sch_remove(struct subchannel *sch) { struct vfio_ccw_private *private = dev_get_drvdata(&sch->dev); struct vfio_ccw_crw *crw, *temp; @@ -257,7 +257,6 @@ static int vfio_ccw_sch_remove(struct subchannel *sch) VFIO_CCW_MSG_EVENT(4, "unbound from subchannel %x.%x.%04x\n", sch->schid.cssid, sch->schid.ssid, sch->schid.sch_no); - return 0; } static void vfio_ccw_sch_shutdown(struct subchannel *sch) |