• T
    block: allocate io_context upfront · 7f4b35d1
    Tejun Heo 提交于
    Block layer very lazy allocation of ioc.  It waits until the moment
    ioc is absolutely necessary; unfortunately, that time could be inside
    queue lock and __get_request() performs unlock - try alloc - retry
    dancing.
    
    Just allocate it up-front on entry to block layer.  We're not saving
    the rain forest by deferring it to the last possible moment and
    complicating things unnecessarily.
    
    This patch is to prepare for further updates to request allocation
    path.
    Signed-off-by: NTejun Heo <tj@kernel.org>
    Acked-by: NVivek Goyal <vgoyal@redhat.com>
    Signed-off-by: NJens Axboe <axboe@kernel.dk>
    7f4b35d1
blk-throttle.c 31.0 KB