Skip to content
  • Kevin Wolf's avatar
    421919d7
    block: Remove blk_pread_unthrottled() · 421919d7
    Kevin Wolf authored
    
    
    The functionality offered by blk_pread_unthrottled() goes back to commit
    498e386c. Then, we couldn't perform I/O throttling with synchronous
    requests because timers wouldn't be executed in polling loops. So the
    commit automatically disabled I/O throttling as soon as a synchronous
    request was issued.
    
    However, for geometry detection during disk initialisation, we always
    used (and still use) synchronous requests even if guest requests use AIO
    later. Geometry detection was not wanted to disable I/O throttling, so
    bdrv_pread_unthrottled() was introduced which disabled throttling only
    temporarily.
    
    All of this isn't necessary any more because we do run timers in polling
    loop and even synchronous requests are now using coroutine
    infrastructure internally. For this reason, commit 90c78624 already
    removed the automatic disabling of I/O throttling.
    
    It's time to get rid of the workaround for the removed code, and its
    abuse of blk_root_drained_begin()/end(), as well.
    
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
    Reviewed-by: default avatarMax Reitz <mreitz@redhat.com>
    421919d7
    block: Remove blk_pread_unthrottled()
    Kevin Wolf authored
    
    
    The functionality offered by blk_pread_unthrottled() goes back to commit
    498e386c. Then, we couldn't perform I/O throttling with synchronous
    requests because timers wouldn't be executed in polling loops. So the
    commit automatically disabled I/O throttling as soon as a synchronous
    request was issued.
    
    However, for geometry detection during disk initialisation, we always
    used (and still use) synchronous requests even if guest requests use AIO
    later. Geometry detection was not wanted to disable I/O throttling, so
    bdrv_pread_unthrottled() was introduced which disabled throttling only
    temporarily.
    
    All of this isn't necessary any more because we do run timers in polling
    loop and even synchronous requests are now using coroutine
    infrastructure internally. For this reason, commit 90c78624 already
    removed the automatic disabling of I/O throttling.
    
    It's time to get rid of the workaround for the removed code, and its
    abuse of blk_root_drained_begin()/end(), as well.
    
    Signed-off-by: default avatarKevin Wolf <kwolf@redhat.com>
    Reviewed-by: default avatarMax Reitz <mreitz@redhat.com>
Loading