aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/bcache/debug.c
diff options
context:
space:
mode:
authorKent Overstreet <kmo@daterainc.com>2013-12-18 00:56:21 -0500
committerKent Overstreet <kmo@daterainc.com>2014-01-08 16:05:12 -0500
commitfafff81cead78157099df1ee10af16cc51893ddc (patch)
treea198145a2ac94431667e82e2eb09c1365fb94b84 /drivers/md/bcache/debug.c
parent085d2a3dd4d65b7bce1dead987c647dbbc014281 (diff)
bcache: Bkey indexing renaming
More refactoring: node() -> bset_bkey_idx() end() -> bset_bkey_last() Signed-off-by: Kent Overstreet <kmo@daterainc.com>
Diffstat (limited to 'drivers/md/bcache/debug.c')
-rw-r--r--drivers/md/bcache/debug.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/md/bcache/debug.c b/drivers/md/bcache/debug.c
index 8887c550d56c..955fa1d31774 100644
--- a/drivers/md/bcache/debug.c
+++ b/drivers/md/bcache/debug.c
@@ -84,7 +84,7 @@ static void dump_bset(struct btree *b, struct bset *i, unsigned set)
84 unsigned j; 84 unsigned j;
85 char buf[80]; 85 char buf[80];
86 86
87 for (k = i->start; k < end(i); k = next) { 87 for (k = i->start; k < bset_bkey_last(i); k = next) {
88 next = bkey_next(k); 88 next = bkey_next(k);
89 89
90 bch_bkey_to_text(buf, sizeof(buf), k); 90 bch_bkey_to_text(buf, sizeof(buf), k);
@@ -102,7 +102,7 @@ static void dump_bset(struct btree *b, struct bset *i, unsigned set)
102 102
103 printk(" %s\n", bch_ptr_status(b->c, k)); 103 printk(" %s\n", bch_ptr_status(b->c, k));
104 104
105 if (next < end(i) && 105 if (next < bset_bkey_last(i) &&
106 bkey_cmp(k, !b->level ? &START_KEY(next) : next) > 0) 106 bkey_cmp(k, !b->level ? &START_KEY(next) : next) > 0)
107 printk(KERN_ERR "Key skipped backwards\n"); 107 printk(KERN_ERR "Key skipped backwards\n");
108 } 108 }
@@ -162,7 +162,7 @@ void bch_btree_verify(struct btree *b)
162 if (inmemory->keys != sorted->keys || 162 if (inmemory->keys != sorted->keys ||
163 memcmp(inmemory->start, 163 memcmp(inmemory->start,
164 sorted->start, 164 sorted->start,
165 (void *) end(inmemory) - (void *) inmemory->start)) { 165 (void *) bset_bkey_last(inmemory) - (void *) inmemory->start)) {
166 struct bset *i; 166 struct bset *i;
167 unsigned j; 167 unsigned j;
168 168