From: Linus Torvalds <torvalds@linux-foundation.org>
To: Jens Axboe <axboe@kernel.dk>
Cc: "linux-block@vger.kernel.org" <linux-block@vger.kernel.org>,
Christoph Hellwig <hch@lst.de>
Subject: Re: block: only use __set_current_state() for polled IO
Date: Wed, 2 Jan 2019 10:11:39 -0800 [thread overview]
Message-ID: <CAHk-=whcmNjH+3pP_tgKbxe3iNu20eVVxfDyVXrKsNf7HiR0WA@mail.gmail.com> (raw)
In-Reply-To: <CAHk-=wicNcMhY_YCkT5Nsdcxake8x+sfYUByvbhTzp2v-LWjeA@mail.gmail.com>
On Wed, Jan 2, 2019 at 10:07 AM Linus Torvalds
<torvalds@linux-foundation.org> wrote:
>
> Stop this craziness. The optimization is garbage. If you want to save
> 15 cycles, get rid of code, don't add new code in an area where the
> block maintainers have already shown that they can't get it right.
Side note: that argument is further strengthened by a very simple
observation: if the code isn't going to sleep, then the whole state
setting is entirely and utterly pointless.
So code like this:
+ if (is_poll)
+ __set_current_state(TASK_UNINTERRUPTIBLE);
is *FUNDAMENTAL* garbage.
Seriously, stop playing stupid games. You're doing things wrong.
I'm doing to revert that buggy commit, and I will not pull any crazy
code that tries to redo this kind of completely broken code.
Linus
next prev parent reply other threads:[~2019-01-02 18:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-02 17:55 block: only use __set_current_state() for polled IO Jens Axboe
2019-01-02 18:07 ` Linus Torvalds
2019-01-02 18:10 ` Jens Axboe
2019-01-02 18:11 ` Linus Torvalds [this message]
2019-01-02 18:14 ` Jens Axboe
2019-01-02 18:55 ` Linus Torvalds
2019-01-02 18:59 ` Jens Axboe
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-=whcmNjH+3pP_tgKbxe3iNu20eVVxfDyVXrKsNf7HiR0WA@mail.gmail.com' \
--to=torvalds@linux-foundation.org \
--cc=axboe@kernel.dk \
--cc=hch@lst.de \
--cc=linux-block@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;
as well as URLs for NNTP newsgroup(s).