Commit ed94724b authored by James Bottomley's avatar James Bottomley

Merge remote-tracking branch 'mkp-scsi/4.4/scsi-fixes' into fixes

parents 5e103356 1c69d3b6
......@@ -219,13 +219,13 @@ static int sdev_runtime_suspend(struct device *dev)
struct scsi_device *sdev = to_scsi_device(dev);
int err = 0;
if (pm && pm->runtime_suspend) {
err = blk_pre_runtime_suspend(sdev->request_queue);
if (err)
return err;
err = blk_pre_runtime_suspend(sdev->request_queue);
if (err)
return err;
if (pm && pm->runtime_suspend)
err = pm->runtime_suspend(dev);
blk_post_runtime_suspend(sdev->request_queue, err);
}
blk_post_runtime_suspend(sdev->request_queue, err);
return err;
}
......@@ -248,11 +248,11 @@ static int sdev_runtime_resume(struct device *dev)
const struct dev_pm_ops *pm = dev->driver ? dev->driver->pm : NULL;
int err = 0;
if (pm && pm->runtime_resume) {
blk_pre_runtime_resume(sdev->request_queue);
blk_pre_runtime_resume(sdev->request_queue);
if (pm && pm->runtime_resume)
err = pm->runtime_resume(dev);
blk_post_runtime_resume(sdev->request_queue, err);
}
blk_post_runtime_resume(sdev->request_queue, err);
return err;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment