[07/11] btrfs: dev-replace: remove pointless assert in write unlock
diff mbox series

Message ID 3fb761b6e09ab5a5d5d23ab146c0981b5519b2ec.1536331604.git.dsterba@suse.com
State New
Headers show
Series
  • Cleanup dev-replace locking
Related show

Commit Message

David Sterba Sept. 7, 2018, 2:55 p.m. UTC
The value of blocking_readers is increased only when the lock is taken
for read, no way we can fail the condition with the write lock.

Signed-off-by: David Sterba <dsterba@suse.com>
---
 fs/btrfs/dev-replace.c | 1 -
 1 file changed, 1 deletion(-)

Patch
diff mbox series

diff --git a/fs/btrfs/dev-replace.c b/fs/btrfs/dev-replace.c
index c0e9b2c229d5..ba1cbedaa422 100644
--- a/fs/btrfs/dev-replace.c
+++ b/fs/btrfs/dev-replace.c
@@ -977,7 +977,6 @@  void btrfs_dev_replace_write_lock(struct btrfs_dev_replace *dev_replace)
 
 void btrfs_dev_replace_write_unlock(struct btrfs_dev_replace *dev_replace)
 {
-	ASSERT(atomic_read(&dev_replace->blocking_readers) == 0);
 	write_unlock(&dev_replace->lock);
 }