diff options
| author | Kent Overstreet <[email protected]> | 2024-08-11 01:04:35 +0000 |
|---|---|---|
| committer | Kent Overstreet <[email protected]> | 2024-08-14 02:56:50 +0000 |
| commit | b2f11c6f3e1fc60742673b8675c95b78447f3dae (patch) | |
| tree | 60d2b5a8e31c6b660d9da0985eac6a686c3d5358 /fs/bcachefs/btree_trans_commit.c | |
| parent | bcachefs: Convert for_each_btree_node() to lockrestart_do() (diff) | |
| download | kernel-b2f11c6f3e1fc60742673b8675c95b78447f3dae.tar.gz kernel-b2f11c6f3e1fc60742673b8675c95b78447f3dae.zip | |
lib/generic-radix-tree.c: Fix rare race in __genradix_ptr_alloc()
If we need to increase the tree depth, allocate a new node, and then
race with another thread that increased the tree depth before us, we'll
still have a preallocated node that might be used later.
If we then use that node for a new non-root node, it'll still have a
pointer to the old root instead of being zeroed - fix this by zeroing it
in the cmpxchg failure path.
Signed-off-by: Kent Overstreet <[email protected]>
Diffstat (limited to 'fs/bcachefs/btree_trans_commit.c')
0 files changed, 0 insertions, 0 deletions
