[0/5] Extent buffer locking and documentation
mbox series

Message ID cover.1571340084.git.dsterba@suse.com
Headers show
  • Extent buffer locking and documentation
Related show


David Sterba Oct. 17, 2019, 7:38 p.m. UTC
I've spent a lot of time staring at the locking code and speculating
about all sorts of weird problems that could happen due to memory
ordering or lost wakeups or if the custom locking is safe at all, also
regarding the recent changes.

Inevitably I found something but also wrote documentation. Please read
it and if you see need for more clarifications, I'm happy to add it as
I'm now in a state that things become temporarily obvious and trivial.

I've tested it in fstests with KCSAN (the new concurrency sanitizer), no
problems found but this is not considered sufficient, more tests will

David Sterba (5):
  btrfs: merge blocking_writers branches in btrfs_tree_read_lock
  btrfs: set blocking_writers directly, no increment or decrement
  btrfs: access eb::blocking_writers according to ACCESS_ONCE policies
  btrfs: serialize blocking_writers updates
  btrfs: document extent buffer locking

 fs/btrfs/locking.c | 184 +++++++++++++++++++++++++++++++++++----------
 1 file changed, 144 insertions(+), 40 deletions(-)