public inbox for [email protected]
 help / color / mirror / Atom feed
From: Linus Torvalds <[email protected]>
To: Jens Axboe <[email protected]>
Cc: io-uring <[email protected]>
Subject: Re: [GIT PULL] io_uring fix for 5.11 final
Date: Fri, 12 Feb 2021 12:29:14 -0800	[thread overview]
Message-ID: <CAHk-=wgK+8CbxbHKxcJop2sq634mZYUhMeNXLUN6fGnrrKeXbg@mail.gmail.com> (raw)
In-Reply-To: <[email protected]>

On Fri, Feb 12, 2021 at 12:22 PM Jens Axboe <[email protected]> wrote:
>
>   My other idea was
> to add a check in path resolution that catches it, for future safe
> guards outside of send/recvmsg. That's obviously a separate change
> from the comment, but would be nice to have.

I wonder how painful it would be to just make sure that kernel threads
have a NULL ->fs and ->files by default.

But maybe the oops in a kernel thread ends up being too painful and
harder to debug and deal with, and a special check is preferred just
because a WARN_ON_ONCE() wouldn't cause any other downstream issues.

Yes, some kernel threads do need to do pathname lookups (and io_uring
isn't the only such thing), but I think they are generally fairly
special cases (ie things like usermode helper, firmware loaders, etc).

           Linus

  reply	other threads:[~2021-02-12 20:30 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-12 14:08 [GIT PULL] io_uring fix for 5.11 final Jens Axboe
2021-02-12 19:51 ` Linus Torvalds
2021-02-12 20:04   ` Jens Axboe
2021-02-12 20:07     ` Linus Torvalds
2021-02-12 20:09       ` Jens Axboe
2021-02-12 20:15         ` Linus Torvalds
2021-02-12 20:22           ` Jens Axboe
2021-02-12 20:29             ` Linus Torvalds [this message]
2021-02-12 20:42               ` Jens Axboe
2021-02-12 20:12 ` pr-tracker-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='CAHk-=wgK+8CbxbHKxcJop2sq634mZYUhMeNXLUN6fGnrrKeXbg@mail.gmail.com' \
    [email protected] \
    [email protected] \
    [email protected] \
    /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