• Jeff Dike's avatar
    uml: batch I/O requests · a0044bdf
    Jeff Dike authored
    Send as many I/O requests to the I/O thread as possible, even though it will
    still only handle one at a time.  This provides an opportunity to reduce
    latency by starting one request before the previous one has been finished in
    the driver.
    
    Request handling is somewhat modernized by requesting sg pieces of a request
    and handling them separately, finishing off the entire request after all the
    pieces are done.
    
    When a request queue stalls, normally because its pipe to the I/O thread is
    full, it is put on the restart list.  This list is processed by starting up
    the queues on it whenever there is some indication that progress might be
    possible again.  Currently, this happens in the driver interrupt routine.
    Some requests have been finished, so there is likely to be room in the pipe
    again.
    
    This almost doubles throughput when copying data between devices, but made no
    noticable difference on anything else I tried.
    Signed-off-by: default avatarJeff Dike <jdike@linux.intel.com>
    Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
    Cc: Jens Axboe <jens.axboe@oracle.com>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    a0044bdf
ubd_kern.c 33.8 KB