Hi everyone, My for-linus branch is updated for 3.5: git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linus This includes a fairly large change from Josef around data writeback completion. Before, the writeback wasn''t completed until the metadata insertions for the extent were done, and this made for fairly large latency spikes on the last page of each ordered extent. We already had a separate mechanism for tracking pending metadata insertions, so Josef just needed to tweak things a little to end writeback earlier on the page. Overall it makes us much friendly to memory reclaim and lowers latencies quite a lot for synchronous IO. Jan Schmidt has finished some background work required to track btree blocks as they go through changes in ownership. It''s the missing piece he needed for both btrfs send/receive and subvolume quotas. Neither of those are ready yet, but the new tracking code is included here. Most of the time, the new code is off. It is only used by scrub and other backref walkers. Stefan Behrens has added io failure tracking. This includes counters for which drives are causing the most trouble so the admin (or an automated tool) can choose to kick them out. We''re tracking IO errors, crc errors, and generation checks we do on each metadata block. RAID5/6 did miss the cut this time because I''m having trouble with corruptions. I''ll nail it down next week and post as a beta testing before 3.6 Jan Schmidt (21) commits (+1405/-290): Btrfs: bugfix: ignore the wrong key for indirect tree block backrefs (+135/-50) Btrfs: add del_ptr and insert_ptr modifications to the tree mod log (+32/-10) Btrfs: add inodes before dropping the extent lock in find_all_leafs (+43/-6) Btrfs: fix tree mod log rewinded level and rewinding of moved keys (+4/-2) Btrfs: use delayed ref sequence numbers for all fs-tree updates (+13/-23) Btrfs: add missing spin_lock for insertion into tree mod log (+18/-5) Btrfs: don''t set for_cow parameter for tree block functions (+20/-20) Btrfs: use the tree modification log for backref resolving (+29/-17) Btrfs: put all block modifications into the tree mod log (+36/-0) Btrfs: tree mod log sanity checks in join_transaction (+18/-0) Btrfs: look into the extent during find_all_leafs (+158/-84) Btrfs: fs_info variable for join_transaction (+19/-18) Btrfs: dummy extent buffers for tree mod log (+76/-7) Btrfs: add tree modification log functions (+412/-1) Btrfs: bugfix in btrfs_find_parent_nodes (+3/-2) Btrfs: move struct seq_list to ctree.h (+7/-5) Btrfs: add tree_mod_dont_log helper (+15/-9) Btrfs: add tree mod log to fs_info (+14/-0) Btrfs: add btrfs_search_old_slot (+317/-4) Btrfs: fix tree mod log del_ptr (+7/-6) Btrfs: ulist realloc bugfix (+29/-21) Josef Bacik (13) commits (+330/-322): Btrfs: convert the inode bit field to use the actual bit operations (+44/-44) Btrfs: check to see if the inode is in the log before fsyncing (+16/-17) Btrfs: merge contigous regions when loading free space cache (+41/-0) Btrfs: fall back to non-inline if we don''t have enough space (+4/-1) Btrfs: do not check delalloc when updating disk_i_size (+3/-16) Btrfs: do not do filemap_write_and_wait_range in fsync (+6/-5) Btrfs: finish ordered extents in their own thread (+164/-191) Btrfs: remove useless waiting and extra filemap work (+2/-15) Btrfs: fix how we deal with the orphan block rsv (+24/-22) Btrfs: use i_version instead of our own sequence (+19/-10) Btrfs: fix return code in drop_objectid_items (+2/-0) Btrfs: fix compile warnings in extent_io.c (+1/-1) Btrfs: cache no acl on new inodes (+4/-0) Stefan Behrens (7) commits (+985/-174): Btrfs: read device stats on mount, write modified ones during commit (+232/-0) Btrfs: add device counters for detected IO and checksum errors (+230/-24) Btrfs: fix runtime warning in check-integrity check data mode (+22/-3) Btrfs: change integrity checker to support big blocks (+415/-146) Btrfs: fix false positive in check-integrity on unmount (+1/-1) Btrfs: add ioctl to get and reset the device stats (+77/-0) Btrfs: set ioprio of scrub readahead to idle (+8/-0) Wang Sheng-Hui (5) commits (+7/-8): Btrfs: remove the useless assignment to *entry in function tree_insert of file extent_io.c (+0/-1) Btrfs: fix btrfs_release_extent_buffer_page with the right usage of num_extent_pages (+3/-1) btrfs/ctree.c: remove the unnecessary ''return -1;'' at the end of bin_search (+2/-4) Btrfs: cleanup the comment for clear_state_bit in extent_io.c (+1/-1) Btrfs: fix the comment for find_first_extent_bit (+1/-1) Jim Meyering (3) commits (+32/-44): Btrfs: NUL-terminate path buffer in DEV_INFO ioctl result (+4/-2) Btrfs: avoid buffer overrun in mount option handling (+26/-41) Btrfs: avoid buffer overrun in btrfs_printk (+2/-1) Liu Bo (3) commits (+28/-30): Btrfs: use fastpath in extent state ops as much as possible (+18/-26) Btrfs: fix wrong error returned by adding a device (+1/-1) Btrfs: do not do balance in readonly mode (+9/-3) Sergei Trofimovich (1) commits (+40/-5): btrfs: allow changing ''thread_pool'' size at remount time Daniel J Blueman (1) commits (+5/-6): Fix minor type issues Dan Carpenter (1) commits (+1/-1): Btrfs: cleanup: use consistent lock naming Asias He (1) commits (+0/-14): btrfs: Drop unused function btrfs_abort_devices() Miao Xie (1) commits (+39/-10): Btrfs: fix the same inode id problem when doing auto defragment Tsutomu Itoh (1) commits (+18/-4): Btrfs: return value of btrfs_read_buffer is checked correctly Total: (58) commits fs/btrfs/acl.c | 4 + fs/btrfs/backref.c | 495 +++++++++++++++++-------- fs/btrfs/backref.h | 3 +- fs/btrfs/btrfs_inode.h | 50 ++- fs/btrfs/check-integrity.c | 584 +++++++++++++++++++++-------- fs/btrfs/ctree.c | 861 +++++++++++++++++++++++++++++++++++++++++-- fs/btrfs/ctree.h | 77 +++- fs/btrfs/delayed-inode.c | 8 +- fs/btrfs/delayed-ref.c | 10 +- fs/btrfs/delayed-ref.h | 24 -- fs/btrfs/disk-io.c | 57 ++- fs/btrfs/disk-io.h | 1 - fs/btrfs/extent-tree.c | 23 +- fs/btrfs/extent_io.c | 168 ++++++--- fs/btrfs/extent_io.h | 8 +- fs/btrfs/file.c | 76 ++-- fs/btrfs/free-space-cache.c | 45 ++- fs/btrfs/inode.c | 264 +++++++------ fs/btrfs/ioctl.c | 50 ++- fs/btrfs/ioctl.h | 33 ++ fs/btrfs/ordered-data.c | 165 ++++----- fs/btrfs/ordered-data.h | 13 +- fs/btrfs/print-tree.c | 3 + fs/btrfs/reada.c | 5 + fs/btrfs/scrub.c | 65 +++- fs/btrfs/super.c | 117 +++--- fs/btrfs/transaction.c | 59 ++- fs/btrfs/tree-log.c | 35 +- fs/btrfs/ulist.c | 38 +- fs/btrfs/ulist.h | 15 +- fs/btrfs/volumes.c | 306 ++++++++++++++- fs/btrfs/volumes.h | 52 +++ fs/btrfs/xattr.c | 1 + 33 files changed, 2849 insertions(+), 866 deletions(-)
Hi Linus, Please pull my for-linus branch: git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linus The dates look like I had to rebase this morning because there was a compiler warning for a printk arg that I had missed earlier. These are all fixes, including one to prevent using stale pointers for device names, and lots of fixes around transaction abort cleanups (Josef, Liu Bo). Jan Schmidt also sent in a number of fixes for the new reference number tracking code. Liu Bo beat me to updating the MAINTAINERS file. Since he thought to also fix the git url, I kept his commit. Josef Bacik (10) commits (+303/-102): Btrfs: pass locked_page into extent_clear_unlock_delalloc if theres an error (+2/-2) Btrfs: unlock everything properly in the error case for nocow (+35/-2) Btrfs: wake up transaction waiters when aborting a transaction (+7/-6) Btrfs: call filemap_fdatawrite twice for compression (+31/-7) Btrfs: fix locking in btrfs_destroy_delayed_refs (+17/-13) Btrfs: keep inode pinned when compressing writes (+6/-2) Btrfs: abort the transaction if the commit fails (+8/-2) Btrfs: use rcu to protect device->name (+162/-64) Btrfs: fix btrfs_destroy_marked_extents (+2/-4) Btrfs: implement ->show_devname (+33/-0) Jan Schmidt (6) commits (+72/-37): Btrfs: remove obsolete btrfs_next_leaf call from __resolve_indirect_ref (+1/-9) Btrfs: remove call to btrfs_header_nritems with no effect (+0/-3) Btrfs: fix return value for __tree_mod_log_oldest_root (+20/-13) Btrfs: use btrfs_read_lock_root_node in get_old_root (+16/-4) Btrfs: fix race in tree mod log addition (+19/-4) Btrfs: add btrfs_next_old_leaf (+16/-4) Liu Bo (5) commits (+29/-5): Btrfs: avoid memory leak of extent state in error handling routine (+2/-0) Btrfs: make sure that we''ve made everything in pinned tree clean (+11/-0) Btrfs: update MAINTAINERS info for BTRFS FILE SYSTEM (+2/-2) Btrfs: fix missing inherited flag in rename (+6/-3) Btrfs: do not resize a seeding device (+8/-0) Li Zefan (2) commits (+50/-49): Btrfs: fix incompat flags setting (+1/-1) Btrfs: fix defrag regression (+49/-48) Miao Xie (1) commits (+27/-0): Btrfs: destroy the items of the delayed inodes in error handling routine Total: (24) commits (+481/-193) MAINTAINERS | 4 +- fs/btrfs/backref.c | 17 ++----- fs/btrfs/btrfs_inode.h | 1 + fs/btrfs/check-integrity.c | 16 +++--- fs/btrfs/ctree.c | 86 +++++++++++++++++++++++--------- fs/btrfs/ctree.h | 2 + fs/btrfs/delayed-inode.c | 18 +++++++ fs/btrfs/delayed-inode.h | 3 ++ fs/btrfs/disk-io.c | 76 +++++++++++++++++----------- fs/btrfs/extent_io.c | 7 +-- fs/btrfs/inode.c | 73 +++++++++++++++++++++------ fs/btrfs/ioctl.c | 118 +++++++++++++++++++++++++------------------- fs/btrfs/ordered-data.c | 22 ++++++++- fs/btrfs/rcu-string.h | 56 +++++++++++++++++++++ fs/btrfs/scrub.c | 30 ++++++----- fs/btrfs/super.c | 33 +++++++++++++ fs/btrfs/transaction.c | 14 +++++- fs/btrfs/volumes.c | 92 +++++++++++++++++++++------------- fs/btrfs/volumes.h | 2 +- 19 files changed, 479 insertions(+), 191 deletions(-)
On Fri, Jun 15, 2012 at 11:09 AM, Chris Mason <chris.mason@fusionio.com> wrote:> > Please pull my for-linus branch: > > git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linusThis seems to introduce a new warning: In file included from fs/btrfs/ctree.c:22:0: fs/btrfs/ctree.c: In function ‘btrfs_search_old_slot’: fs/btrfs/ctree.h:2117:240: warning: ‘old_generation’ may be used uninitialized in this function [-Wmaybe-uninitialized] fs/btrfs/ctree.c:1178:6: note: ‘old_generation’ was declared here which looks like just gcc being unable to see that it is only used when set, but it''s still annoying. I''d suggest initializing it to 0 just to shut up the compiler. Ok? Linus
On Fri, Jun 15, 2012 at 05:57:42PM -0600, Linus Torvalds wrote:> On Fri, Jun 15, 2012 at 11:09 AM, Chris Mason <chris.mason@fusionio.com> wrote: > > > > Please pull my for-linus branch: > > > > git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linus > > This seems to introduce a new warning: > > In file included from fs/btrfs/ctree.c:22:0: > fs/btrfs/ctree.c: In function ‘btrfs_search_old_slot’: > fs/btrfs/ctree.h:2117:240: warning: ‘old_generation’ may be used > uninitialized in this function [-Wmaybe-uninitialized] > fs/btrfs/ctree.c:1178:6: note: ‘old_generation’ was declared here > > which looks like just gcc being unable to see that it is only used > when set, but it''s still annoying. I''d suggest initializing it to 0 > just to shut up the compiler. Ok? >Yes, this does look like noise. It is only used when old_root is set, but it''ll be really easy to add bugs there later. I''ve pushed two commits out, the second one is a printk cast on 32 bit machines. Neither of these are fatal but they are in for-linus: git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linus Chris Mason (2) commits (+3/-2): Btrfs: cast devid to unsigned long long for printk %llu (+2/-1) Btrfs: init old_generation in get_old_root (+1/-1) Total: (2) commits (+3/-2) fs/btrfs/ctree.c | 2 +- fs/btrfs/ioctl.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Linus, Please grab my for-linus branch: git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs.git for-linus This is a small pull with btrfs fixes. The biggest of the bunch is another fix for the new backref walking code. We''re still hammering out one btrfs dio vs buffered reads problem, but that one will have to wait for the next rc. Josef Bacik (2) commits (+3/-2): Btrfs: delay iput with async extents (+2/-2) Btrfs: add a missing spin_lock (+1/-0) Alexander Block (2) commits (+59/-44): Btrfs: don''t assume to be on the correct extent in add_all_parents (+52/-42) Btrfs: introduce btrfs_next_old_item (+7/-2) Total: (4) commits (+62/-46) fs/btrfs/backref.c | 94 +++++++++++++++++++++++++++++----------------------- fs/btrfs/ctree.h | 9 +++-- fs/btrfs/disk-io.c | 1 + fs/btrfs/inode.c | 4 +-- 4 files changed, 62 insertions(+), 46 deletions(-)