]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
bcachefs: Pop all the transactions from the abort one
authorAlan Huang <mmpgouride@gmail.com>
Wed, 2 Oct 2024 19:06:33 +0000 (03:06 +0800)
committerKent Overstreet <kent.overstreet@linux.dev>
Tue, 14 Jan 2025 15:45:25 +0000 (10:45 -0500)
The transaction is going to abort, so there will be no cycle involving
this transaction anymore.

Signed-off-by: Alan Huang <mmpgouride@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/btree_locking.c

index 15ef9f71ca436fab43da04e99fe5b7820f85dfc9..10b805a60f5269289a3a4e89abee39b36ea1c29d 100644 (file)
@@ -242,6 +242,8 @@ static noinline int break_cycle(struct lock_graph *g, struct printbuf *cycle,
 out:
        if (ret)
                lock_graph_pop_all(g);
+       else
+               lock_graph_pop_from(g, abort);
        return ret;
 }