From: "Jörn Engel" <joern@barelysecure.org>
To: Miquel Raynal <miquel.raynal@bootlin.com>
Cc: Chris Roy <iam@thechris.in>, Richard Weinberger <richard@nod.at>,
Greg KH <gregkh@linuxfoundation.org>,
syzbot <syzbot+7cab6a19619f1b8efc00@syzkaller.appspotmail.com>,
dakr@kernel.org, driver-core@lists.linux.dev,
linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
rafael@kernel.org, syzkaller-bugs@googlegroups.com,
linux-mtd@lists.infradead.org, vigneshr@ti.com,
Adarsh Das <adarshdas950@gmail.com>
Subject: Re: [syzbot] [fs?] possible deadlock in ovl_create_object (2)
Date: Sun, 20 Sep 2026 09:19:55 -0700 [thread overview]
Message-ID: <arAHq0imD-Gm_bOc@cashel.logfs.org> (raw)
In-Reply-To: <87cxu8axvh.fsf@bootlin.com>
Hello Miquèl
On Sun, Sep 20, 2026 at 02:52:18PM +0200, Miquel Raynal wrote:
>
> Not saying this would be a bad move, it would be highly inconsistent
> with the current code base. Every single allocation in the kernel is
> checked. Such a change, without a documented and agreed upon method,
> would lead to dozens fuzzing AIs sending patches to add the "missing"
> check.
If your argument is that such a change would be inappropriate for the
patch in question, I totally agree with you.
I would disagree with an argument of "we should do the wrong thing for
the sake of consistency". If indeed it is the wrong thing, we should
stop doing it. Then we can regain consistency by not doing the wrong
thing anywhere. In other words, consistency is irrelevant. The only
question should be whether such a change is right or wrong.
There is also the practical consideration that changing the kmalloc
interface will lead to thousands of changes throughout the kernel and
requires a large time commitment from someone. If nobody volunteers to
be that someone, it might still be better to stick with the status quo
for now.
So making an entirely theoretical "if I were king for a day" kind of
argument, I don't think GFP_KERNEL allocations should have to check for
failure. Neither should userspace callers to malloc. An interface that
frequently returns errors is pretty safe, as callers with broken error
handling are quickly detected and fixes. An interface that almost never
returns errors is dangerous, as broken error handling in callers becomes
common and will eventually lead to bizarre hard-to-reproduce failures.
One of my roles in my last job was to fix userspace malloc and one of my
fixes was to ensure it would never return an allocation failure. If it
returned, the caller received what it requested. If that wasn't
possible, the process would crash. A crashing process isn't exactly
desired, but it beats unpredictable behavior triggered by broken error
handlers. And dealing with a single error path costs significantly less
cognitive effort than dealing with thousands of error handlers
everywhere in the code base.
Anyway, since I am not volunteering to spend a significant chunk of my
time, this is just the opinion of someone that doesn't matter. Feel
free to reject it.
Jörn
--
Why do musicians compose symphonies and poets write poems?
They do it because life wouldn't have any meaning for them if they didn't.
That's why I draw cartoons. It's my life.
-- Charles Shultz
next prev parent reply other threads:[~2026-09-20 16:20 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-09 15:19 syzbot
2026-09-12 13:12 ` syzbot
2026-09-16 19:48 ` Chris Roy
2026-09-16 21:37 ` Chris Roy
2026-09-16 21:52 ` syzbot
2026-09-17 6:44 ` Chris Roy
2026-09-17 6:59 ` syzbot
2026-09-17 7:33 ` Greg KH
2026-09-17 7:58 ` Chris Roy
2026-09-17 8:13 ` syzbot
2026-09-17 18:15 ` Jörn Engel
2026-09-19 7:42 ` AW: " Richard Weinberger
2026-09-19 8:52 ` Chris Roy
2026-09-19 9:07 ` syzbot
2026-09-19 14:45 ` Jörn Engel
2026-09-19 15:28 ` Chris Roy
2026-09-19 15:38 ` Jörn Engel
2026-09-20 12:52 ` Miquel Raynal
2026-09-20 16:19 ` Jörn Engel [this message]
2026-09-20 18:34 ` Chris Roy
2026-09-19 14:21 ` AW: " Jörn Engel
2026-09-19 14:28 ` Richard Weinberger
2026-09-19 14:44 ` Chris Roy
2026-09-20 21:09 ` AW: " Richard Weinberger
2026-09-20 21:13 ` Chris Roy
2026-09-20 18:51 ` [PATCH v4] mtd: block2mtd: defer device open out of param/sysfs write Chris Roy
2026-09-20 19:03 ` sashiko-bot
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=arAHq0imD-Gm_bOc@cashel.logfs.org \
--to=joern@barelysecure.org \
--cc=adarshdas950@gmail.com \
--cc=dakr@kernel.org \
--cc=driver-core@lists.linux.dev \
--cc=gregkh@linuxfoundation.org \
--cc=iam@thechris.in \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=miquel.raynal@bootlin.com \
--cc=rafael@kernel.org \
--cc=richard@nod.at \
--cc=syzbot+7cab6a19619f1b8efc00@syzkaller.appspotmail.com \
--cc=syzkaller-bugs@googlegroups.com \
--cc=vigneshr@ti.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®