Re: [PATCH] Btrfs: fix orphan cleanup regression

2011-10-04 Thread Milko Krachounov
Josef Bacik wrote: In fixing how we deal with bad inodes, we had a regression in the orphan cleanup code, since it expects to get a bad inode back. So fix it to deal with getting -ESTALE back by deleting the orphan item manually and moving on. Thanks, Reported-by: Simon Kirby

Re: Suddenly, a dead filesystem

2011-10-04 Thread Avi Kivity
On Mon, Oct 3, 2011 at 8:07 PM, Avi Kivity avi.kiv...@gmail.com wrote: Thats -EIO, is there any messages before the bug?  Thanks, Not that I recall.  I'll check again when I'm near the poor thing again. Confirmed - that's the first relevant message. As to -EIO, I dd'ed the entire volume

[PATCH] Btrfs: break out of orphan cleanup if we can't make progress V2

2011-10-04 Thread Josef Bacik
I noticed while running xfstests 83 that if we didn't have enough space to delete our inode the orphan cleanup would just loop. This is because it keeps finding the same orphan item and keeps trying to kill it but can't because we don't get an error back from iput for deleting the inode. So keep

[patch 02/65] btrfs: Catch locking failures in {set,clear}_extent_bit

2011-10-04 Thread Jeff Mahoney
The *_state functions can only return 0 or -EEXIST. This patch addresses the cases where those functions return -EEXIST, representing a locking failure. It handles them by panicking with an appropriate error message. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c | 41

[patch 09/65] btrfs: pin_down_extent should return void

2011-10-04 Thread Jeff Mahoney
pin_down_extent performs some operations which can't fail and then calls set_extent_dirty, which has two failure cases via set_extent_bit: 1) Return -EEXIST if exclusive bits are set - Since it doesn't use any exclusive bits, this failure case can't occur. 2) Return -ENOMEM if

[patch 34/65] btrfs: btrfs_init_compress should return void

2011-10-04 Thread Jeff Mahoney
btrfs_init_compress doesn't have any failure conditions, so return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/compression.h |2 +- fs/btrfs/super.c |5 + 2 files changed, 2 insertions(+), 5 deletions(-) --- a/fs/btrfs/compression.c +++

[patch 38/65] btrfs: btrfs_prepare_extent_commit should return void

2011-10-04 Thread Jeff Mahoney
btrfs_prepare_extent_commit has no error conditions and should return void. Its callers already ignore the error codes anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.h |4 ++-- fs/btrfs/extent-tree.c |3 +-- 2 files changed, 3 insertions(+), 4 deletions(-)

[patch 41/65] btrfs: btrfs_run_defrag_inodes should return void

2011-10-04 Thread Jeff Mahoney
btrfs_run_defrag_inodes has no error conditions and should return void. Its callers already ignore the error codes anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.h |2 +- fs/btrfs/file.c |3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) ---

[patch 45/65] btrfs: __add_reloc_root error push-up

2011-10-04 Thread Jeff Mahoney
This patch pushes kmalloc errors up to the caller and BUGs in the caller. The BUG_ON for duplicate reloc tree root insertion is replaced with a panic explaining the issue. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/relocation.c | 20 +++- 1 file changed, 15

[patch 37/65] btrfs: btrfs_destroy_delalloc_inodes should return void

2011-10-04 Thread Jeff Mahoney
btrfs_destroy_delalloc_inodes has no error conditions and should return void. Its callers already ignore the error codes anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/disk-io.c |6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) --- a/fs/btrfs/disk-io.c +++

[patch 35/65] btrfs: btrfs_invalidate_inodes should return void

2011-10-04 Thread Jeff Mahoney
btrfs_invalidate_inodes has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.h |2 +- fs/btrfs/inode.c |3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) --- a/fs/btrfs/ctree.h +++ b/fs/btrfs/ctree.h @@ -2590,7 +2590,7 @@

[patch 59/65] btrfs: __btrfs_mod_ref should return void

2011-10-04 Thread Jeff Mahoney
Now that process_func can't return an error, __btrfs_mod_ref has no more error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.c | 30 ++ fs/btrfs/ctree.h |8 fs/btrfs/extent-tree.c | 34

[patch 62/65] btrfs: btrfs_extend_item should return void

2011-10-04 Thread Jeff Mahoney
btrfs_extend_item has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.c |7 +++ fs/btrfs/ctree.h |5 +++-- fs/btrfs/dir-item.c|5 ++--- fs/btrfs/extent-tree.c |5 ++--- fs/btrfs/file-item.c |2 +-

