diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-06-16 22:56:42 +0300 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-23 00:10:02 +0300 |
commit | 32913f49f54f0cf9ccf581e3abd2d1fc6ba4debf (patch) | |
tree | af06267093004fd58dc0e639842e0fb4575d5614 /fs/bcachefs/six.c | |
parent | 2804d0f15bda386fa86c7b6b432edb758e785bce (diff) | |
download | linux-32913f49f54f0cf9ccf581e3abd2d1fc6ba4debf.tar.xz |
six locks: Seq now only incremented on unlock
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/six.c')
-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) |