mirror of
https://github.com/torvalds/linux.git
synced 2026-06-01 11:03:43 +02:00
bcachefs: add missing locking in bch2_write_point_to_text()
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
177ac4925f
commit
7ad7497862
|
|
@ -1517,6 +1517,8 @@ static void bch2_write_point_to_text(struct printbuf *out, struct bch_fs *c,
|
|||
struct open_bucket *ob;
|
||||
unsigned i;
|
||||
|
||||
mutex_lock(&wp->lock);
|
||||
|
||||
prt_printf(out, "%lu: ", wp->write_point);
|
||||
prt_human_readable_u64(out, wp->sectors_allocated << 9);
|
||||
|
||||
|
|
@ -1534,6 +1536,8 @@ static void bch2_write_point_to_text(struct printbuf *out, struct bch_fs *c,
|
|||
open_bucket_for_each(c, &wp->ptrs, ob, i)
|
||||
bch2_open_bucket_to_text(out, c, ob);
|
||||
printbuf_indent_sub(out, 2);
|
||||
|
||||
mutex_unlock(&wp->lock);
|
||||
}
|
||||
|
||||
void bch2_write_points_to_text(struct printbuf *out, struct bch_fs *c)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user