]> git.neil.brown.name Git - LaFS.git/commitdiff
Add cluster list tracking to print_tree
authorNeilBrown <neilb@suse.de>
Fri, 25 Jun 2010 09:17:29 +0000 (19:17 +1000)
committerNeilBrown <neilb@suse.de>
Sun, 27 Jun 2010 23:14:59 +0000 (09:14 +1000)
In print tree, where we try to print which 'lru' list a block
is on, also check the write-cluster lists, both in preparation,
and waiting for Writeout.

Signed-off-by: NeilBrown <neilb@suse.de>
checkpoint.c

index 22f4cee01d303c402dce7ba87d5e97d6130cadfe..084db6b247d73964348631c341f4dff070280052 100644 (file)
@@ -230,7 +230,24 @@ int lafs_print_tree(struct block *b, int depth)
                        break;
                }
        }
-       /* print the flags */
+       for (i = 0 ; i < 2; i++) {
+               int j, k;
+               j = 0;
+               list_for_each_entry(b2, &dfs->wc[i].clhead, lru) {
+                       if (b2 == b)
+                               printk(" wc[%d][%d] ", i, j);
+                       j++;
+               }
+               for (k = 0; k < 4; k++) {
+                       j = 0;
+                       list_for_each_entry(b2, &dfs->wc[i].pending_blocks[k], lru) {
+                               if (b2 == b)
+                                       printk(" pending[%d][%d][%d] ", i, k, j);
+                               j++;
+                       }
+               }
+       }
+
        printk("\n");
        if (test_bit(B_Index, &b->flags) && ib->uninc_table.pending_cnt) {
                lafs_print_uninc(&ib->uninc_table);