diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2024-05-07 03:49:24 +0300 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2024-05-07 18:02:36 +0300 |
commit | 54541c1f78e12a78487ae63e2e199a7d4f6dbd26 (patch) | |
tree | 735f198e33988225c60f206014d4860df540644f /scripts/gdb/linux/utils.py | |
parent | 71dac2482ad3c8d4a8b8998a96751f009bad895f (diff) | |
download | linux-54541c1f78e12a78487ae63e2e199a7d4f6dbd26.tar.xz |
bcachefs: Fix race in bch2_write_super()
bch2_write_super() was looping over online devices multiple times -
dropping and retaking io_ref each time.
This meant it could race with device removal; it could increment the
sequence number on a device but fail to write it - and then if the
device was re-added, it would get confused the next time around thinking
a superblock write was silently dropped.
Fix this by taking io_ref once, and stashing pointers to online devices
in a darray.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions