Re: Poor performance during disk writes

Jens Axboe
2001-12-21T16:51:19Z

On Thu, Dec 20 2001, Andrew Morton wrote:
> --- linux-2.4.17-pre6/drivers/block/ll_rw_blk.c Mon Nov 5 21:01:11 2001
> +++ linux-akpm/drivers/block/ll_rw_blk.c Sat Dec 8 11:10:36 2001
> @@ -690,7 +690,8 @@ again:
> } else if (q->head_active && !q->plugged)
> head = head->next;
>
> - el_ret = elevator->elevator_merge_fn(q, &req, head, bh, rw,max_sectors);
> + el_ret = elevator->elevator_merge_fn(q, &req, head, bh,
> + rw, max_sectors, elevator->max_bomb_segments);

merge function can just grab max_bomb_segments ala

int mbs = q->elevator.max_bomb_segments

so no need to modify the merge functions.

--
Jens Axboe