Skip to contentSkip to conversation

code problem report

DISCUSSION sniper 1 participant 1 message Feb 9, 2009 Btrfs file system

lore
Share & tools
lore

sniper

author
#0 lore raw

31 int btrfs_defrag_leaves(struct btrfs_trans_handle *trans,
32 struct btrfs_root *root, int cache_only)
33 {
...
45 if (cache_only) //check once
46 goto out;
....
79 root->defrag_max.objectid = 0; //needless? The
following code will rewrite soon.
80 /* from above we know this is not a leaf */
81 btrfs_node_key_to_cpu(root_node, &root->defrag_max,
82 nritems - 1);
...
91 if (cache_only) //?check again. It seems no one can
modify 'cache_only', which check is needless or wrong?
92 min_trans = root->defrag_trans_start;
...
129 out: