summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2016-04-18 23:00:56 -0800
committerKent Overstreet <kent.overstreet@gmail.com>2016-08-28 19:15:16 -0800
commitbf2528e1c75f161533b79e963e508eb971e2ebf0 (patch)
tree5d984faba6cee4062d09ac99e772eb16a43b57d6
parent34cd89b81a783a5324baf05bbe2dbfae5d9a2df0 (diff)
XXX writeback throttling
-rw-r--r--fs/bcachefs/Kconfig (renamed from drivers/md/bcache/Kconfig)0
-rw-r--r--fs/bcachefs/Makefile (renamed from drivers/md/bcache/Makefile)0
-rw-r--r--fs/bcachefs/acl.c (renamed from drivers/md/bcache/acl.c)0
-rw-r--r--fs/bcachefs/acl.h (renamed from drivers/md/bcache/acl.h)0
-rw-r--r--fs/bcachefs/alloc.c (renamed from drivers/md/bcache/alloc.c)2
-rw-r--r--fs/bcachefs/alloc.h (renamed from drivers/md/bcache/alloc.h)0
-rw-r--r--fs/bcachefs/alloc_types.h (renamed from drivers/md/bcache/alloc_types.h)0
-rw-r--r--fs/bcachefs/bcache.h (renamed from drivers/md/bcache/bcache.h)4
-rw-r--r--fs/bcachefs/bkey.c (renamed from drivers/md/bcache/bkey.c)12
-rw-r--r--fs/bcachefs/bkey.h (renamed from drivers/md/bcache/bkey.h)2
-rw-r--r--fs/bcachefs/bkey_methods.c (renamed from drivers/md/bcache/bkey_methods.c)0
-rw-r--r--fs/bcachefs/bkey_methods.h (renamed from drivers/md/bcache/bkey_methods.h)0
-rw-r--r--fs/bcachefs/blockdev.c (renamed from drivers/md/bcache/blockdev.c)0
-rw-r--r--fs/bcachefs/blockdev.h (renamed from drivers/md/bcache/blockdev.h)0
-rw-r--r--fs/bcachefs/blockdev_types.h (renamed from drivers/md/bcache/blockdev_types.h)0
-rw-r--r--fs/bcachefs/bset.c (renamed from drivers/md/bcache/bset.c)6
-rw-r--r--fs/bcachefs/bset.h (renamed from drivers/md/bcache/bset.h)6
-rw-r--r--fs/bcachefs/btree_cache.c (renamed from drivers/md/bcache/btree_cache.c)4
-rw-r--r--fs/bcachefs/btree_cache.h (renamed from drivers/md/bcache/btree_cache.h)0
-rw-r--r--fs/bcachefs/btree_gc.c (renamed from drivers/md/bcache/btree_gc.c)0
-rw-r--r--fs/bcachefs/btree_gc.h (renamed from drivers/md/bcache/btree_gc.h)0
-rw-r--r--fs/bcachefs/btree_io.c (renamed from drivers/md/bcache/btree_io.c)0
-rw-r--r--fs/bcachefs/btree_io.h (renamed from drivers/md/bcache/btree_io.h)0
-rw-r--r--fs/bcachefs/btree_iter.c (renamed from drivers/md/bcache/btree_iter.c)4
-rw-r--r--fs/bcachefs/btree_iter.h (renamed from drivers/md/bcache/btree_iter.h)2
-rw-r--r--fs/bcachefs/btree_locking.h (renamed from drivers/md/bcache/btree_locking.h)0
-rw-r--r--fs/bcachefs/btree_types.h (renamed from drivers/md/bcache/btree_types.h)0
-rw-r--r--fs/bcachefs/btree_update.c (renamed from drivers/md/bcache/btree_update.c)2
-rw-r--r--fs/bcachefs/btree_update.h (renamed from drivers/md/bcache/btree_update.h)0
-rw-r--r--fs/bcachefs/buckets.c (renamed from drivers/md/bcache/buckets.c)0
-rw-r--r--fs/bcachefs/buckets.h (renamed from drivers/md/bcache/buckets.h)0
-rw-r--r--fs/bcachefs/buckets_types.h (renamed from drivers/md/bcache/buckets_types.h)0
-rw-r--r--fs/bcachefs/chardev.c (renamed from drivers/md/bcache/chardev.c)0
-rw-r--r--fs/bcachefs/checksum.c (renamed from drivers/md/bcache/checksum.c)0
-rw-r--r--fs/bcachefs/checksum.h (renamed from drivers/md/bcache/checksum.h)0
-rw-r--r--fs/bcachefs/clock.c (renamed from drivers/md/bcache/clock.c)0
-rw-r--r--fs/bcachefs/clock.h (renamed from drivers/md/bcache/clock.h)0
-rw-r--r--fs/bcachefs/clock_types.h (renamed from drivers/md/bcache/clock_types.h)0
-rw-r--r--fs/bcachefs/closure.c (renamed from drivers/md/bcache/closure.c)0
-rw-r--r--fs/bcachefs/closure.h (renamed from drivers/md/bcache/closure.h)0
-rw-r--r--fs/bcachefs/debug.c (renamed from drivers/md/bcache/debug.c)2
-rw-r--r--fs/bcachefs/debug.h (renamed from drivers/md/bcache/debug.h)2
-rw-r--r--fs/bcachefs/dirent.c (renamed from drivers/md/bcache/dirent.c)0
-rw-r--r--fs/bcachefs/dirent.h (renamed from drivers/md/bcache/dirent.h)0
-rw-r--r--fs/bcachefs/error.c (renamed from drivers/md/bcache/error.c)0
-rw-r--r--fs/bcachefs/error.h (renamed from drivers/md/bcache/error.h)0
-rw-r--r--fs/bcachefs/extents.c (renamed from drivers/md/bcache/extents.c)0
-rw-r--r--fs/bcachefs/extents.h (renamed from drivers/md/bcache/extents.h)0
-rw-r--r--fs/bcachefs/fifo.h (renamed from drivers/md/bcache/fifo.h)0
-rw-r--r--fs/bcachefs/fs-gc.c (renamed from drivers/md/bcache/fs-gc.c)0
-rw-r--r--fs/bcachefs/fs-gc.h (renamed from drivers/md/bcache/fs-gc.h)0
-rw-r--r--fs/bcachefs/fs-io.c (renamed from drivers/md/bcache/fs-io.c)4
-rw-r--r--fs/bcachefs/fs-io.h (renamed from drivers/md/bcache/fs-io.h)0
-rw-r--r--fs/bcachefs/fs.c (renamed from drivers/md/bcache/fs.c)0
-rw-r--r--fs/bcachefs/fs.h (renamed from drivers/md/bcache/fs.h)0
-rw-r--r--fs/bcachefs/inode.c (renamed from drivers/md/bcache/inode.c)0
-rw-r--r--fs/bcachefs/inode.h (renamed from drivers/md/bcache/inode.h)0
-rw-r--r--fs/bcachefs/io.c (renamed from drivers/md/bcache/io.c)0
-rw-r--r--fs/bcachefs/io.h (renamed from drivers/md/bcache/io.h)0
-rw-r--r--fs/bcachefs/io_types.h (renamed from drivers/md/bcache/io_types.h)0
-rw-r--r--fs/bcachefs/journal.c (renamed from drivers/md/bcache/journal.c)0
-rw-r--r--fs/bcachefs/journal.h (renamed from drivers/md/bcache/journal.h)0
-rw-r--r--fs/bcachefs/journal_types.h (renamed from drivers/md/bcache/journal_types.h)0
-rw-r--r--fs/bcachefs/keybuf.c (renamed from drivers/md/bcache/keybuf.c)0
-rw-r--r--fs/bcachefs/keybuf.h (renamed from drivers/md/bcache/keybuf.h)0
-rw-r--r--fs/bcachefs/keybuf_types.h (renamed from drivers/md/bcache/keybuf_types.h)0
-rw-r--r--fs/bcachefs/keylist.c (renamed from drivers/md/bcache/keylist.c)0
-rw-r--r--fs/bcachefs/keylist.h (renamed from drivers/md/bcache/keylist.h)0
-rw-r--r--fs/bcachefs/keylist_types.h (renamed from drivers/md/bcache/keylist_types.h)0
-rw-r--r--fs/bcachefs/migrate.c (renamed from drivers/md/bcache/migrate.c)0
-rw-r--r--fs/bcachefs/migrate.h (renamed from drivers/md/bcache/migrate.h)0
-rw-r--r--fs/bcachefs/move.c (renamed from drivers/md/bcache/move.c)0
-rw-r--r--fs/bcachefs/move.h (renamed from drivers/md/bcache/move.h)0
-rw-r--r--fs/bcachefs/move_types.h (renamed from drivers/md/bcache/move_types.h)0
-rw-r--r--fs/bcachefs/movinggc.c (renamed from drivers/md/bcache/movinggc.c)0
-rw-r--r--fs/bcachefs/movinggc.h (renamed from drivers/md/bcache/movinggc.h)0
-rw-r--r--fs/bcachefs/notify.c (renamed from drivers/md/bcache/notify.c)0
-rw-r--r--fs/bcachefs/notify.h (renamed from drivers/md/bcache/notify.h)0
-rw-r--r--fs/bcachefs/opts.c (renamed from drivers/md/bcache/opts.c)0
-rw-r--r--fs/bcachefs/opts.h (renamed from drivers/md/bcache/opts.h)0
-rw-r--r--fs/bcachefs/request.c (renamed from drivers/md/bcache/request.c)0
-rw-r--r--fs/bcachefs/request.h (renamed from drivers/md/bcache/request.h)0
-rw-r--r--fs/bcachefs/siphash.c (renamed from drivers/md/bcache/siphash.c)0
-rw-r--r--fs/bcachefs/siphash.h (renamed from drivers/md/bcache/siphash.h)0
-rw-r--r--fs/bcachefs/six.c (renamed from drivers/md/bcache/six.c)0
-rw-r--r--fs/bcachefs/six.h (renamed from drivers/md/bcache/six.h)0
-rw-r--r--fs/bcachefs/stats.c (renamed from drivers/md/bcache/stats.c)0
-rw-r--r--fs/bcachefs/stats.h (renamed from drivers/md/bcache/stats.h)0
-rw-r--r--fs/bcachefs/stats_types.h (renamed from drivers/md/bcache/stats_types.h)0
-rw-r--r--fs/bcachefs/str_hash.h (renamed from drivers/md/bcache/str_hash.h)0
-rw-r--r--fs/bcachefs/super.c (renamed from drivers/md/bcache/super.c)0
-rw-r--r--fs/bcachefs/super.h (renamed from drivers/md/bcache/super.h)0
-rw-r--r--fs/bcachefs/super_types.h (renamed from drivers/md/bcache/super_types.h)0
-rw-r--r--fs/bcachefs/sysfs.c (renamed from drivers/md/bcache/sysfs.c)2
-rw-r--r--fs/bcachefs/sysfs.h (renamed from drivers/md/bcache/sysfs.h)0
-rw-r--r--fs/bcachefs/tier.c (renamed from drivers/md/bcache/tier.c)0
-rw-r--r--fs/bcachefs/tier.h (renamed from drivers/md/bcache/tier.h)0
-rw-r--r--fs/bcachefs/trace.c (renamed from drivers/md/bcache/trace.c)0
-rw-r--r--fs/bcachefs/util.c (renamed from drivers/md/bcache/util.c)0
-rw-r--r--fs/bcachefs/util.h (renamed from drivers/md/bcache/util.h)2
-rw-r--r--fs/bcachefs/writeback.c (renamed from drivers/md/bcache/writeback.c)2
-rw-r--r--fs/bcachefs/writeback.h (renamed from drivers/md/bcache/writeback.h)0
-rw-r--r--fs/bcachefs/xattr.c (renamed from drivers/md/bcache/xattr.c)0
-rw-r--r--fs/bcachefs/xattr.h (renamed from drivers/md/bcache/xattr.h)0
104 files changed, 30 insertions, 28 deletions
diff --git a/drivers/md/bcache/Kconfig b/fs/bcachefs/Kconfig
index 0f698426fc74..0f698426fc74 100644
--- a/drivers/md/bcache/Kconfig
+++ b/fs/bcachefs/Kconfig
diff --git a/drivers/md/bcache/Makefile b/fs/bcachefs/Makefile
index 390c167819c4..390c167819c4 100644
--- a/drivers/md/bcache/Makefile
+++ b/fs/bcachefs/Makefile
diff --git a/drivers/md/bcache/acl.c b/fs/bcachefs/acl.c
index aaec01208042..aaec01208042 100644
--- a/drivers/md/bcache/acl.c
+++ b/fs/bcachefs/acl.c
diff --git a/drivers/md/bcache/acl.h b/fs/bcachefs/acl.h
index 079e568908e4..079e568908e4 100644
--- a/drivers/md/bcache/acl.h
+++ b/fs/bcachefs/acl.h
diff --git a/drivers/md/bcache/alloc.c b/fs/bcachefs/alloc.c
index 3cba2762a8be..b4975df07a99 100644
--- a/drivers/md/bcache/alloc.c
+++ b/fs/bcachefs/alloc.c
@@ -1241,7 +1241,7 @@ static void open_bucket_copy_unused_ptrs(struct cache_set *c,
static void verify_not_stale(struct cache_set *c, const struct open_bucket *ob)
{
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
const struct bch_extent_ptr *ptr;
struct cache *ca;
diff --git a/drivers/md/bcache/alloc.h b/fs/bcachefs/alloc.h
index 7dbbb23ff67a..7dbbb23ff67a 100644
--- a/drivers/md/bcache/alloc.h
+++ b/fs/bcachefs/alloc.h
diff --git a/drivers/md/bcache/alloc_types.h b/fs/bcachefs/alloc_types.h
index 065b9c02f185..065b9c02f185 100644
--- a/drivers/md/bcache/alloc_types.h
+++ b/fs/bcachefs/alloc_types.h
diff --git a/drivers/md/bcache/bcache.h b/fs/bcachefs/bcache.h
index 137c0d7a2e50..83ee086b60fe 100644
--- a/drivers/md/bcache/bcache.h
+++ b/fs/bcachefs/bcache.h
@@ -250,7 +250,7 @@
#define BCH_DEBUG_PARAMS_ALL() BCH_DEBUG_PARAMS_ALWAYS() BCH_DEBUG_PARAMS_DEBUG()
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
#define BCH_DEBUG_PARAMS() BCH_DEBUG_PARAMS_ALL()
#else
#define BCH_DEBUG_PARAMS() BCH_DEBUG_PARAMS_ALWAYS()
@@ -753,7 +753,7 @@ struct cache_set {
/* DEBUG JUNK */
struct dentry *debug;
struct btree_debug btree_debug[BTREE_ID_NR];
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
struct btree *verify_data;
struct btree_node *verify_ondisk;
struct mutex verify_lock;
diff --git a/drivers/md/bcache/bkey.c b/fs/bcachefs/bkey.c
index c20ab1caa746..db38f262652b 100644
--- a/drivers/md/bcache/bkey.c
+++ b/fs/bcachefs/bkey.c
@@ -9,7 +9,7 @@
const struct bkey_format bch_bkey_format_current = BKEY_FORMAT_CURRENT;
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
static void to_binary(char *out, const void *p, unsigned nr_bytes)
{
@@ -224,7 +224,7 @@ static bool bch_bkey_transform_key(const struct bkey_format *out_f,
if (!set_inc_field(&out_s, i, get_inc_field(&in_s, i)))
return false;
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
{
struct bkey u = bkey_unpack_key(in_f, in);
BUG_ON(bkey_start_offset(&u) < out_f->field_offset[BKEY_FIELD_OFFSET]);
@@ -447,7 +447,7 @@ static bool set_inc_field_lossy(struct pack_state *state, unsigned field, u64 v)
return ret;
}
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
static bool bkey_packed_successor(struct bkey_packed *out,
const struct bkey_format *format,
struct bkey_packed k)
@@ -502,7 +502,7 @@ enum bkey_pack_pos_ret bkey_pack_pos_lossy(struct bkey_packed *out,
const struct bkey_format *format)
{
struct pack_state state = pack_state_init(format, out);
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
struct bpos orig = in;
#endif
bool exact = true;
@@ -545,7 +545,7 @@ enum bkey_pack_pos_ret bkey_pack_pos_lossy(struct bkey_packed *out,
out->format = KEY_FORMAT_LOCAL_BTREE;
out->type = KEY_TYPE_DELETED;
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
if (exact) {
BUG_ON(bkey_cmp_left_packed(format, out, orig));
} else {
@@ -862,7 +862,7 @@ void bch_bkey_swab_key(const struct bkey_format *_f, struct bkey_packed *k)
}
}
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
void bkey_pack_test(void)
{
struct bkey t = KEY(4134ULL, 1250629070527416633ULL, 0);
diff --git a/drivers/md/bcache/bkey.h b/fs/bcachefs/bkey.h
index 1e68822e13bd..f18a8017bc60 100644
--- a/drivers/md/bcache/bkey.h
+++ b/fs/bcachefs/bkey.h
@@ -527,7 +527,7 @@ BKEY_VAL_ACCESSORS(xattr, BCH_XATTR);
#define next_word(p) nth_word(p, 1)
#define prev_word(p) nth_word(p, -1)
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
void bkey_pack_test(void);
#else
static inline void bkey_pack_test(void) {}
diff --git a/drivers/md/bcache/bkey_methods.c b/fs/bcachefs/bkey_methods.c
index 47db7a2ba04a..47db7a2ba04a 100644
--- a/drivers/md/bcache/bkey_methods.c
+++ b/fs/bcachefs/bkey_methods.c
diff --git a/drivers/md/bcache/bkey_methods.h b/fs/bcachefs/bkey_methods.h
index 03ca92e28a29..03ca92e28a29 100644
--- a/drivers/md/bcache/bkey_methods.h
+++ b/fs/bcachefs/bkey_methods.h
diff --git a/drivers/md/bcache/blockdev.c b/fs/bcachefs/blockdev.c
index 81fc5c8dd360..81fc5c8dd360 100644
--- a/drivers/md/bcache/blockdev.c
+++ b/fs/bcachefs/blockdev.c
diff --git a/drivers/md/bcache/blockdev.h b/fs/bcachefs/blockdev.h
index 0fc0ed1b80c4..0fc0ed1b80c4 100644
--- a/drivers/md/bcache/blockdev.h
+++ b/fs/bcachefs/blockdev.h
diff --git a/drivers/md/bcache/blockdev_types.h b/fs/bcachefs/blockdev_types.h
index 67dd4dec868b..67dd4dec868b 100644
--- a/drivers/md/bcache/blockdev_types.h
+++ b/fs/bcachefs/blockdev_types.h
diff --git a/drivers/md/bcache/bset.c b/fs/bcachefs/bset.c
index 35488f873410..22dbdf91057b 100644
--- a/drivers/md/bcache/bset.c
+++ b/fs/bcachefs/bset.c
@@ -48,7 +48,7 @@ struct bset_tree *bch_bkey_to_bset(struct btree_keys *b, struct bkey_packed *k)
* by the time we actually do the insert will all be deleted.
*/
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
static bool keys_out_of_order(const struct bkey_format *f,
const struct bkey_packed *prev,
@@ -386,7 +386,7 @@ void bch_btree_keys_init(struct btree_keys *b, const struct btree_keys_ops *ops,
b->ops = ops;
b->nsets = 0;
memset(&b->nr, 0, sizeof(b->nr));
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
b->expensive_debug_checks = expensive_debug_checks;
#endif
for (i = 0; i < MAX_BSETS; i++) {
@@ -1233,7 +1233,7 @@ static struct bkey_packed *bch_bset_search(struct btree_keys *b,
!btree_iter_pos_cmp_packed(f, search, m, strictly_greater))
m = bkey_next(m);
- if (IS_ENABLED(CONFIG_BCACHE_DEBUG)) {
+ if (IS_ENABLED(CONFIG_BCACHEFS_DEBUG)) {
struct bkey_packed *prev = bkey_prev(t, m);
BUG_ON(prev &&
diff --git a/drivers/md/bcache/bset.h b/fs/bcachefs/bset.h
index ed7dc48d5b04..8ee47e828aa8 100644
--- a/drivers/md/bcache/bset.h
+++ b/fs/bcachefs/bset.h
@@ -265,7 +265,7 @@ struct btree_keys {
* set[0]->data points to the entire btree node as it exists on disk.
*/
struct bset_tree set[MAX_BSETS];
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
bool *expensive_debug_checks;
#endif
};
@@ -274,7 +274,7 @@ extern bool bch_expensive_debug_checks;
static inline bool btree_keys_expensive_checks(struct btree_keys *b)
{
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
return bch_expensive_debug_checks || *b->expensive_debug_checks;
#else
return false;
@@ -599,7 +599,7 @@ void bch_btree_keys_stats(struct btree_keys *, struct bset_stats *);
/* Debug stuff */
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
void bch_dump_bset(struct btree_keys *, struct bset *, unsigned);
void bch_dump_bucket(struct btree_keys *);
diff --git a/drivers/md/bcache/btree_cache.c b/fs/bcachefs/btree_cache.c
index 2cda8776e903..569a72a111c0 100644
--- a/drivers/md/bcache/btree_cache.c
+++ b/fs/bcachefs/btree_cache.c
@@ -333,7 +333,7 @@ void bch_btree_cache_free(struct cache_set *c)
mutex_lock(&c->btree_cache_lock);
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
if (c->verify_data)
list_move(&c->verify_data->list, &c->btree_cache);
@@ -391,7 +391,7 @@ int bch_btree_cache_alloc(struct cache_set *c)
list_splice_init(&c->btree_cache,
&c->btree_cache_freeable);
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
mutex_init(&c->verify_lock);
c->verify_ondisk = (void *)
diff --git a/drivers/md/bcache/btree_cache.h b/fs/bcachefs/btree_cache.h
index e3950bf4cfb3..e3950bf4cfb3 100644
--- a/drivers/md/bcache/btree_cache.h
+++ b/fs/bcachefs/btree_cache.h
diff --git a/drivers/md/bcache/btree_gc.c b/fs/bcachefs/btree_gc.c
index 486c47372458..486c47372458 100644
--- a/drivers/md/bcache/btree_gc.c
+++ b/fs/bcachefs/btree_gc.c
diff --git a/drivers/md/bcache/btree_gc.h b/fs/bcachefs/btree_gc.h
index 99c6ccdef2b1..99c6ccdef2b1 100644
--- a/drivers/md/bcache/btree_gc.h
+++ b/fs/bcachefs/btree_gc.h
diff --git a/drivers/md/bcache/btree_io.c b/fs/bcachefs/btree_io.c
index a12b5684b63a..a12b5684b63a 100644
--- a/drivers/md/bcache/btree_io.c
+++ b/fs/bcachefs/btree_io.c
diff --git a/drivers/md/bcache/btree_io.h b/fs/bcachefs/btree_io.h
index 6e22f47ff605..6e22f47ff605 100644
--- a/drivers/md/bcache/btree_io.h
+++ b/fs/bcachefs/btree_io.h
diff --git a/drivers/md/bcache/btree_iter.c b/fs/bcachefs/btree_iter.c
index ccd39883048f..f8c146057282 100644
--- a/drivers/md/bcache/btree_iter.c
+++ b/fs/bcachefs/btree_iter.c
@@ -190,7 +190,7 @@ bool btree_node_relock(struct btree_iter *iter, unsigned level)
/* Btree iterator: */
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
static void __bch_btree_iter_verify(struct btree_node_iter *iter,
struct btree *b,
@@ -492,7 +492,7 @@ void bch_btree_iter_reinit_node(struct btree_iter *iter, struct btree *b)
static void btree_iter_verify_locking(struct btree_iter *iter, unsigned level)
{
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
struct btree_iter *linked;
if (!btree_want_intent(iter, level))
diff --git a/drivers/md/bcache/btree_iter.h b/fs/bcachefs/btree_iter.h
index c021a2633d2f..c42855471503 100644
--- a/drivers/md/bcache/btree_iter.h
+++ b/fs/bcachefs/btree_iter.h
@@ -114,7 +114,7 @@ __next_linked_btree_node(struct btree_iter *iter, struct btree *b,
for ((_linked) = (_iter); \
((_linked) = __next_linked_btree_node(_iter, _b, _linked));)
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
void bch_btree_iter_verify(struct btree_iter *, struct btree *);
#else
static inline void bch_btree_iter_verify(struct btree_iter *iter,
diff --git a/drivers/md/bcache/btree_locking.h b/fs/bcachefs/btree_locking.h
index fb6ce606eea4..fb6ce606eea4 100644
--- a/drivers/md/bcache/btree_locking.h
+++ b/fs/bcachefs/btree_locking.h
diff --git a/drivers/md/bcache/btree_types.h b/fs/bcachefs/btree_types.h
index f294aa2965c9..f294aa2965c9 100644
--- a/drivers/md/bcache/btree_types.h
+++ b/fs/bcachefs/btree_types.h
diff --git a/drivers/md/bcache/btree_update.c b/fs/bcachefs/btree_update.c
index 297af41ff3aa..9b5b048e4339 100644
--- a/drivers/md/bcache/btree_update.c
+++ b/fs/bcachefs/btree_update.c
@@ -742,7 +742,7 @@ void bch_btree_journal_key(struct btree_iter *iter,
static void verify_keys_sorted(struct keylist *l)
{
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
struct bkey_i *k;
for (k = l->bot;
diff --git a/drivers/md/bcache/btree_update.h b/fs/bcachefs/btree_update.h
index 55b74b61c04b..55b74b61c04b 100644
--- a/drivers/md/bcache/btree_update.h
+++ b/fs/bcachefs/btree_update.h
diff --git a/drivers/md/bcache/buckets.c b/fs/bcachefs/buckets.c
index 35336afd0ab2..35336afd0ab2 100644
--- a/drivers/md/bcache/buckets.c
+++ b/fs/bcachefs/buckets.c
diff --git a/drivers/md/bcache/buckets.h b/fs/bcachefs/buckets.h
index c96a398ca7bc..c96a398ca7bc 100644
--- a/drivers/md/bcache/buckets.h
+++ b/fs/bcachefs/buckets.h
diff --git a/drivers/md/bcache/buckets_types.h b/fs/bcachefs/buckets_types.h
index 256f6fe7f272..256f6fe7f272 100644
--- a/drivers/md/bcache/buckets_types.h
+++ b/fs/bcachefs/buckets_types.h
diff --git a/drivers/md/bcache/chardev.c b/fs/bcachefs/chardev.c
index f1874211e94b..f1874211e94b 100644
--- a/drivers/md/bcache/chardev.c
+++ b/fs/bcachefs/chardev.c
diff --git a/drivers/md/bcache/checksum.c b/fs/bcachefs/checksum.c
index beae0b26e570..beae0b26e570 100644
--- a/drivers/md/bcache/checksum.c
+++ b/fs/bcachefs/checksum.c
diff --git a/drivers/md/bcache/checksum.h b/fs/bcachefs/checksum.h
index 169a24a527a8..169a24a527a8 100644
--- a/drivers/md/bcache/checksum.h
+++ b/fs/bcachefs/checksum.h
diff --git a/drivers/md/bcache/clock.c b/fs/bcachefs/clock.c
index 8218769f4f8c..8218769f4f8c 100644
--- a/drivers/md/bcache/clock.c
+++ b/fs/bcachefs/clock.c
diff --git a/drivers/md/bcache/clock.h b/fs/bcachefs/clock.h
index f59f0716f611..f59f0716f611 100644
--- a/drivers/md/bcache/clock.h
+++ b/fs/bcachefs/clock.h
diff --git a/drivers/md/bcache/clock_types.h b/fs/bcachefs/clock_types.h
index 346466a9f987..346466a9f987 100644
--- a/drivers/md/bcache/clock_types.h
+++ b/fs/bcachefs/clock_types.h
diff --git a/drivers/md/bcache/closure.c b/fs/bcachefs/closure.c
index 5705cc328499..5705cc328499 100644
--- a/drivers/md/bcache/closure.c
+++ b/fs/bcachefs/closure.c
diff --git a/drivers/md/bcache/closure.h b/fs/bcachefs/closure.h
index 5fae4d4f4ee4..5fae4d4f4ee4 100644
--- a/drivers/md/bcache/closure.h
+++ b/fs/bcachefs/closure.h
diff --git a/drivers/md/bcache/debug.c b/fs/bcachefs/debug.c
index 224286b99973..d88396c6ebe9 100644
--- a/drivers/md/bcache/debug.c
+++ b/fs/bcachefs/debug.c
@@ -27,7 +27,7 @@
static struct dentry *bch_debug;
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
static void btree_verify_endio(struct bio *bio)
{
diff --git a/drivers/md/bcache/debug.h b/fs/bcachefs/debug.h
index c8f3ae64bd7d..109eab115471 100644
--- a/drivers/md/bcache/debug.h
+++ b/fs/bcachefs/debug.h
@@ -18,7 +18,7 @@ BCH_DEBUG_PARAMS()
BCH_DEBUG_PARAMS_ALWAYS()
#undef BCH_DEBUG_PARAM
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
#define BCH_DEBUG_PARAM(name, description) \
static inline bool name(struct cache_set *c) \
diff --git a/drivers/md/bcache/dirent.c b/fs/bcachefs/dirent.c
index b81c64683d07..b81c64683d07 100644
--- a/drivers/md/bcache/dirent.c
+++ b/fs/bcachefs/dirent.c
diff --git a/drivers/md/bcache/dirent.h b/fs/bcachefs/dirent.h
index 63b4aa07f432..63b4aa07f432 100644
--- a/drivers/md/bcache/dirent.h
+++ b/fs/bcachefs/dirent.h
diff --git a/drivers/md/bcache/error.c b/fs/bcachefs/error.c
index 00f797a340e6..00f797a340e6 100644
--- a/drivers/md/bcache/error.c
+++ b/fs/bcachefs/error.c
diff --git a/drivers/md/bcache/error.h b/fs/bcachefs/error.h
index ef93eebc8f1f..ef93eebc8f1f 100644
--- a/drivers/md/bcache/error.h
+++ b/fs/bcachefs/error.h
diff --git a/drivers/md/bcache/extents.c b/fs/bcachefs/extents.c
index 8310b8cb898a..8310b8cb898a 100644
--- a/drivers/md/bcache/extents.c
+++ b/fs/bcachefs/extents.c
diff --git a/drivers/md/bcache/extents.h b/fs/bcachefs/extents.h
index 5d97828dbd5c..5d97828dbd5c 100644
--- a/drivers/md/bcache/extents.h
+++ b/fs/bcachefs/extents.h
diff --git a/drivers/md/bcache/fifo.h b/fs/bcachefs/fifo.h
index 32a17c92b698..32a17c92b698 100644
--- a/drivers/md/bcache/fifo.h
+++ b/fs/bcachefs/fifo.h
diff --git a/drivers/md/bcache/fs-gc.c b/fs/bcachefs/fs-gc.c
index 6ec3e1c37a5b..6ec3e1c37a5b 100644
--- a/drivers/md/bcache/fs-gc.c
+++ b/fs/bcachefs/fs-gc.c
diff --git a/drivers/md/bcache/fs-gc.h b/fs/bcachefs/fs-gc.h
index 04f08978af3a..04f08978af3a 100644
--- a/drivers/md/bcache/fs-gc.h
+++ b/fs/bcachefs/fs-gc.h
diff --git a/drivers/md/bcache/fs-io.c b/fs/bcachefs/fs-io.c
index b0079b2e6740..4761d011c5cd 100644
--- a/drivers/md/bcache/fs-io.c
+++ b/fs/bcachefs/fs-io.c
@@ -175,7 +175,7 @@ static int __must_check i_sectors_dirty_get(struct bch_inode_info *ei,
h->hook.fn = i_sectors_hook_fn;
h->sectors = 0;
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
h->ei = ei;
#endif
@@ -886,6 +886,8 @@ static int __bch_writepage(struct page *page, struct writeback_control *wbc,
loff_t i_size = i_size_read(inode);
pgoff_t end_index = i_size >> PAGE_SHIFT;
+ /* throttle based on ra_pages */
+
EBUG_ON(!PageUptodate(page));
/* Is the page fully inside i_size? */
diff --git a/drivers/md/bcache/fs-io.h b/fs/bcachefs/fs-io.h
index 3cf76b2f9d8f..3cf76b2f9d8f 100644
--- a/drivers/md/bcache/fs-io.h
+++ b/fs/bcachefs/fs-io.h
diff --git a/drivers/md/bcache/fs.c b/fs/bcachefs/fs.c
index 2493f5ff9884..2493f5ff9884 100644
--- a/drivers/md/bcache/fs.c
+++ b/fs/bcachefs/fs.c
diff --git a/drivers/md/bcache/fs.h b/fs/bcachefs/fs.h
index e8f627c6ba45..e8f627c6ba45 100644
--- a/drivers/md/bcache/fs.h
+++ b/fs/bcachefs/fs.h
diff --git a/drivers/md/bcache/inode.c b/fs/bcachefs/inode.c
index dff8c0923590..dff8c0923590 100644
--- a/drivers/md/bcache/inode.c
+++ b/fs/bcachefs/inode.c
diff --git a/drivers/md/bcache/inode.h b/fs/bcachefs/inode.h
index e5a36ca24bb0..e5a36ca24bb0 100644
--- a/drivers/md/bcache/inode.h
+++ b/fs/bcachefs/inode.h
diff --git a/drivers/md/bcache/io.c b/fs/bcachefs/io.c
index cd3dbe76ceca..cd3dbe76ceca 100644
--- a/drivers/md/bcache/io.c
+++ b/fs/bcachefs/io.c
diff --git a/drivers/md/bcache/io.h b/fs/bcachefs/io.h
index b37d9845b17e..b37d9845b17e 100644
--- a/drivers/md/bcache/io.h
+++ b/fs/bcachefs/io.h
diff --git a/drivers/md/bcache/io_types.h b/fs/bcachefs/io_types.h
index 50856c6ce207..50856c6ce207 100644
--- a/drivers/md/bcache/io_types.h
+++ b/fs/bcachefs/io_types.h
diff --git a/drivers/md/bcache/journal.c b/fs/bcachefs/journal.c
index 30e1eb13dc77..30e1eb13dc77 100644
--- a/drivers/md/bcache/journal.c
+++ b/fs/bcachefs/journal.c
diff --git a/drivers/md/bcache/journal.h b/fs/bcachefs/journal.h
index 0813e8d7d12b..0813e8d7d12b 100644
--- a/drivers/md/bcache/journal.h
+++ b/fs/bcachefs/journal.h
diff --git a/drivers/md/bcache/journal_types.h b/fs/bcachefs/journal_types.h
index 5c3ec3cb08d0..5c3ec3cb08d0 100644
--- a/drivers/md/bcache/journal_types.h
+++ b/fs/bcachefs/journal_types.h
diff --git a/drivers/md/bcache/keybuf.c b/fs/bcachefs/keybuf.c
index a3c6b03e1093..a3c6b03e1093 100644
--- a/drivers/md/bcache/keybuf.c
+++ b/fs/bcachefs/keybuf.c
diff --git a/drivers/md/bcache/keybuf.h b/fs/bcachefs/keybuf.h
index d6fdda9d633c..d6fdda9d633c 100644
--- a/drivers/md/bcache/keybuf.h
+++ b/fs/bcachefs/keybuf.h
diff --git a/drivers/md/bcache/keybuf_types.h b/fs/bcachefs/keybuf_types.h
index 3facc4a07526..3facc4a07526 100644
--- a/drivers/md/bcache/keybuf_types.h
+++ b/fs/bcachefs/keybuf_types.h
diff --git a/drivers/md/bcache/keylist.c b/fs/bcachefs/keylist.c
index 638596300575..638596300575 100644
--- a/drivers/md/bcache/keylist.c
+++ b/fs/bcachefs/keylist.c
diff --git a/drivers/md/bcache/keylist.h b/fs/bcachefs/keylist.h
index 028552757527..028552757527 100644
--- a/drivers/md/bcache/keylist.h
+++ b/fs/bcachefs/keylist.h
diff --git a/drivers/md/bcache/keylist_types.h b/fs/bcachefs/keylist_types.h
index 569cdc2480e2..569cdc2480e2 100644
--- a/drivers/md/bcache/keylist_types.h
+++ b/fs/bcachefs/keylist_types.h
diff --git a/drivers/md/bcache/migrate.c b/fs/bcachefs/migrate.c
index c33606865eb2..c33606865eb2 100644
--- a/drivers/md/bcache/migrate.c
+++ b/fs/bcachefs/migrate.c
diff --git a/drivers/md/bcache/migrate.h b/fs/bcachefs/migrate.h
index 55636e00f105..55636e00f105 100644
--- a/drivers/md/bcache/migrate.h
+++ b/fs/bcachefs/migrate.h
diff --git a/drivers/md/bcache/move.c b/fs/bcachefs/move.c
index bbfcbdae2f37..bbfcbdae2f37 100644
--- a/drivers/md/bcache/move.c
+++ b/fs/bcachefs/move.c
diff --git a/drivers/md/bcache/move.h b/fs/bcachefs/move.h
index 2f9998e66e7f..2f9998e66e7f 100644
--- a/drivers/md/bcache/move.h
+++ b/fs/bcachefs/move.h
diff --git a/drivers/md/bcache/move_types.h b/fs/bcachefs/move_types.h
index d5e1a4a968fa..d5e1a4a968fa 100644
--- a/drivers/md/bcache/move_types.h
+++ b/fs/bcachefs/move_types.h
diff --git a/drivers/md/bcache/movinggc.c b/fs/bcachefs/movinggc.c
index 22f6fb8dd212..22f6fb8dd212 100644
--- a/drivers/md/bcache/movinggc.c
+++ b/fs/bcachefs/movinggc.c
diff --git a/drivers/md/bcache/movinggc.h b/fs/bcachefs/movinggc.h
index 5d09e0fa3ae1..5d09e0fa3ae1 100644
--- a/drivers/md/bcache/movinggc.h
+++ b/fs/bcachefs/movinggc.h
diff --git a/drivers/md/bcache/notify.c b/fs/bcachefs/notify.c
index e9b5568c95e3..e9b5568c95e3 100644
--- a/drivers/md/bcache/notify.c
+++ b/fs/bcachefs/notify.c
diff --git a/drivers/md/bcache/notify.h b/fs/bcachefs/notify.h
index 80d658768764..80d658768764 100644
--- a/drivers/md/bcache/notify.h
+++ b/fs/bcachefs/notify.h
diff --git a/drivers/md/bcache/opts.c b/fs/bcachefs/opts.c
index 249dd5d91a98..249dd5d91a98 100644
--- a/drivers/md/bcache/opts.c
+++ b/fs/bcachefs/opts.c
diff --git a/drivers/md/bcache/opts.h b/fs/bcachefs/opts.h
index bd490aa91b79..bd490aa91b79 100644
--- a/drivers/md/bcache/opts.h
+++ b/fs/bcachefs/opts.h
diff --git a/drivers/md/bcache/request.c b/fs/bcachefs/request.c
index 67c8d3f3d145..67c8d3f3d145 100644
--- a/drivers/md/bcache/request.c
+++ b/fs/bcachefs/request.c
diff --git a/drivers/md/bcache/request.h b/fs/bcachefs/request.h
index cd3fe1225045..cd3fe1225045 100644
--- a/drivers/md/bcache/request.h
+++ b/fs/bcachefs/request.h
diff --git a/drivers/md/bcache/siphash.c b/fs/bcachefs/siphash.c
index 0c6f7f3ec819..0c6f7f3ec819 100644
--- a/drivers/md/bcache/siphash.c
+++ b/fs/bcachefs/siphash.c
diff --git a/drivers/md/bcache/siphash.h b/fs/bcachefs/siphash.h
index 7a4b2241f1e1..7a4b2241f1e1 100644
--- a/drivers/md/bcache/siphash.h
+++ b/fs/bcachefs/siphash.h
diff --git a/drivers/md/bcache/six.c b/fs/bcachefs/six.c
index 172d45c7f20c..172d45c7f20c 100644
--- a/drivers/md/bcache/six.c
+++ b/fs/bcachefs/six.c
diff --git a/drivers/md/bcache/six.h b/fs/bcachefs/six.h
index da8ec5332f4a..da8ec5332f4a 100644
--- a/drivers/md/bcache/six.h
+++ b/fs/bcachefs/six.h
diff --git a/drivers/md/bcache/stats.c b/fs/bcachefs/stats.c
index a8a4eb3692c4..a8a4eb3692c4 100644
--- a/drivers/md/bcache/stats.c
+++ b/fs/bcachefs/stats.c
diff --git a/drivers/md/bcache/stats.h b/fs/bcachefs/stats.h
index 39877f9aa132..39877f9aa132 100644
--- a/drivers/md/bcache/stats.h
+++ b/fs/bcachefs/stats.h
diff --git a/drivers/md/bcache/stats_types.h b/fs/bcachefs/stats_types.h
index 28e4c69e8e6d..28e4c69e8e6d 100644
--- a/drivers/md/bcache/stats_types.h
+++ b/fs/bcachefs/stats_types.h
diff --git a/drivers/md/bcache/str_hash.h b/fs/bcachefs/str_hash.h
index 375a3f7a2ded..375a3f7a2ded 100644
--- a/drivers/md/bcache/str_hash.h
+++ b/fs/bcachefs/str_hash.h
diff --git a/drivers/md/bcache/super.c b/fs/bcachefs/super.c
index 27d984c1d37a..27d984c1d37a 100644
--- a/drivers/md/bcache/super.c
+++ b/fs/bcachefs/super.c
diff --git a/drivers/md/bcache/super.h b/fs/bcachefs/super.h
index 24f9b0ead9c8..24f9b0ead9c8 100644
--- a/drivers/md/bcache/super.h
+++ b/fs/bcachefs/super.h
diff --git a/drivers/md/bcache/super_types.h b/fs/bcachefs/super_types.h
index d89f780f544f..d89f780f544f 100644
--- a/drivers/md/bcache/super_types.h
+++ b/fs/bcachefs/super_types.h
diff --git a/drivers/md/bcache/sysfs.c b/fs/bcachefs/sysfs.c
index 1652c09b7fb6..4df9c72486a7 100644
--- a/drivers/md/bcache/sysfs.c
+++ b/fs/bcachefs/sysfs.c
@@ -377,7 +377,7 @@ static struct attribute *bch_cached_dev_files[] = {
&sysfs_state,
&sysfs_label,
&sysfs_readahead,
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
&sysfs_verify,
&sysfs_bypass_torture_test,
#endif
diff --git a/drivers/md/bcache/sysfs.h b/fs/bcachefs/sysfs.h
index 9d5845874931..9d5845874931 100644
--- a/drivers/md/bcache/sysfs.h
+++ b/fs/bcachefs/sysfs.h
diff --git a/drivers/md/bcache/tier.c b/fs/bcachefs/tier.c
index caf6b3df2c9c..caf6b3df2c9c 100644
--- a/drivers/md/bcache/tier.c
+++ b/fs/bcachefs/tier.c
diff --git a/drivers/md/bcache/tier.h b/fs/bcachefs/tier.h
index 57b4acf86fb5..57b4acf86fb5 100644
--- a/drivers/md/bcache/tier.h
+++ b/fs/bcachefs/tier.h
diff --git a/drivers/md/bcache/trace.c b/fs/bcachefs/trace.c
index def525d19dcb..def525d19dcb 100644
--- a/drivers/md/bcache/trace.c
+++ b/fs/bcachefs/trace.c
diff --git a/drivers/md/bcache/util.c b/fs/bcachefs/util.c
index 9a0d89d6223c..9a0d89d6223c 100644
--- a/drivers/md/bcache/util.c
+++ b/fs/bcachefs/util.c
diff --git a/drivers/md/bcache/util.h b/fs/bcachefs/util.h
index c79b55fc08ed..97eea8892572 100644
--- a/drivers/md/bcache/util.h
+++ b/fs/bcachefs/util.h
@@ -18,7 +18,7 @@
struct closure;
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
#define EBUG_ON(cond) BUG_ON(cond)
#define atomic_dec_bug(v) BUG_ON(atomic_dec_return(v) < 0)
diff --git a/drivers/md/bcache/writeback.c b/fs/bcachefs/writeback.c
index 3db1f0827ca3..846533cd527b 100644
--- a/drivers/md/bcache/writeback.c
+++ b/fs/bcachefs/writeback.c
@@ -584,7 +584,7 @@ int bch_cached_dev_writeback_init(struct cached_dev *dc)
sectors = get_capacity(dc->disk.disk);
if (!d->stripe_size) {
-#ifdef CONFIG_BCACHE_DEBUG
+#ifdef CONFIG_BCACHEFS_DEBUG
d->stripe_size = 1 << 0;
#else
d->stripe_size = 1 << 31;
diff --git a/drivers/md/bcache/writeback.h b/fs/bcachefs/writeback.h
index a71a2bfe1b87..a71a2bfe1b87 100644
--- a/drivers/md/bcache/writeback.h
+++ b/fs/bcachefs/writeback.h
diff --git a/drivers/md/bcache/xattr.c b/fs/bcachefs/xattr.c
index bfaf2875e229..bfaf2875e229 100644
--- a/drivers/md/bcache/xattr.c
+++ b/fs/bcachefs/xattr.c
diff --git a/drivers/md/bcache/xattr.h b/fs/bcachefs/xattr.h
index 675529d328d0..675529d328d0 100644
--- a/drivers/md/bcache/xattr.h
+++ b/fs/bcachefs/xattr.h