]> git.baikalelectronics.ru Git - kernel.git/commit
gfs2: Wake up when sd_glock_disposal becomes zero
authorAlexander Aring <aahringo@redhat.com>
Mon, 26 Oct 2020 14:52:29 +0000 (10:52 -0400)
committerAndreas Gruenbacher <agruenba@redhat.com>
Tue, 3 Nov 2020 13:39:11 +0000 (14:39 +0100)
commit91a48c62aeca66fd58cb07cfa2df4cc1e5c534c9
treec9f4f8c199ef7335fff49ed0ca929040e945915c
parent9b11f673ff9013190ff73b5a94cf7ec42523c711
gfs2: Wake up when sd_glock_disposal becomes zero

Commit b67c68bec281 ("GFS2: Fix glock deallocation race") fixed a
sd_glock_disposal accounting bug by adding a missing atomic_dec
statement, but it failed to wake up sd_glock_wait when that decrement
causes sd_glock_disposal to reach zero.  As a consequence,
gfs2_gl_hash_clear can now run into a 10-minute timeout instead of
being woken up.  Add the missing wakeup.

Fixes: b67c68bec281 ("GFS2: Fix glock deallocation race")
Cc: stable@vger.kernel.org # v2.6.39+
Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
fs/gfs2/glock.c