summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/disk-io.c
Commit message (Collapse)AuthorAgeFilesLines
* Btrfs: Add data block hints to SSD mode tooChris Mason2008-09-251-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Enable delalloc accountingChris Mason2008-09-251-0/+4
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: mount -o max_inline=size to control the maximum inline extent sizeChris Mason2008-09-251-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: extent_io and extent_state optimizationsChris Mason2008-09-251-2/+2
| | | | | | | | | | | | The end_bio routines are changed to take a pointer to the extent state struct, and the state tree is walked in order to set/clear appropriate bits as IO completes. This greatly reduces the number of rbtree searches done by the end_bio handlers, and reduces lock contention. The extent_io releasepage function is changed to avoid expensive searches for locked state. Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Split the extent_map code into two partsChris Mason2008-09-251-57/+66
| | | | | | | | | | | | | | There is now extent_map for mapping offsets in the file to disk and extent_io for state tracking, IO submission and extent_bufers. The new extent_map code shifts from [start,end] pairs to [start,len], and pushes the locking out into the caller. This allows a few performance optimizations and is easier to use. A number of extent_map usage bugs were fixed, mostly with failing to remove extent_map entries when changing the file. Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add mount -o ssd, which includes optimizations for seek free storageChris Mason2008-09-251-0/+3
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Use blk_congestion_wait on older kernelsChris Mason2008-09-251-1/+6
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Rework btrfs_drop_inode to avoid schedulingChris Mason2008-09-251-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Only delete roots from sysfs when they were added to sysfsChris Mason2008-09-251-1/+2
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Fix extent_buffer usage when nodesize != leafsizeChris Mason2008-09-251-3/+23
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add flush barriers on commitChris Mason2008-09-251-0/+5
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add some simple throttling to wait for data=ordered and snapshot deletionChris Mason2008-09-251-0/+7
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add data=ordered supportChris Mason2008-09-251-1/+15
| | | | | | | | This forces file data extents down the disk along with the metadata that references them. The current implementation is fairly simple, and just writes out all of the dirty pages in an inode before the commit. Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Change tree block csum tagging to avoid false error messagesChris Mason2008-09-251-10/+36
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Reduce stack usage in the resizer, fix 32 bit compilesChris Mason2008-09-251-0/+5
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Support for online FS resize (grow and shrink)Chris Mason2008-09-251-8/+24
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Implement basic support for -ENOSPCChris Mason2008-09-251-1/+4
| | | | | | | | | | This is intended to prevent accidentally filling the drive. A determined user can still make things oops. It includes some accounting of the current bytes under delayed allocation, but this will change as things get optimized Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Back port to 2.6.18-el kernelsChris Mason2008-09-251-1/+4
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add mount option to enforce a max extent sizeChris Mason2008-09-251-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Fix extent_map and extent_state leaks by flushing lrus on FS unmountChris Mason2008-09-251-0/+10
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add mount -o nodatasum to turn of file data checksummingChris Mason2008-09-251-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add lowest key information to back refs for extent tree blocks as well.Chris Mason2008-09-251-1/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add back pointers from extents to the btree or file referencing themChris Mason2008-09-251-1/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add simple stripe size parameterChris Mason2008-09-251-5/+10
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add efficient dirty accounting to the extent_map treeChris Mason2008-09-251-1/+6
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Fine tune the btree writeback exclusion some moreChris Mason2008-09-251-0/+4
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Only limit btree writeback for pdflushChris Mason2008-09-251-1/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Limit btree writeback to prevent seeksChris Mason2008-09-251-0/+9
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add block group pinned accounting backYan2008-09-251-0/+1
| | | | | | | | | This patch adds a helper function 'update_pinned_extents' to extent-tree.c. The usage of the helper function is similar to 'update_block_group', the last parameter of the function indicates pin vs unpin. Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Use writepages for the metadata tooChris Mason2008-09-251-3/+26
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Fix PAGE_CACHE_SHIFT shifts on 32 bit machinesChris Mason2008-09-251-1/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Properly setup root key while reading the rootYan Zheng2008-09-251-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add back file data checksummingChris Mason2008-09-251-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: balance_dirty_pages_ratelimited is causing problems, use nr == 1 alwaysChris Mason2008-09-251-1/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add back metadata checksummingChris Mason2008-09-251-60/+155
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: extent_map optimizations to cut down on CPU usageChris Mason2008-09-251-10/+10
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add an extent buffer LRU to reduce radix tree hitsChris Mason2008-09-251-14/+11
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add back the online defragging codeChris Mason2008-09-251-0/+60
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Use an array of pages in the extent buffers to reduce the cost of ↵Chris Mason2008-09-251-3/+3
| | | | | | find_get_page Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Allow tree blocks larger than the page sizeChris Mason2008-09-251-34/+58
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Change the remaining radix trees used by extent-tree.c to extent_map ↵Chris Mason2008-09-251-3/+6
| | | | | | trees Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Stop using radix trees for the block group cacheChris Mason2008-09-251-2/+2
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Fix extent_buffer and extent_state leaksChris Mason2008-09-251-3/+14
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Avoid memcpy where possible in extent_buffersChris Mason2008-09-251-3/+3
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Create extent_buffer interface for large blocksizesChris Mason2008-09-251-211/+180
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Use balance_dirty_pages_nr on btree blocksChris Mason2008-09-251-2/+3
| | | | | | | | btrfs_btree_balance_dirty is changed to pass the number of pages dirtied for more accurate dirty throttling. This lets the VM make better decisions about when to force some writeback. Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Find and remove dead roots the first time a root is loaded.Chris Mason2007-09-111-5/+4
| | | | | | | | | | | | | | Dead roots are trees left over after a crash, and they were either in the process of being removed or were waiting to be removed when the box crashed. Before, a search of the entire tree of root pointers was done on mount looking for dead roots. Now, the search is done the first time we load a root. This makes mount faster when there are a large number of snapshots, and it enables the block accounting code to properly update the block counts on the latest root as old versions of the root are reaped after a crash. Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add more synchronization before creating a snapshotChris Mason2007-09-101-0/+1
| | | | | | | | File data checksums are only done during writepage, so we have to make sure all pages are written when the snapshot is taken. This also adds some locking so that new writes don't race in and add new dirty pages. Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: Add per-root block accounting and sysfs entriesJosef Bacik2007-08-291-2/+29
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
* Btrfs: delay commits during fsync to allow more writersJosef Bacik2007-08-101-0/+1
| | | | Signed-off-by: Chris Mason <chris.mason@oracle.com>
OpenPOWER on IntegriCloud