aboutsummaryrefslogtreecommitdiff
path: root/fs/btrfs/disk-io.h
AgeCommit message (Collapse)AuthorFilesLines
2008-09-25Btrfs: Transaction commit: don't use filemap_fdatawaitChris Mason1-0/+1
After writing out all the remaining btree blocks in the transaction, the commit code would use filemap_fdatawait to make sure it was all on disk. This means it would wait for blocks written by other procs as well. The new code walks the list of blocks for this transaction again and waits only for those required by this transaction. Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Online btree defragmentation fixesChris Mason1-6/+0
The btree defragger wasn't making forward progress because the new key wasn't being saved by the btrfs_search_forward function. This also disables the automatic btree defrag, it wasn't scaling well to huge filesystems. The auto-defrag needs to be done differently. Signed-off-by: Chris Mason <[email protected]>
2008-09-25Add btrfs_end_transaction_throttle to force writers to wait for pending commitsChris Mason1-1/+0
The existing throttle mechanism was often not sufficient to prevent new writers from coming in and making a given transaction run forever. This adds an explicit wait at the end of most operations so they will allow the current transaction to close. There is no wait inside file_write, inode updates, or cow filling, all which have different deadlock possibilities. This is a temporary measure until better asynchronous commit support is added. This code leads to stalls as it waits for data=ordered writeback, and it really needs to be fixed. Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Add mount -o degraded to allow mounts to continue with missing devicesChris Mason1-1/+2
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Handle write errors on raid1 and raid10Chris Mason1-1/+1
When duplicate copies exist, writes are allowed to fail to one of those copies. This changeset includes a few changes that allow the FS to continue even when some IOs fail. It also adds verification of the parent generation number for btree blocks. This generation is stored in the pointer to a block, and it ensures that missed writes to are detected. Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Pass down the expected generation number when reading tree blocksChris Mason1-3/+4
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Create a work queue for bio writesChris Mason1-0/+3
This allows checksumming to happen in parallel among many cpus, and keeps us from bogging down pdflush with the checksumming code. Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Write out all super blocks on commit, and bring back proper barrier ↵Chris Mason1-0/+1
support Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Handle data block end_io through the async work queueChris Mason1-0/+2
Before it was done by the bio end_io routine, the work queue code is able to scale much better with faster IO subsystems. Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Verify checksums on tree blocks found without read_tree_blockChris Mason1-0/+2
Checksums were only verified by btrfs_read_tree_block, which meant the functions to probe the page cache for blocks were not validating checksums. Normally this is fine because the buffers will only be in cache if they have already been validated. But, there is a window while the buffer is being read from disk where it could be up to date in the cache but not yet verified. This patch makes sure all buffers go through checksum verification before they are used. This is safer, and it prevents modification of buffers before they go through the csum code. Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Add support for device scanning and detection ioctlsChris Mason1-1/+3
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Add support for multiple devices per filesystemChris Mason1-0/+2
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Add some simple throttling to wait for data=ordered and snapshot deletionChris Mason1-0/+1
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Add data=ordered supportChris Mason1-0/+2
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 <[email protected]>
2008-09-25Btrfs: Support for online FS resize (grow and shrink)Chris Mason1-0/+2
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Add back file data checksummingChris Mason1-0/+2
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Add back the online defragging codeChris Mason1-0/+7
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Allow tree blocks larger than the page sizeChris Mason1-4/+5
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Create extent_buffer interface for large blocksizesChris Mason1-44/+11
Signed-off-by: Chris Mason <[email protected]>
2008-09-25Btrfs: Use balance_dirty_pages_nr on btree blocksChris Mason1-1/+1
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 <[email protected]>
2007-09-10Add support for defragging files via btrfsctl -d. Avoid OOM on extent treeChris Mason1-0/+2
defrag. Signed-off-by: Chris Mason <[email protected]>
2007-08-29Btrfs: Add per-root block accounting and sysfs entriesJosef Bacik1-1/+2
Signed-off-by: Chris Mason <[email protected]>
2007-08-27Btrfs: Extent based page cache code. This uses an rbtree of extents and testsChris Mason1-1/+0
instead of buffer heads. Signed-off-by: Chris Mason <[email protected]>
2007-08-10Btrfs: Add BH_Defrag to mark buffers that are in need of defraggingChris Mason1-0/+2
This allows the tree walking code to defrag only the newly allocated buffers, it seems to be a good balance between perfect defragging and the performance hit of repeatedly reallocating blocks. Signed-off-by: Chris Mason <[email protected]>
2007-06-28Btrfs: crash recovery fixesChris Mason1-0/+1
Signed-off-by: Chris Mason <[email protected]>
2007-06-22Btrfs: Add the ability to find and remove dead roots after a crash.Chris Mason1-0/+3
Signed-off-by: Chris Mason <[email protected]>
2007-06-12Btrfs: add GPLv2Chris Mason1-0/+18
Signed-off-by: Chris Mason <[email protected]>
2007-05-02Btrfs: fix page cache memory leakChris Mason1-0/+2
Signed-off-by: Chris Mason <[email protected]>
2007-05-01Btrfs: directory readaheadChris Mason1-0/+6
Signed-off-by: Chris Mason <[email protected]>
2007-04-12Btrfs: add a device id to device itemsChris Mason1-0/+1
Signed-off-by: Chris Mason <[email protected]>
2007-04-12Btrfs: add disk ioctl, mostly workingChris Mason1-0/+6
Signed-off-by: Chris Mason <[email protected]>
2007-04-11Btrfs: create a logical->phsyical block number mapping schemeChris Mason1-0/+1
Signed-off-by: Chris Mason <[email protected]>
2007-04-09Btrfs: groundwork for subvolume and snapshot rootsChris Mason1-0/+2
Signed-off-by: Chris Mason <[email protected]>
2007-04-02Btrfs: still corruption huntingChris Mason1-3/+1
Signed-off-by: Chris Mason <[email protected]>
2007-03-29Btrfs: verify csums on readChris Mason1-0/+2
Signed-off-by: Chris Mason <[email protected]>
2007-03-28Btrfs: use a btree inode instead of sb_getblkChris Mason1-2/+3
Signed-off-by: Chris Mason <[email protected]>
2007-03-22Btrfs: transaction reworkChris Mason1-4/+4
Signed-off-by: Chris Mason <[email protected]>
2007-03-22Mountable btrfs, with readdirChris Mason1-23/+28
Signed-off-by: Chris Mason <[email protected]>
2007-03-21Btrfs: initial move to kernel module landChris Mason1-0/+1
Signed-off-by: Chris Mason <[email protected]>
2007-03-16Btrfs: transaction handles everywhereChris Mason1-6/+10
Signed-off-by: Chris Mason <[email protected]>
2007-03-14Btrfs: variable block size supportChris Mason1-5/+4
Signed-off-by: Chris Mason <[email protected]>
2007-03-13Btrfs: Change the super to point to a tree of trees to enable persistent ↵Chris Mason1-1/+2
snapshots Signed-off-by: Chris Mason <[email protected]>
2007-03-13rename funcs and structs to btrfsChris Mason1-14/+15
Signed-off-by: Chris Mason <[email protected]>
2007-03-06Btrfs: Fixup reference counting on cowsChris Mason1-2/+2
Signed-off-by: Chris Mason <[email protected]>
2007-03-01Btrfs: pretend page cache & commit codeChris Mason1-0/+6
Signed-off-by: Chris Mason <[email protected]>
2007-02-23Btrfs: Block sized tree extents and extent deletionChris Mason1-1/+1
Signed-off-by: Chris Mason <[email protected]>
2007-02-21Btrfs: extent fixesChris Mason1-2/+2
Signed-off-by: Chris Mason <[email protected]>
2007-02-20Btrfs: early extent mapping supportChris Mason1-0/+3
Signed-off-by: Chris Mason <[email protected]>
2007-02-02Btrfs: Add backing store, memory managementChris Mason1-0/+21
Signed-off-by: Chris Mason <[email protected]>