diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2021-12-05 08:30:49 +0300 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-23 00:09:18 +0300 |
commit | 94a3e1a6c1bd441b58972ee0216593fc0b09ee75 (patch) | |
tree | c1c51180768769af2f00c7653122329c85b4f93c /fs/bcachefs/tests.c | |
parent | 1d81313f22205bfd844bd2e13e7e3ea5d50cd673 (diff) | |
download | linux-94a3e1a6c1bd441b58972ee0216593fc0b09ee75.tar.xz |
bcachefs: bch2_trans_update() is now __must_check
With snapshots, bch2_trans_update() has to check if we need a whitout,
which can cause a transaction restart, so this is important now.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Diffstat (limited to 'fs/bcachefs/tests.c')
-rw-r--r-- | fs/bcachefs/tests.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/bcachefs/tests.c b/fs/bcachefs/tests.c index 6023661ece16..145b85320d22 100644 --- a/fs/bcachefs/tests.c +++ b/fs/bcachefs/tests.c @@ -584,10 +584,10 @@ static int rand_mixed_trans(struct btree_trans *trans, if (!(i & 3) && k.k) { bkey_cookie_init(&cookie->k_i); cookie->k.p = iter->pos; - bch2_trans_update(trans, iter, &cookie->k_i, 0); + ret = bch2_trans_update(trans, iter, &cookie->k_i, 0); } - return 0; + return ret; } static int rand_mixed(struct bch_fs *c, u64 nr) |