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

This commit is contained in:
James Bottomley 2015-12-17 07:32:08 -08:00
commit ed94724bed
1 changed files with 10 additions and 10 deletions

View File

@ -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;
}