summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--fs/bcachefs/data_update.c4
-rw-r--r--fs/bcachefs/ec.c28
-rw-r--r--fs/bcachefs/ec.h6
-rw-r--r--fs/bcachefs/io.c4
4 files changed, 0 insertions, 42 deletions
diff --git a/fs/bcachefs/data_update.c b/fs/bcachefs/data_update.c
index 1d7ed3ac236c..32c79e1fd3e7 100644
--- a/fs/bcachefs/data_update.c
+++ b/fs/bcachefs/data_update.c
@@ -104,7 +104,6 @@ int bch2_data_update_index_update(struct bch_write_op *op)
struct btree_iter iter;
struct data_update *m =
container_of(op, struct data_update, op);
- struct open_bucket *ec_ob = ec_open_bucket(c, &op->open_buckets);
struct keylist *keys = &op->insert_keys;
struct bkey_buf _new, _insert;
int ret = 0;
@@ -243,9 +242,6 @@ int bch2_data_update_index_update(struct bch_write_op *op)
if (!ret) {
bch2_btree_iter_set_pos(&iter, next_pos);
- if (ec_ob)
- bch2_ob_add_backpointer(c, ec_ob, &insert->k);
-
this_cpu_add(c->counters[BCH_COUNTER_move_extent_finish], new->k.size);
trace_move_extent_finish(&new->k);
}
diff --git a/fs/bcachefs/ec.c b/fs/bcachefs/ec.c
index 1defde778deb..808e61523d9a 100644
--- a/fs/bcachefs/ec.c
+++ b/fs/bcachefs/ec.c
@@ -1017,8 +1017,6 @@ err:
}
}
- bch2_keylist_free(&s->keys, s->inline_keys);
-
ec_stripe_buf_exit(&s->existing_stripe);
ec_stripe_buf_exit(&s->new_stripe);
closure_debug_destroy(&s->iodone);
@@ -1101,30 +1099,6 @@ void *bch2_writepoint_ec_buf(struct bch_fs *c, struct write_point *wp)
return ob->ec->new_stripe.data[ob->ec_idx] + (offset << 9);
}
-void bch2_ob_add_backpointer(struct bch_fs *c, struct open_bucket *ob,
- struct bkey *k)
-{
- struct ec_stripe_new *ec = ob->ec;
-
- if (!ec)
- return;
-
- mutex_lock(&ec->lock);
-
- if (bch2_keylist_realloc(&ec->keys, ec->inline_keys,
- ARRAY_SIZE(ec->inline_keys),
- BKEY_U64s)) {
- BUG();
- }
-
- bkey_init(&ec->keys.top->k);
- ec->keys.top->k.p = k->p;
- ec->keys.top->k.size = k->size;
- bch2_keylist_push(&ec->keys);
-
- mutex_unlock(&ec->lock);
-}
-
static int unsigned_cmp(const void *_l, const void *_r)
{
unsigned l = *((const unsigned *) _l);
@@ -1217,8 +1191,6 @@ static int ec_new_stripe_alloc(struct bch_fs *c, struct ec_stripe_head *h)
BCH_BKEY_PTRS_MAX) - h->redundancy;
s->nr_parity = h->redundancy;
- bch2_keylist_init(&s->keys, s->inline_keys);
-
ec_stripe_key_init(c, &s->new_stripe.key, s->nr_data,
s->nr_parity, h->blocksize);
diff --git a/fs/bcachefs/ec.h b/fs/bcachefs/ec.h
index 8596fa763b4c..54ad8b0a648c 100644
--- a/fs/bcachefs/ec.h
+++ b/fs/bcachefs/ec.h
@@ -5,7 +5,6 @@
#include "ec_types.h"
#include "buckets_types.h"
#include "extents_types.h"
-#include "keylist_types.h"
int bch2_stripe_invalid(const struct bch_fs *, struct bkey_s_c,
int rw, struct printbuf *);
@@ -167,9 +166,6 @@ struct ec_stripe_new {
open_bucket_idx_t blocks[BCH_BKEY_PTRS_MAX];
struct disk_reservation res;
- struct keylist keys;
- u64 inline_keys[BKEY_U64s * 8];
-
struct ec_stripe_buf new_stripe;
struct ec_stripe_buf existing_stripe;
};
@@ -197,8 +193,6 @@ struct ec_stripe_head {
int bch2_ec_read_extent(struct bch_fs *, struct bch_read_bio *);
void *bch2_writepoint_ec_buf(struct bch_fs *, struct write_point *);
-void bch2_ob_add_backpointer(struct bch_fs *, struct open_bucket *,
- struct bkey *);
void bch2_ec_bucket_written(struct bch_fs *, struct open_bucket *);
void bch2_ec_bucket_cancel(struct bch_fs *, struct open_bucket *);
diff --git a/fs/bcachefs/io.c b/fs/bcachefs/io.c
index acdf9fbf18b9..be78ba22dd73 100644
--- a/fs/bcachefs/io.c
+++ b/fs/bcachefs/io.c
@@ -472,7 +472,6 @@ static int bch2_write_index_default(struct bch_write_op *op)
{
struct bch_fs *c = op->c;
struct bkey_buf sk;
- struct open_bucket *ec_ob = ec_open_bucket(c, &op->open_buckets);
struct keylist *keys = &op->insert_keys;
struct bkey_i *k = bch2_keylist_front(keys);
struct btree_trans trans;
@@ -516,9 +515,6 @@ static int bch2_write_index_default(struct bch_write_op *op)
if (ret)
break;
- if (ec_ob)
- bch2_ob_add_backpointer(c, ec_ob, &sk.k->k);
-
if (bkey_ge(iter.pos, k->k.p))
bch2_keylist_pop_front(&op->insert_keys);
else