Btrfs: Drop some verbose printks
authorChris Mason <chris.mason@oracle.com>
Mon, 28 Apr 2008 20:40:52 +0000 (16:40 -0400)
committerChris Mason <chris.mason@oracle.com>
Thu, 25 Sep 2008 15:04:02 +0000 (11:04 -0400)
Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/disk-io.c
fs/btrfs/extent_io.c
fs/btrfs/volumes.c

index a9ce491..1c7d84a 100644 (file)
@@ -214,25 +214,18 @@ static int btree_read_extent_buffer_pages(struct btrfs_root *root,
        while (1) {
                ret = read_extent_buffer_pages(io_tree, eb, start, 1,
                                               btree_get_extent, mirror_num);
-               if (!ret) {
-                       if (mirror_num)
-printk("good read %Lu mirror %d total %d\n", eb->start, mirror_num, num_copies);
+               if (!ret)
                        return ret;
-               }
+
                num_copies = btrfs_num_copies(&root->fs_info->mapping_tree,
                                              eb->start, eb->len);
-printk("failed to read %Lu mirror %d total %d\n", eb->start, mirror_num, num_copies);
-               if (num_copies == 1) {
-printk("reading %Lu failed only one copy\n", eb->start);
+               if (num_copies == 1)
                        return ret;
-               }
+
                mirror_num++;
-               if (mirror_num > num_copies) {
-printk("bailing at mirror %d of %d\n", mirror_num, num_copies);
+               if (mirror_num > num_copies)
                        return ret;
-               }
        }
-printk("read extent buffer page last\n");
        return -EIO;
 }
 
@@ -322,7 +315,6 @@ int btree_readpage_end_io_hook(struct page *page, u64 start, u64 end,
        btrfs_clear_buffer_defrag(eb);
        found_start = btrfs_header_bytenr(eb);
        if (found_start != start) {
-printk("bad start on %Lu found %Lu\n", eb->start, found_start);
                ret = -EIO;
                goto err;
        }
index 2368536..dd403b4 100644 (file)
@@ -3003,17 +3003,18 @@ int extent_buffer_uptodate(struct extent_io_tree *tree,
                           struct extent_buffer *eb)
 {
        int ret = 0;
-       int ret2;
        unsigned long num_pages;
        unsigned long i;
        struct page *page;
        int pg_uptodate = 1;
 
        if (eb->flags & EXTENT_UPTODATE)
-               ret = 1;
+               return 1;
 
-       ret = test_range_bit(tree, eb->start, eb->start + eb->len - 1,
+       ret = test_range_bit(tree, eb->start, eb->start + eb->len - 1,
                           EXTENT_UPTODATE, 1);
+       if (ret)
+               return ret;
 
        num_pages = num_extent_pages(eb->start, eb->len);
        for (i = 0; i < num_pages; i++) {
@@ -3023,11 +3024,7 @@ int extent_buffer_uptodate(struct extent_io_tree *tree,
                        break;
                }
        }
-       if ((ret || ret2) && !pg_uptodate) {
-printk("uptodate error2 eb %Lu ret %d ret2 %d pg_uptodate %d\n", eb->start, ret, ret2, pg_uptodate);
-               WARN_ON(1);
-       }
-       return (ret || ret2);
+       return pg_uptodate;
 }
 EXPORT_SYMBOL(extent_buffer_uptodate);
 
index 6476ecb..9a72411 100644 (file)
@@ -1282,7 +1282,6 @@ again:
                                         num_stripes, sub_stripes);
 
        index = 0;
-printk("new chunk type %Lu start %Lu size %Lu\n", type, key.offset, *num_bytes);
        while(index < num_stripes) {
                struct btrfs_stripe *stripe;
                BUG_ON(list_empty(&private_devs));
@@ -1299,7 +1298,6 @@ printk("new chunk type %Lu start %Lu size %Lu\n", type, key.offset, *num_bytes);
                             BTRFS_FIRST_CHUNK_TREE_OBJECTID, key.offset,
                             calc_size, &dev_offset);
                BUG_ON(ret);
-printk("alloc chunk start %Lu size %Lu from dev %Lu type %Lu\n", key.offset, calc_size, device->devid, type);
                device->bytes_used += calc_size;
                ret = btrfs_update_device(trans, device);
                BUG_ON(ret);