summaryrefslogtreecommitdiff
path: root/fs/bcachefs/recovery.c
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2020-12-16 13:35:16 -0500
committerKent Overstreet <kent.overstreet@linux.dev>2023-10-22 17:08:44 -0400
commitaa8889c07abecd7db7b2c0beb61db921fbafe04f (patch)
treeed24fd86cf23c94c6319226b29283f5b1d9553fb /fs/bcachefs/recovery.c
parentf3721e12d07ab3c3e400a1a635e999ef72780de4 (diff)
downloadlwn-aa8889c07abecd7db7b2c0beb61db921fbafe04f.tar.gz
lwn-aa8889c07abecd7db7b2c0beb61db921fbafe04f.zip
bcachefs: Fix assertion popping in transaction commit path
We can't be holding read locks on btree nodes when we go to take write locks: this would deadlock if another thread is holding an intent lock on the node we have a read lock on, and it tries to commit and upgrade to a write lock. But instead of triggering an assertion, if this happens we can just upgrade the read lock to an intent lock. Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com> Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/recovery.c')
0 files changed, 0 insertions, 0 deletions