Skip to content

Commit da20a20

Browse files
Jens AxboeJens Axboe
authored andcommitted
[PATCH] ll_rw_blk: allow more flexibility for read_ahead_kb store
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 <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
1 parent bf57225 commit da20a20

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

block/ll_rw_blk.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3806,9 +3806,6 @@ queue_ra_store(struct request_queue *q, const char *page, size_t count)
38063806
ssize_t ret = queue_var_store(&ra_kb, page, count);
38073807

38083808
spin_lock_irq(q->queue_lock);
3809-
if (ra_kb > (q->max_sectors >> 1))
3810-
ra_kb = (q->max_sectors >> 1);
3811-
38123809
q->backing_dev_info.ra_pages = ra_kb >> (PAGE_CACHE_SHIFT - 10);
38133810
spin_unlock_irq(q->queue_lock);
38143811

0 commit comments

Comments
 (0)