mirror of
https://github.com/koverstreet/bcachefs-tools.git
synced 2025-02-23 00:00:02 +03:00
Fix performance regression of update_inode
This kernel commit: 65bd442397274347e721a89c2c4882a392bae982 removes BTREE_ITER_cached from bch2_btree_insert_trans, which causes the update_inode function to take a long time (~20s). Add this flag back in the update_inode function. Signed-off-by: Ariel Miculas <ariel.miculas@gmail.com> Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
d750b2b98b
commit
ed675b8d64
@ -19,7 +19,7 @@ void update_inode(struct bch_fs *c,
|
|||||||
bch2_inode_pack(&packed, inode);
|
bch2_inode_pack(&packed, inode);
|
||||||
packed.inode.k.p.snapshot = U32_MAX;
|
packed.inode.k.p.snapshot = U32_MAX;
|
||||||
ret = bch2_btree_insert(c, BTREE_ID_inodes, &packed.inode.k_i,
|
ret = bch2_btree_insert(c, BTREE_ID_inodes, &packed.inode.k_i,
|
||||||
NULL, 0, 0);
|
NULL, 0, BTREE_ITER_cached);
|
||||||
if (ret)
|
if (ret)
|
||||||
die("error updating inode: %s", bch2_err_str(ret));
|
die("error updating inode: %s", bch2_err_str(ret));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user