[patch 63/65] btrfs: end_compressed_writeback should return void

2011-10-04 Thread Jeff Mahoney
end_compressed_writeback has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/compression.c |5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) --- a/fs/btrfs/compression.c +++

[patch 64/65] btrfs: copy_for_split should return void

2011-10-04 Thread Jeff Mahoney
copy_for_split has no error conditions and should return void. We return 0 from split_leaf instead of ret since ret would have been set using the return value from copy_for_split which would have been 0. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.c | 19

[patch 60/65] btrfs: clean_tree_block should return void

2011-10-04 Thread Jeff Mahoney
clean_tree_block has no error conditions and should return void. Its callers already ignore the error codes. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/disk-io.c |5 ++--- fs/btrfs/disk-io.h |4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) ---

[patch 65/65] btrfs: update_inline_extent_backref should return void

2011-10-04 Thread Jeff Mahoney
Now that btrfs_truncate_item returns void, there are no more error conditions in update_inline_extent_backref and it should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent-tree.c | 23 +++ 1 file changed, 11 insertions(+), 12 deletions(-) ---

[patch 61/65] btrfs: btrfs_truncate_item should return void

2011-10-04 Thread Jeff Mahoney
btrfs_truncate_item has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.c | 11 +-- fs/btrfs/ctree.h |8 fs/btrfs/dir-item.c|4 ++-- fs/btrfs/extent-tree.c |3 +-- fs/btrfs/file-item.c |

[patch 57/65] btrfs: btrfs_free_extent void return prep

2011-10-04 Thread Jeff Mahoney
btrfs_free_extent has no error conditions, but is used via process_func in __btrfs_mod_ref which requires it to return an int. This patch cleans up the callers to eliminate error handling that will never be used. The next patch makes both btrfs_free_extent and the other function used via

[patch 04/65] btrfs: Simplify btrfs_insert_root

2011-10-04 Thread Jeff Mahoney
btrfs_insert_root is just a wrapper for btrfs_insert_item. Just return the error directly. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/root-tree.c |9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) --- a/fs/btrfs/root-tree.c +++ b/fs/btrfs/root-tree.c @@ -116,13

[patch 01/65] btrfs: Add btrfs_panic()

2011-10-04 Thread Jeff Mahoney
As part of the effort to eliminate BUG_ON as an error handling technique, we need to determine which errors are actual logic errors, which are on-disk corruption, and which are normal runtime errors e.g. -ENOMEM. Annotating these error cases is helpful to understand and report them. This

[patch 36/65] btrfs: __setup_root should return void

2011-10-04 Thread Jeff Mahoney
__setup_root has no error conditions and should return void. Its callers already ignore the error codes anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/disk-io.c |9 - 1 file changed, 4 insertions(+), 5 deletions(-) --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c

[patch 58/65] btrfs: __btrfs_mod_refs process_func should return void

2011-10-04 Thread Jeff Mahoney
__btrfs_mod_ref's process_func function pointer calls btrfs_free_extent and btrfs_inc_extent_ref, which now both return only 0. This patches makes them return void and eliminates the error condition in __btrfs_mod_ref. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.h |

[patch 55/65] btrfs: Delayed ref mempool functions should return void

2011-10-04 Thread Jeff Mahoney
Now that the delayed ref code uses mempools, allocations can't fail, and there are no more error conditions to report. This patch makes the following functions return void: - btrfs_alloc_reserved_file_extent - btrfs_add_delayed_tree_ref - btrfs_add_delayed_data_ref -

[patch 54/65] btrfs: Use mempools for delayed refs

2011-10-04 Thread Jeff Mahoney
This patch converts the delayed ref code to use slab cache-backed mempools for allocating its nodes. The allocations happen deep in the call path where error recovery is impossible. By using mempools, we ensure that the allocations can't fail. Each mempool keeps a page of structures

[patch 52/65] btrfs: add_delayed_data_ref should return void

2011-10-04 Thread Jeff Mahoney
add_delayed_data_ref has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/delayed-ref.c | 17 +++-- 1 file changed, 7 insertions(+), 10 deletions(-) --- a/fs/btrfs/delayed-ref.c +++ b/fs/btrfs/delayed-ref.c @@ -520,11 +520,11 @@

[patch 53/65] btrfs: Fix kfree of member instead of structure

2011-10-04 Thread Jeff Mahoney
Correctness fix: The kfree calls in the add_delayed_* functions free the node that's passed into it, but the node is a member of another structure. It works because it's always the first member of the containing structure, but it should really be using the containing structure itself.

