mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Szymon Wilczek <swilczek.lx@gmail.com>
Cc: ocfs2-devel@lists.linux.dev, mark@fasheh.com, jlbec@evilplan.org,
	joseph.qi@linux.alibaba.com, linux-kernel@vger.kernel.org,
	syzkaller-bugs@googlegroups.com,
	syzbot+51244a05705883616c95@syzkaller.appspotmail.com
Subject: Re: [PATCH] ocfs2: fix circular locking dependency in ocfs2_acquire_dquot
Date: Mon, 5 Jan 2026 17:37:11 -0800	[thread overview]
Message-ID: <20260105173711.b33d85c7f72544876c8dcfd3@linux-foundation.org> (raw)
In-Reply-To: <20251227174251.121668-1-swilczek.lx@gmail.com>

On Sat, 27 Dec 2025 18:42:51 +0100 Szymon Wilczek <swilczek.lx@gmail.com> wrote:

> Move ocfs2_extend_no_holes() to execute before ocfs2_lock_global_qf() to
> fix a circular locking dependency reported by syzbot.
> 
> The issue occurs because ocfs2_extend_no_holes() internally calls
> ocfs2_extend_allocation() which starts a transaction (acquiring
> sb_start_intwrite). When called while holding the global quota file
> lock, this conflicts with mount-time operations that acquire
> sb_internal first, creating the following circular dependency:
> 
>   sb_internal -> ocfs2_sysfile_lock_key -> ocfs2_quota_ip_alloc_sem_key
> 
> By moving the quota file extension before acquiring the global quota
> file lock, we ensure that any internal transactions complete before
> quota locks are held, breaking the circular dependency.

Thanks.  This might have escaped reviewer attention due to the holiday
season.  I'll add it to mm.git's mm-nonmm-unstable branch for runtime
testing while we await review (please!).

  reply	other threads:[~2026-01-06  1:37 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-27 17:42 Szymon Wilczek
2026-01-06  1:37 ` Andrew Morton [this message]
2026-01-08  8:43 ` Joseph Qi
2026-01-08 14:15   ` Szymon Wilczek
2026-01-09  1:07     ` Joseph Qi
2026-01-09  2:02       ` Szymon Wilczek
2026-01-20  1:37         ` Joseph Qi
2026-01-20 23:16           ` Szymon Wilczek
2026-01-08 14:19 ` [PATCH v2] " Szymon Wilczek

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=20260105173711.b33d85c7f72544876c8dcfd3@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=jlbec@evilplan.org \
    --cc=joseph.qi@linux.alibaba.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark@fasheh.com \
    --cc=ocfs2-devel@lists.linux.dev \
    --cc=swilczek.lx@gmail.com \
    --cc=syzbot+51244a05705883616c95@syzkaller.appspotmail.com \
    --cc=syzkaller-bugs@googlegroups.com \
    /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

all inboxes | Powered by JetHome®