summaryrefslogtreecommitdiff
path: root/libbcachefs/move.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2018-01-11 06:41:59 -0500
committerKent Overstreet <kent.overstreet@gmail.com>2018-01-11 07:02:08 -0500
commit4de98a2712764bceb9e0f67b1ac2f2c7862feb77 (patch)
tree94861af51e19af917d80952dfabeaa7a76901eaa /libbcachefs/move.h
parentf8cbede6d18e81c804e62fd7d576310b420dcaac (diff)
Update bcachefs sources to 02ae70070a bcachefs: Allocate new btree roots lazily
Diffstat (limited to 'libbcachefs/move.h')
-rw-r--r--libbcachefs/move.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/libbcachefs/move.h b/libbcachefs/move.h
index 2e884ce0..24d6ddfa 100644
--- a/libbcachefs/move.h
+++ b/libbcachefs/move.h
@@ -1,6 +1,7 @@
#ifndef _BCACHEFS_MOVE_H
#define _BCACHEFS_MOVE_H
+#include "btree_iter.h"
#include "buckets.h"
#include "io_types.h"
@@ -25,10 +26,19 @@ void bch2_migrate_write_init(struct migrate_write *, struct bch_read_bio *);
typedef bool (*move_pred_fn)(void *, struct bkey_s_c_extent);
+struct bch_move_stats {
+ struct btree_iter iter;
+
+ atomic64_t keys_moved;
+ atomic64_t sectors_moved;
+ atomic64_t sectors_seen;
+ atomic64_t sectors_raced;
+};
+
int bch2_move_data(struct bch_fs *, struct bch_ratelimit *,
unsigned, struct bch_devs_mask *,
struct write_point_specifier,
int, int, move_pred_fn, void *,
- u64 *, u64 *);
+ struct bch_move_stats *);
#endif /* _BCACHEFS_MOVE_H */