aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/blkdev.h
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2009-07-09 08:52:32 -0400
committerJens Axboe <axboe@carl.(none)>2009-07-10 14:31:53 -0400
commit8aa7e847d834ed937a9ad37a0f2ad5b8584c1ab0 (patch)
tree76c8b4f1362a928d426f2201790ab5d128f57724 /include/linux/blkdev.h
parentc2cc49a2f8a479dde96a599646d30b6cc9dbed78 (diff)
Fix congestion_wait() sync/async vs read/write confusion
Commit 1faa16d22877f4839bd433547d770c676d1d964c accidentally broke the bdi congestion wait queue logic, causing us to wait on congestion for WRITE (== 1) when we really wanted BLK_RW_ASYNC (== 0) instead. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'include/linux/blkdev.h')
-rw-r--r--include/linux/blkdev.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 49ae07951d55..bb3d39978701 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -779,18 +779,18 @@ extern int sg_scsi_ioctl(struct request_queue *, struct gendisk *, fmode_t,
779 * congested queues, and wake up anyone who was waiting for requests to be 779 * congested queues, and wake up anyone who was waiting for requests to be
780 * put back. 780 * put back.
781 */ 781 */
782static inline void blk_clear_queue_congested(struct request_queue *q, int rw) 782static inline void blk_clear_queue_congested(struct request_queue *q, int sync)
783{ 783{
784 clear_bdi_congested(&q->backing_dev_info, rw); 784 clear_bdi_congested(&q->backing_dev_info, sync);
785} 785}
786 786
787/* 787/*
788 * A queue has just entered congestion. Flag that in the queue's VM-visible 788 * A queue has just entered congestion. Flag that in the queue's VM-visible
789 * state flags and increment the global gounter of congested queues. 789 * state flags and increment the global gounter of congested queues.
790 */ 790 */
791static inline void blk_set_queue_congested(struct request_queue *q, int rw) 791static inline void blk_set_queue_congested(struct request_queue *q, int sync)
792{ 792{
793 set_bdi_congested(&q->backing_dev_info, rw); 793 set_bdi_congested(&q->backing_dev_info, sync);
794} 794}
795 795
796extern void blk_start_queue(struct request_queue *q); 796extern void blk_start_queue(struct request_queue *q);