]> git.baikalelectronics.ru Git - kernel.git/commit
GFS2: Allow glocks to be unlocked after withdraw
authorBob Peterson <rpeterso@redhat.com>
Fri, 5 May 2017 14:43:02 +0000 (09:43 -0500)
committerBob Peterson <rpeterso@redhat.com>
Fri, 5 May 2017 19:19:28 +0000 (14:19 -0500)
commitc39e7a1514f0378755d9b0d2c6075756f6dd9a86
treee3617232b60c723a084e087cb9d431a7247f48be
parent945a65f0b6ad6a1b879f872c5fbb4ba422c18059
GFS2: Allow glocks to be unlocked after withdraw

This bug fixes a regression introduced by patch 733479a925.

The intent of the patch was to stop promoting glocks after a
file system is withdrawn due to a variety of errors, because doing
so results in a BUG(). (You should be able to unmount after a
withdraw rather than having the kernel panic.)

Unfortunately, it also stopped demotions, so glocks could not be
unlocked after withdraw, which means the unmount would hang.

This patch allows function do_xmote to demote locks to an
unlocked state after a withdraw, but not promote them.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
fs/gfs2/glock.c