diff options
author | 2022-12-11 21:25:39 +0100 | |
---|---|---|
committer | 2023-09-18 23:13:20 +0200 | |
commit | 18c1db313ea904ebd01aa08135b72cdb04f889fb (patch) | |
tree | c50fb7beb93ebed11b53d092a233cf7634958b64 /fs/gfs2 | |
parent | Merge tag 'gfs2-v6.6-rc1-fixes' of git://git.kernel.org/pub/scm/linux/kernel/... (diff) | |
download | linux-18c1db313ea904ebd01aa08135b72cdb04f889fb.tar.gz linux-18c1db313ea904ebd01aa08135b72cdb04f889fb.tar.bz2 linux-18c1db313ea904ebd01aa08135b72cdb04f889fb.zip |
gfs2: Simplify function gfs2_upgrade_iopen_glock
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>
Diffstat (limited to 'fs/gfs2')
-rw-r--r-- | fs/gfs2/super.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c index 02d93da21b2b..3141db77189e 100644 --- a/fs/gfs2/super.c +++ b/fs/gfs2/super.c @@ -1299,18 +1299,8 @@ static bool gfs2_upgrade_iopen_glock(struct inode *inode) * As a last resort, if another node keeps holding the iopen glock * without showing any activity on the inode glock, we will eventually * time out and fail the iopen glock upgrade. - * - * Note that we're passing the LM_FLAG_TRY_1CB flag to the first - * locking request as an optimization to notify lock holders as soon as - * possible. Without that flag, they'd be notified implicitly by the - * second locking request. */ - gfs2_holder_reinit(LM_ST_EXCLUSIVE, LM_FLAG_TRY_1CB | GL_NOCACHE, gh); - error = gfs2_glock_nq(gh); - if (error != GLR_TRYFAILED) - return !error; - gfs2_holder_reinit(LM_ST_EXCLUSIVE, GL_ASYNC | GL_NOCACHE, gh); error = gfs2_glock_nq(gh); if (error) |