Btrfs: More throttle tuning
* Make walk_down_tree wake up throttled tasks more often
* Make walk_down_tree call cond_resched during long loops
* As the size of the ref cache grows, wait longer in throttle
* Get rid of the reada code in walk_down_tree, the leaves don't get
read anymore, thanks to the ref cache.
Signed-off-by: Chris Mason <chris.mason@oracle.com>
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c
index d2d1cc8..da9dda4 100644
--- a/fs/btrfs/disk-io.c
+++ b/fs/btrfs/disk-io.c
@@ -188,13 +188,6 @@
btrfs_csum_final(crc, result);
if (verify) {
- int from_this_trans = 0;
-
- if (root->fs_info->running_transaction &&
- btrfs_header_generation(buf) ==
- root->fs_info->running_transaction->transid)
- from_this_trans = 1;
-
/* FIXME, this is not good */
if (memcmp_extent_buffer(buf, result, 0, BTRFS_CRC32_SIZE)) {
u32 val;
@@ -203,11 +196,9 @@
read_extent_buffer(buf, &val, 0, BTRFS_CRC32_SIZE);
printk("btrfs: %s checksum verify failed on %llu "
- "wanted %X found %X from_this_trans %d "
- "level %d\n",
+ "wanted %X found %X level %d\n",
root->fs_info->sb->s_id,
- buf->start, val, found, from_this_trans,
- btrfs_header_level(buf));
+ buf->start, val, found, btrfs_header_level(buf));
return 1;
}
} else {