summaryrefslogtreecommitdiff
path: root/libbcachefs/alloc_foreground.c
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2019-02-28 21:34:16 -0500
committerKent Overstreet <kent.overstreet@gmail.com>2019-02-28 22:33:41 -0500
commita4eb187a6f0af8041ae2128e6ee82ab7a43cb87c (patch)
tree9560a9fc7b481ee827ee00ae48a77eca69b398a7 /libbcachefs/alloc_foreground.c
parent17c5215c1c542dd7b6b4f891a0da16d8c98e0591 (diff)
Update bcachefs sources to 75e8a078b8 bcachefs: improved flush_held_btree_writes()
Diffstat (limited to 'libbcachefs/alloc_foreground.c')
-rw-r--r--libbcachefs/alloc_foreground.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libbcachefs/alloc_foreground.c b/libbcachefs/alloc_foreground.c
index f2f9015d..6568e8ac 100644
--- a/libbcachefs/alloc_foreground.c
+++ b/libbcachefs/alloc_foreground.c
@@ -723,7 +723,7 @@ static struct write_point *__writepoint_find(struct hlist_head *head,
static inline bool too_many_writepoints(struct bch_fs *c, unsigned factor)
{
u64 stranded = c->write_points_nr * c->bucket_size_max;
- u64 free = bch2_fs_sectors_free(c);
+ u64 free = bch2_fs_usage_read_short(c).free;
return stranded * factor > free;
}