Linux kernel -stable discussions
 help / color / mirror / Atom feed
From: Alexander Aring <aahringo@redhat.com>
To: agruenba@redhat.com
Cc: stable@vger.kernel.org, gfs2@lists.linux.dev, aahringo@redhat.com
Subject: [PATCH gfs2/for-next] gfs2: use delay during spinlock area
Date: Mon, 31 Mar 2025 15:36:56 -0400	[thread overview]
Message-ID: <20250331193656.1134507-1-aahringo@redhat.com> (raw)

In a rare case of gfs2 spectator mount the ls->ls_recover_spin is being
held. In this case we cannot call msleep_interruptible() as we a in a
non-sleepable context. Replace it with mdelay() to busy wait for 1
second.

Cc: stable@vger.kernel.org
Fixes: 4a7727725dc7 ("GFS2: Fix recovery issues for spectators")
Signed-off-by: Alexander Aring <aahringo@redhat.com>
---
 fs/gfs2/lock_dlm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/gfs2/lock_dlm.c b/fs/gfs2/lock_dlm.c
index 58aeeae7ed8c..ac0afedff49b 100644
--- a/fs/gfs2/lock_dlm.c
+++ b/fs/gfs2/lock_dlm.c
@@ -996,7 +996,7 @@ static int control_mount(struct gfs2_sbd *sdp)
 		if (sdp->sd_args.ar_spectator) {
 			fs_info(sdp, "Recovery is required. Waiting for a "
 				"non-spectator to mount.\n");
-			msleep_interruptible(1000);
+			mdelay(1000);
 		} else {
 			fs_info(sdp, "control_mount wait1 block %u start %u "
 				"mount %u lvb %u flags %lx\n", block_gen,
-- 
2.43.0


             reply	other threads:[~2025-03-31 19:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-31 19:36 Alexander Aring [this message]
2025-03-31 21:31 ` [PATCH gfs2/for-next] gfs2: use delay during spinlock area David Laight
2025-03-31 22:47   ` Andreas Gruenbacher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250331193656.1134507-1-aahringo@redhat.com \
    --to=aahringo@redhat.com \
    --cc=agruenba@redhat.com \
    --cc=gfs2@lists.linux.dev \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox