• Jens Axboe's avatar
    [PATCH] ll_rw_blk: prevent huge request allocations · 082cf69e
    Jens Axboe authored
    Currently we cap request allocations at q->nr_requests, but we allow a
    batching io context to allocate up to 32 more (default setting).  This
    can flood the queue with request allocations, with only a few batching
    processes.  The real fix would be to limit the number of batchers, but
    as that isn't currently tracked, I suggest we just cap the maximum
    number of allocated requests to eg 50% over the limit.
    
    This was observed in real life, users typically see this as vmstat bo
    numbers going off the wall with seconds of no queueing afterwards.
    Behaviour this bursty is not beneficial.
    Signed-off-by: default avatarJens Axboe <axboe@suse.de>
    Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
    082cf69e
ll_rw_blk.c 90.6 KB