aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-pm.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/ide-pm.c')
-rw-r--r--drivers/ide/ide-pm.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/drivers/ide/ide-pm.c b/drivers/ide/ide-pm.c
index 4b3bf6a06b70..60538d9c84ee 100644
--- a/drivers/ide/ide-pm.c
+++ b/drivers/ide/ide-pm.c
@@ -186,12 +186,10 @@ void ide_complete_pm_request(ide_drive_t *drive, struct request *rq)
186 blk_pm_suspend_request(rq) ? "suspend" : "resume"); 186 blk_pm_suspend_request(rq) ? "suspend" : "resume");
187#endif 187#endif
188 spin_lock_irqsave(q->queue_lock, flags); 188 spin_lock_irqsave(q->queue_lock, flags);
189 if (blk_pm_suspend_request(rq)) { 189 if (blk_pm_suspend_request(rq))
190 blk_stop_queue(q); 190 blk_stop_queue(q);
191 } else { 191 else
192 drive->dev_flags &= ~IDE_DFLAG_BLOCKED; 192 drive->dev_flags &= ~IDE_DFLAG_BLOCKED;
193 blk_start_queue(q);
194 }
195 spin_unlock_irqrestore(q->queue_lock, flags); 193 spin_unlock_irqrestore(q->queue_lock, flags);
196 194
197 drive->hwif->rq = NULL; 195 drive->hwif->rq = NULL;
@@ -219,6 +217,8 @@ void ide_check_pm_state(ide_drive_t *drive, struct request *rq)
219 * point. 217 * point.
220 */ 218 */
221 ide_hwif_t *hwif = drive->hwif; 219 ide_hwif_t *hwif = drive->hwif;
220 struct request_queue *q = drive->queue;
221 unsigned long flags;
222 int rc; 222 int rc;
223#ifdef DEBUG_PM 223#ifdef DEBUG_PM
224 printk("%s: Wakeup request inited, waiting for !BSY...\n", drive->name); 224 printk("%s: Wakeup request inited, waiting for !BSY...\n", drive->name);
@@ -231,5 +231,9 @@ void ide_check_pm_state(ide_drive_t *drive, struct request *rq)
231 rc = ide_wait_not_busy(hwif, 100000); 231 rc = ide_wait_not_busy(hwif, 100000);
232 if (rc) 232 if (rc)
233 printk(KERN_WARNING "%s: drive not ready on wakeup\n", drive->name); 233 printk(KERN_WARNING "%s: drive not ready on wakeup\n", drive->name);
234
235 spin_lock_irqsave(q->queue_lock, flags);
236 blk_start_queue(q);
237 spin_unlock_irqrestore(q->queue_lock, flags);
234 } 238 }
235} 239}