[patch 48/65] btrfs: del_ptr should return void

2011-10-04 Thread Jeff Mahoney
With fixup_low_keys now returning void, there are no error conditions for del_ptr to report so it should return void. We set ret = 0 explicitly in btrfs_del_items but I'm not convinced that the error handling code already there is correct. Signed-off-by: Jeff Mahoney je...@suse.com ---

[patch 49/65] btrfs: insert_ptr should return void

2011-10-04 Thread Jeff Mahoney
insert_ptr has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.c | 46 +- 1 file changed, 13 insertions(+), 33 deletions(-) --- a/fs/btrfs/ctree.c +++ b/fs/btrfs/ctree.c @@ -2114,12 +2114,11

[patch 47/65] btrfs: setup_items_for_insert should return void

2011-10-04 Thread Jeff Mahoney
setup_items_for_insert now has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.c | 26 ++ fs/btrfs/ctree.h |8 fs/btrfs/delayed-inode.c |6 ++ 3 files changed, 16

[patch 50/65] btrfs: add_delayed_ref_head should return void

2011-10-04 Thread Jeff Mahoney
add_delayed_ref_head has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/delayed-ref.c | 29 ++--- 1 file changed, 10 insertions(+), 19 deletions(-) --- a/fs/btrfs/delayed-ref.c +++ b/fs/btrfs/delayed-ref.c @@

[patch 46/65] btrfs: fixup_low_keys should return void

2011-10-04 Thread Jeff Mahoney
fixup_low_keys has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.c | 39 +++ 1 file changed, 11 insertions(+), 28 deletions(-) --- a/fs/btrfs/ctree.c +++ b/fs/btrfs/ctree.c @@ -1864,15 +1864,12 @@

[patch 51/65] btrfs: add_delayed_tree_ref should return void

2011-10-04 Thread Jeff Mahoney
add_delayed_tree_ref has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/delayed-ref.c | 15 ++- 1 file changed, 6 insertions(+), 9 deletions(-) --- a/fs/btrfs/delayed-ref.c +++ b/fs/btrfs/delayed-ref.c @@ -467,10 +467,10 @@

[patch 43/65] btrfs: Factor out tree-ops-merge_bio_hook call

2011-10-04 Thread Jeff Mahoney
In submit_extent_page, there's a visually noisy if statement that, in the midst of other conditions, does the tree dependency for tree-ops and tree-ops-merge_bio_hook before calling it, and then another condition afterwards. If an error is returned from merge_bio_hook, there's no way to catch

[patch 44/65] btrfs: -submit_bio_hook error push-up

2011-10-04 Thread Jeff Mahoney
This pushes failures from the submit_bio_hook callbacks, btrfs_submit_bio_hook and btree_submit_bio_hook into the callers, including callers of submit_one_bio where it catches the failures with BUG_ON. It also pushes up through the -readpage_io_failed_hook to end_bio_extent_writepage where

[patch 42/65] btrfs: Simplify btrfs_submit_bio_hook

2011-10-04 Thread Jeff Mahoney
btrfs_submit_bio_hook currently calls btrfs_bio_wq_end_io in either case of an if statement that determines one of the arguments. This patch moves the function call outside of the if statement and uses it to only determine the different argument. This allows us to catch an error in one place

[patch 39/65] btrfs: btrfs_set_block_group_rw should return void

2011-10-04 Thread Jeff Mahoney
btrfs_set_block_group_rw has no error conditions and should return void. Its callers already ignore the error codes anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ctree.h |4 ++-- fs/btrfs/extent-tree.c |3 +-- 2 files changed, 3 insertions(+), 4 deletions(-)

[patch 40/65] btrfs: setup_inline_extent_backref should return void

2011-10-04 Thread Jeff Mahoney
setup_inline_extent_backref has no error conditions and should return void. We set ret = 0 explicitly in insert_inline_extent_backref since it would have been set using the return value, which would have been 0. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent-tree.c | 23

[patch 33/65] btrfs: tree-log: wait_for_writer should return void

2011-10-04 Thread Jeff Mahoney
wait_for_writer has no error conditions and should return void. Its callers already ignore the error codes anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/tree-log.c |5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) --- a/fs/btrfs/tree-log.c +++

[patch 31/65] btrfs: btrfs_requeue_work should return void

