Skip to content

Commit 1f85f39

Browse files
committed
gfs2: Simplify function gfs2_upgrade_iopen_glock
jira LE-2169 Rebuild_History Non-Buildable kernel-4.18.0-553.27.1.el8_10 commit-author Andreas Gruenbacher <agruenba@redhat.com> commit 18c1db3 When trying to upgrade the iopen glock, gfs2_upgrade_iopen_glock() tries to take the iopen glock with the LM_FLAG_TRY_1CB flag set before trying to take it without the LM_FLAG_TRY or LM_FLAG_TRY_1CB flags set. Both calls will cause the lock contention bast callbacks to be invoked throughout the cluster, and we really don't need them to be invoked twice. Remove the first LM_FLAG_TRY_1CB call to eliminate unnecessary dlm traffic. Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com> (cherry picked from commit 18c1db3) Signed-off-by: Jonathan Maple <jmaple@ciq.com>
1 parent 7fc12c0 commit 1f85f39

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

fs/gfs2/super.c

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1315,18 +1315,8 @@ static bool gfs2_upgrade_iopen_glock(struct inode *inode)
13151315
* As a last resort, if another node keeps holding the iopen glock
13161316
* without showing any activity on the inode glock, we will eventually
13171317
* time out and fail the iopen glock upgrade.
1318-
*
1319-
* Note that we're passing the LM_FLAG_TRY_1CB flag to the first
1320-
* locking request as an optimization to notify lock holders as soon as
1321-
* possible. Without that flag, they'd be notified implicitly by the
1322-
* second locking request.
13231318
*/
13241319

1325-
gfs2_holder_reinit(LM_ST_EXCLUSIVE, LM_FLAG_TRY_1CB | GL_NOCACHE, gh);
1326-
error = gfs2_glock_nq(gh);
1327-
if (error != GLR_TRYFAILED)
1328-
return !error;
1329-
13301320
gfs2_holder_reinit(LM_ST_EXCLUSIVE, GL_ASYNC | GL_NOCACHE, gh);
13311321
error = gfs2_glock_nq(gh);
13321322
if (error)

0 commit comments

Comments
 (0)