diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-06-16 21:56:42 +0200 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 23:10:02 +0200 |
commit | 32913f49f54f0cf9ccf581e3abd2d1fc6ba4debf (patch) | |
tree | af06267093004fd58dc0e639842e0fb4575d5614 /fs/bcachefs/six.c | |
parent | six locks: Split out seq, use atomic_t instead of atomic64_t (diff) | |
download | linux-32913f49f54f0cf9ccf581e3abd2d1fc6ba4debf.tar.xz linux-32913f49f54f0cf9ccf581e3abd2d1fc6ba4debf.zip |
six locks: Seq now only incremented on unlock
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to '')
-rw-r--r-- | fs/bcachefs/six.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/fs/bcachefs/six.c b/fs/bcachefs/six.c index 54e4aa35a350..8ce0998b9775 100644 --- a/fs/bcachefs/six.c +++ b/fs/bcachefs/six.c @@ -302,9 +302,6 @@ bool six_trylock_ip(struct six_lock *lock, enum six_lock_type type, unsigned lon if (type != SIX_LOCK_write) six_acquire(&lock->dep_map, 1, type == SIX_LOCK_read, ip); - else - lock->seq++; - return true; } EXPORT_SYMBOL_GPL(six_trylock_ip); @@ -596,8 +593,6 @@ int six_lock_ip_waiter(struct six_lock *lock, enum six_lock_type type, ret = do_six_trylock(lock, type, true) ? 0 : six_lock_slowpath(lock, type, wait, should_sleep_fn, p, ip); - lock->seq += !ret && type == SIX_LOCK_write; - if (ret && type != SIX_LOCK_write) six_release(&lock->dep_map, ip); if (!ret) |