diff options
author | Christoph Hellwig <hch@lst.de> | 2018-11-09 14:42:35 +0100 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2018-11-09 19:17:13 -0700 |
commit | 535ac5d3fe63b9ea1dda379f606f9d0d377d7184 (patch) | |
tree | a007c66ce4e12a4086085f48dddf1946e67f85f0 /drivers/ide/ide-io.c | |
parent | 9d037ad707ed6069fbea4e38e6ee37e027b13f1d (diff) | |
download | lwn-535ac5d3fe63b9ea1dda379f606f9d0d377d7184.tar.gz lwn-535ac5d3fe63b9ea1dda379f606f9d0d377d7184.zip |
ide: cleanup ->prep_rq calling convention
The return value is just used as a binary yes/no decision, so switch
it to a bool instead of the old BLKPREP_* values returned as an int.
Also clean up a few related comments.
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/ide/ide-io.c')
-rw-r--r-- | drivers/ide/ide-io.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/ide/ide-io.c b/drivers/ide/ide-io.c index 5093c605c91c..64e72640acf8 100644 --- a/drivers/ide/ide-io.c +++ b/drivers/ide/ide-io.c @@ -326,7 +326,7 @@ static ide_startstop_t start_request (ide_drive_t *drive, struct request *rq) goto kill_rq; } - if (drive->prep_rq && drive->prep_rq(drive, rq)) + if (drive->prep_rq && !drive->prep_rq(drive, rq)) return ide_stopped; if (ata_pm_request(rq)) @@ -508,7 +508,7 @@ repeat: /* * we know that the queue isn't empty, but this can happen - * if the q->prep_rq_fn() decides to kill a request + * if ->prep_rq() decides to kill a request */ if (!rq) { rq = bd->rq; |