Skip to content

Commit

Permalink
Merge remote-tracking branch 'mkp-scsi/4.4/scsi-fixes' into fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
James Bottomley authored and James Bottomley committed Dec 17, 2015
2 parents 5e10335 + 1c69d3b commit ed94724
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions drivers/scsi/scsi_pm.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}

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

Expand Down

0 comments on commit ed94724

Please sign in to comment.