2011-10-04 Thread Jeff Mahoney
btrfs_requeue_work has no error conditions and should return void. Its callers ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/async-thread.c |7 ++- fs/btrfs/async-thread.h |2 +- 2 files changed, 3 insertions(+), 6 deletions(-) ---

[patch 29/65] btrfs: run_ordered_completions should return void

2011-10-04 Thread Jeff Mahoney
run_ordered_completions has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/async-thread.c |5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) --- a/fs/btrfs/async-thread.c +++

[patch 30/65] btrfs: btrfs_stop_workers should return void

2011-10-04 Thread Jeff Mahoney
btrfs_stop_workers has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/async-thread.c |3 +-- fs/btrfs/async-thread.h |2 +- 2 files changed, 2 insertions(+), 3 deletions(-) ---

[patch 26/65] btrfs: schedule_bio should return void

2011-10-04 Thread Jeff Mahoney
schedule_bio has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/volumes.c |4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@

[patch 28/65] btrfs: btrfs_queue_worker should return void

2011-10-04 Thread Jeff Mahoney
btrfs_queue_worker has no error conditions and should return void. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/async-thread.c | 14 -- fs/btrfs/async-thread.h |2 +- 2 files changed, 5 insertions(+), 11 deletions(-) --- a/fs/btrfs/async-thread.c +++

[patch 23/65] btrfs: btrfs_cleanup_fs_uuids should return void

2011-10-04 Thread Jeff Mahoney
btrfs_cleanup_fs_uuids has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/volumes.c |3 +-- fs/btrfs/volumes.h |2 +- 2 files changed, 2 insertions(+), 3 deletions(-) ---

[patch 24/65] btrfs: run_scheduled_bios should return void

2011-10-04 Thread Jeff Mahoney
run_scheduled_bios has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/volumes.c |3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c

[patch 22/65] btrfs: clear_extent_buffer_dirty should return void

2011-10-04 Thread Jeff Mahoney
clear_extent_buffer_dirty has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |3 +-- fs/btrfs/extent_io.h |2 +- 2 files changed, 2 insertions(+), 3 deletions(-) ---

[patch 21/65] btrfs: check_page_writeback should return void

2011-10-04 Thread Jeff Mahoney
check_page_writeback has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) --- a/fs/btrfs/extent_io.c +++

[patch 19/65] btrfs: check_page_uptodate should return void

2011-10-04 Thread Jeff Mahoney
check_page_uptodate has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/fs/btrfs/extent_io.c +++

[patch 20/65] btrfs: check_page_locked should return void

2011-10-04 Thread Jeff Mahoney
check_page_locked has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/fs/btrfs/extent_io.c +++

[patch 17/65] btrfs: wait_extent_bit should return void

2011-10-04 Thread Jeff Mahoney
wait_extent_bit has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |3 +-- fs/btrfs/extent_io.h |2 +- 2 files changed, 2 insertions(+), 3 deletions(-) ---

[patch 18/65] btrfs: __unlock_for_delalloc should return void

2011-10-04 Thread Jeff Mahoney
__unlock_for_delalloc has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |9 - 1 file changed, 4 insertions(+), 5 deletions(-) --- a/fs/btrfs/extent_io.c +++

[patch 16/65] btrfs: wait_on_state should return void

2011-10-04 Thread Jeff Mahoney
wait_on_state has no error conditions and should return void. Its callers already ignore the error code anyway. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) --- a/fs/btrfs/extent_io.c +++

[patch 15/65] btrfs: set_range_writeback should return void

2011-10-04 Thread Jeff Mahoney
set_range_writeback has no error conditions and should return void. Its callers already ignore the error code anyway. There are internal error conditions but they are fatal and will cause a panic. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/extent_io.c |8 +--- 1 file

[patch 14/65] btrfs: btrfs_update_root error push-up

2011-10-04 Thread Jeff Mahoney
btrfs_update_root BUG's when it can't alloc a path, yet it can recover from a search error. This patch returns -ENOMEM instead. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/root-tree.c |4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) --- a/fs/btrfs/root-tree.c +++

[patch 13/65] btrfs: find_and_setup_root error push-up

2011-10-04 Thread Jeff Mahoney
find_and_setup_root BUGs when it encounters an error from btrfs_find_last_root, which can occur if a path can't be allocated. This patch pushes it up to its callers where it is already handled. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/disk-io.c |3 ++- 1 file changed, 2

[patch 07/65] btrfs: clear_extent_bit error push-up

