• Chris Mason's avatar
    Btrfs: reduce CPU usage in the extent_state tree · 1edbb734
    Chris Mason authored
    Btrfs is currently mirroring some of the page state bits into
    its extent state tree.  The goal behind this was to use it in supporting
    blocksizes other than the page size.
    
    But, we don't currently support that, and we're using quite a lot of CPU
    on the rb tree and its spin lock.  This commit starts a series of
    cleanups to reduce the amount of work done in the extent state tree as
    part of each IO.
    
    This commit:
    
    * Adds the ability to lock an extent in the state tree and also set
    other bits.  The idea is to do locking and delalloc in one call
    
    * Removes the EXTENT_WRITEBACK and EXTENT_DIRTY bits.  Btrfs is using
    a combination of the page bits and the ordered write code for this
    instead.
    Signed-off-by: default avatarChris Mason <chris.mason@oracle.com>
    1edbb734
extent_io.h 10.7 KB