Skip to content

Commit

Permalink
[PATCH] ll_rw_blk: allow more flexibility for read_ahead_kb store
Browse files Browse the repository at this point in the history
It can make sense to set read-ahead larger than a single request.
We should not be enforcing such policy on the user. Additionally,
using the BLKRASET ioctl doesn't impose such a restriction. So
additionally we now expose identical behaviour through the two.

Issue also reported by Anton <cbou@mail.ru>

Signed-off-by: Jens Axboe <axboe@suse.de>
  • Loading branch information
Jens Axboe authored and Jens Axboe committed Sep 30, 2006
1 parent bf57225 commit da20a20
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions block/ll_rw_blk.c
Original file line number Diff line number Diff line change
Expand Up @@ -3806,9 +3806,6 @@ queue_ra_store(struct request_queue *q, const char *page, size_t count)
ssize_t ret = queue_var_store(&ra_kb, page, count);

spin_lock_irq(q->queue_lock);
if (ra_kb > (q->max_sectors >> 1))
ra_kb = (q->max_sectors >> 1);

q->backing_dev_info.ra_pages = ra_kb >> (PAGE_CACHE_SHIFT - 10);
spin_unlock_irq(q->queue_lock);

Expand Down

0 comments on commit da20a20

Please sign in to comment.