diff options
author | Christoph Hellwig <hch@lst.de> | 2010-08-07 12:17:56 -0400 |
---|---|---|
committer | Jens Axboe <jaxboe@fusionio.com> | 2010-08-07 12:17:56 -0400 |
commit | 33659ebbae262228eef4e0fe990f393d1f0ed941 (patch) | |
tree | fcb537f09359c8dad3a6f6e16dc4319562dc42cc /drivers/ide/ide-pm.c | |
parent | 7e005f79791dcd58436c88ded4a7f5aed1b82147 (diff) |
block: remove wrappers for request type/flags
Remove all the trivial wrappers for the cmd_type and cmd_flags fields in
struct requests. This allows much easier grepping for different request
types instead of unwinding through macros.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
Diffstat (limited to 'drivers/ide/ide-pm.c')
-rw-r--r-- | drivers/ide/ide-pm.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/ide/ide-pm.c b/drivers/ide/ide-pm.c index 1c08311b0a0e..92406097efeb 100644 --- a/drivers/ide/ide-pm.c +++ b/drivers/ide/ide-pm.c | |||
@@ -191,10 +191,10 @@ void ide_complete_pm_rq(ide_drive_t *drive, struct request *rq) | |||
191 | 191 | ||
192 | #ifdef DEBUG_PM | 192 | #ifdef DEBUG_PM |
193 | printk("%s: completing PM request, %s\n", drive->name, | 193 | printk("%s: completing PM request, %s\n", drive->name, |
194 | blk_pm_suspend_request(rq) ? "suspend" : "resume"); | 194 | (rq->cmd_type == REQ_TYPE_PM_SUSPEND) ? "suspend" : "resume"); |
195 | #endif | 195 | #endif |
196 | spin_lock_irqsave(q->queue_lock, flags); | 196 | spin_lock_irqsave(q->queue_lock, flags); |
197 | if (blk_pm_suspend_request(rq)) | 197 | if (rq->cmd_type == REQ_TYPE_PM_SUSPEND) |
198 | blk_stop_queue(q); | 198 | blk_stop_queue(q); |
199 | else | 199 | else |
200 | drive->dev_flags &= ~IDE_DFLAG_BLOCKED; | 200 | drive->dev_flags &= ~IDE_DFLAG_BLOCKED; |
@@ -210,11 +210,11 @@ void ide_check_pm_state(ide_drive_t *drive, struct request *rq) | |||
210 | { | 210 | { |
211 | struct request_pm_state *pm = rq->special; | 211 | struct request_pm_state *pm = rq->special; |
212 | 212 | ||
213 | if (blk_pm_suspend_request(rq) && | 213 | if (rq->cmd_type == REQ_TYPE_PM_SUSPEND && |
214 | pm->pm_step == IDE_PM_START_SUSPEND) | 214 | pm->pm_step == IDE_PM_START_SUSPEND) |
215 | /* Mark drive blocked when starting the suspend sequence. */ | 215 | /* Mark drive blocked when starting the suspend sequence. */ |
216 | drive->dev_flags |= IDE_DFLAG_BLOCKED; | 216 | drive->dev_flags |= IDE_DFLAG_BLOCKED; |
217 | else if (blk_pm_resume_request(rq) && | 217 | else if (rq->cmd_type == REQ_TYPE_PM_RESUME && |
218 | pm->pm_step == IDE_PM_START_RESUME) { | 218 | pm->pm_step == IDE_PM_START_RESUME) { |
219 | /* | 219 | /* |
220 | * The first thing we do on wakeup is to wait for BSY bit to | 220 | * The first thing we do on wakeup is to wait for BSY bit to |