2011-10-04 Thread Jeff Mahoney
clear_extent_bit can fail with -ENOMEM for a specific case but will BUG on other memory allocation failures. This patch returns -ENOMEM for memory allocation failures and handles them with BUG_ON in callers which don't handle it already. Signed-off-by: Jeff Mahoney je...@suse.com ---

[patch 08/65] btrfs: unlock_extent error push-up

2011-10-04 Thread Jeff Mahoney
The previous patch pushed the clear_extent_bit error handling up a level, which included unlock_extent and unlock_extent_cache. This patch pushes the BUG_ON up into the callers of those functions. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/compression.c |9 ++--

[patch 05/65] btrfs: set_extent_bit error push-up

2011-10-04 Thread Jeff Mahoney
In the locking case, set_extent_bit can return -EEXIST but callers already handle that. In the non-locking case, it can't fail. Memory allocation failures are handled by BUG_ON. This patch pushes up the BUG_ONs from set_extent_bit to callers, except where -ENOMEM can't occur (e.g.

[patch 12/65] btrfs: btrfs_start_transaction non-looped error push-up

2011-10-04 Thread Jeff Mahoney
This patch handles btrfs_start_transaction failures that don't occur in a loop and are obvious to simply push up. In all cases except the mark_garbage_root case, the error is already handled by BUG_ON in the caller. Update v2: This version also checks the returns from btrfs_drop_snapshot.

[patch 06/65] btrfs: lock_extent error push-up

2011-10-04 Thread Jeff Mahoney
lock_extent, try_lock_extent, and lock_extent_bits can't currently fail because errors are caught via BUG_ON. This patch pushes the error handling up to callers, which currently only handle them via BUG_ON themselves. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/compression.c

[patch 03/65] btrfs: Panic on bad rbtree operations

2011-10-04 Thread Jeff Mahoney
The ordered data and relocation trees have BUG_ONs to protect against bad tree operations. This patch replaces them with a panic that will report the problem. Signed-off-by: Jeff Mahoney je...@suse.com --- fs/btrfs/ordered-data.c | 12 ++-- fs/btrfs/relocation.c | 36

[patch 10/65] btrfs: btrfs_pin_extent error push-up

2011-10-04 Thread Jeff Mahoney
btrfs_pin_extent looks up a block group and then calls pin_down_extent with it. If the lookup fails, it should return -ENOENT to allow callers to handle the error condition. For the three existing callers, it is a logic error if the lookup fails and a panic will occur. Signed-off-by: Jeff

Re: Suddenly, a dead filesystem

2011-10-04 Thread Avi Kivity
On Tue, Oct 4, 2011 at 4:39 PM, Avi Kivity avi.kiv...@gmail.com wrote: On Mon, Oct 3, 2011 at 8:07 PM, Avi Kivity avi.kiv...@gmail.com wrote: Thats -EIO, is there any messages before the bug?  Thanks, Not that I recall.  I'll check again when I'm near the poor thing again. Confirmed -

Re: Suddenly, a dead filesystem

2011-10-04 Thread Josef Bacik
On 10/04/2011 03:50 PM, Avi Kivity wrote: Yup I would love to investigate this, what kind of snapshot? LVM snapshot. Did you dd the drive or soemthing? Let me know where to pull it down. Um, it's my /home. It's not leaving home. But if you have test kernels or btrfscks you want to

Re: Suddenly, a dead filesystem

2011-10-04 Thread Avi Kivity
On Tue, Oct 4, 2011 at 10:01 PM, Josef Bacik jo...@redhat.com wrote: On 10/04/2011 03:50 PM, Avi Kivity wrote: Yup I would love to investigate this, what kind of snapshot? LVM snapshot. Did you dd the drive or soemthing?  Let me know where to pull it down. Um, it's my /home.  It's not

Re: Honest timeline for btrfsck

2011-10-04 Thread Jeff Putney
That 2 week time line has now reached the 9 week mark. The only update anyone has seen was 7 weeks ago, with a 'maybe today'. Isn't it time to get that code checked in so someone else can take over, and not have to start from scratch? Even if there isn't any actual working code, having any

[PATCH, resend for 3.2] btrfs: add CONFIG_BTRFS_DEBUG option

2011-10-04 Thread David Sterba
Signed-off-by: David Sterba dste...@suse.cz --- fs/btrfs/Kconfig | 10 ++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/fs/btrfs/Kconfig b/fs/btrfs/Kconfig index ecb9fd3..5601066 100644 --- a/fs/btrfs/Kconfig +++ b/fs/btrfs/Kconfig @@ -31,3 +31,13 @@ config