mirror of
https://github.com/koverstreet/bcachefs-tools.git
synced 2025-02-23 00:00:02 +03:00
Update bcachefs sources to 0389c09b2fb7 bcachefs: Fix bio alloc in check_extent_checksum()
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
59e04ddf40
commit
0e0aa31912
@ -1 +1 @@
|
||||
10ca1f99f8c99a3d992b686cdc29d427807070e5
|
||||
0389c09b2fb702ca7924ddf550ce0c8af708b8be
|
||||
|
1
Makefile
1
Makefile
@ -254,6 +254,7 @@ update-bcachefs-sources:
|
||||
test -d libbcachefs || mkdir libbcachefs
|
||||
cp $(LINUX_DIR)/fs/bcachefs/*.[ch] libbcachefs/
|
||||
git add libbcachefs/*.[ch]
|
||||
git rm -f libbcachefs/mean_and_variance_test.c
|
||||
cp $(LINUX_DIR)/include/linux/closure.h include/linux/
|
||||
git add include/linux/closure.h
|
||||
cp $(LINUX_DIR)/lib/closure.c linux/
|
||||
|
@ -470,7 +470,7 @@ found:
|
||||
goto err;
|
||||
}
|
||||
|
||||
bio = bio_alloc(ca->disk_sb.bdev, 1, REQ_OP_READ, GFP_KERNEL);
|
||||
bio = bio_alloc(ca->disk_sb.bdev, buf_pages(data_buf, bytes), REQ_OP_READ, GFP_KERNEL);
|
||||
bio->bi_iter.bi_sector = p.ptr.offset;
|
||||
bch2_bio_map(bio, data_buf, bytes);
|
||||
ret = submit_bio_wait(bio);
|
||||
|
@ -1504,7 +1504,8 @@ enum btree_id_flags {
|
||||
BIT_ULL(KEY_TYPE_stripe)) \
|
||||
x(reflink, 7, BTREE_ID_EXTENTS|BTREE_ID_DATA, \
|
||||
BIT_ULL(KEY_TYPE_reflink_v)| \
|
||||
BIT_ULL(KEY_TYPE_indirect_inline_data)) \
|
||||
BIT_ULL(KEY_TYPE_indirect_inline_data)| \
|
||||
BIT_ULL(KEY_TYPE_error)) \
|
||||
x(subvolumes, 8, 0, \
|
||||
BIT_ULL(KEY_TYPE_subvolume)) \
|
||||
x(snapshots, 9, 0, \
|
||||
|
@ -1587,7 +1587,7 @@ static int bch2_gc_write_reflink_key(struct btree_trans *trans,
|
||||
struct bkey_i *new = bch2_bkey_make_mut_noupdate(trans, k);
|
||||
ret = PTR_ERR_OR_ZERO(new);
|
||||
if (ret)
|
||||
return ret;
|
||||
goto out;
|
||||
|
||||
if (!r->refcount)
|
||||
new->k.type = KEY_TYPE_deleted;
|
||||
@ -1595,6 +1595,7 @@ static int bch2_gc_write_reflink_key(struct btree_trans *trans,
|
||||
*bkey_refcount(bkey_i_to_s(new)) = cpu_to_le64(r->refcount);
|
||||
ret = bch2_trans_update(trans, iter, new, 0);
|
||||
}
|
||||
out:
|
||||
fsck_err:
|
||||
printbuf_exit(&buf);
|
||||
return ret;
|
||||
|
@ -463,8 +463,8 @@ static void __bch2_dev_btree_bitmap_mark(struct bch_sb_field_members_v2 *mi, uns
|
||||
m->btree_bitmap_shift += resize;
|
||||
}
|
||||
|
||||
for (unsigned bit = sectors >> m->btree_bitmap_shift;
|
||||
bit << m->btree_bitmap_shift < end;
|
||||
for (unsigned bit = start >> m->btree_bitmap_shift;
|
||||
(u64) bit << m->btree_bitmap_shift < end;
|
||||
bit++)
|
||||
bitmap |= BIT_ULL(bit);
|
||||
|
||||
|
@ -238,8 +238,8 @@ static inline bool bch2_dev_btree_bitmap_marked_sectors(struct bch_dev *ca, u64
|
||||
if (end > 64ULL << ca->mi.btree_bitmap_shift)
|
||||
return false;
|
||||
|
||||
for (unsigned bit = sectors >> ca->mi.btree_bitmap_shift;
|
||||
bit << ca->mi.btree_bitmap_shift < end;
|
||||
for (unsigned bit = start >> ca->mi.btree_bitmap_shift;
|
||||
(u64) bit << ca->mi.btree_bitmap_shift < end;
|
||||
bit++)
|
||||
if (!(ca->mi.btree_allocated_bitmap & BIT_ULL(bit)))
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user