s390/ccwgroup: remove pm support
authorJulian Wiedmann <jwi@linux.ibm.com>
Thu, 19 Mar 2020 09:36:32 +0000 (10:36 +0100)
committerVasily Gorbik <gor@linux.ibm.com>
Fri, 27 Mar 2020 09:22:47 +0000 (10:22 +0100)
As s390 no longer supports ARCH_HIBERNATION_POSSIBLE, drop the unused
pm ops from the ccwgroup bus driver.

Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
drivers/s390/cio/ccwgroup.c

index b42a937..483a9ec 100644 (file)
@@ -485,79 +485,10 @@ static void ccwgroup_shutdown(struct device *dev)
                gdrv->shutdown(gdev);
 }
 
-static int ccwgroup_pm_prepare(struct device *dev)
-{
-       struct ccwgroup_device *gdev = to_ccwgroupdev(dev);
-       struct ccwgroup_driver *gdrv = to_ccwgroupdrv(gdev->dev.driver);
-
-       /* Fail while device is being set online/offline. */
-       if (atomic_read(&gdev->onoff))
-               return -EAGAIN;
-
-       if (!gdev->dev.driver || gdev->state != CCWGROUP_ONLINE)
-               return 0;
-
-       return gdrv->prepare ? gdrv->prepare(gdev) : 0;
-}
-
-static void ccwgroup_pm_complete(struct device *dev)
-{
-       struct ccwgroup_device *gdev = to_ccwgroupdev(dev);
-       struct ccwgroup_driver *gdrv = to_ccwgroupdrv(dev->driver);
-
-       if (!gdev->dev.driver || gdev->state != CCWGROUP_ONLINE)
-               return;
-
-       if (gdrv->complete)
-               gdrv->complete(gdev);
-}
-
-static int ccwgroup_pm_freeze(struct device *dev)
-{
-       struct ccwgroup_device *gdev = to_ccwgroupdev(dev);
-       struct ccwgroup_driver *gdrv = to_ccwgroupdrv(gdev->dev.driver);
-
-       if (!gdev->dev.driver || gdev->state != CCWGROUP_ONLINE)
-               return 0;
-
-       return gdrv->freeze ? gdrv->freeze(gdev) : 0;
-}
-
-static int ccwgroup_pm_thaw(struct device *dev)
-{
-       struct ccwgroup_device *gdev = to_ccwgroupdev(dev);
-       struct ccwgroup_driver *gdrv = to_ccwgroupdrv(gdev->dev.driver);
-
-       if (!gdev->dev.driver || gdev->state != CCWGROUP_ONLINE)
-               return 0;
-
-       return gdrv->thaw ? gdrv->thaw(gdev) : 0;
-}
-
-static int ccwgroup_pm_restore(struct device *dev)
-{
-       struct ccwgroup_device *gdev = to_ccwgroupdev(dev);
-       struct ccwgroup_driver *gdrv = to_ccwgroupdrv(gdev->dev.driver);
-
-       if (!gdev->dev.driver || gdev->state != CCWGROUP_ONLINE)
-               return 0;
-
-       return gdrv->restore ? gdrv->restore(gdev) : 0;
-}
-
-static const struct dev_pm_ops ccwgroup_pm_ops = {
-       .prepare = ccwgroup_pm_prepare,
-       .complete = ccwgroup_pm_complete,
-       .freeze = ccwgroup_pm_freeze,
-       .thaw = ccwgroup_pm_thaw,
-       .restore = ccwgroup_pm_restore,
-};
-
 static struct bus_type ccwgroup_bus_type = {
        .name   = "ccwgroup",
        .remove = ccwgroup_remove,
        .shutdown = ccwgroup_shutdown,
-       .pm = &ccwgroup_pm_ops,
 };
 
 bool dev_is_ccwgroup(struct device *dev)