linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Hugh Dickins <hughd@google.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Oleg Nesterov <oleg@redhat.com>, Qian Cai <cai@lca.pw>,
	axboe@kernel.dk,  hch@lst.de, peterz@infradead.org,
	gkohli@codeaurora.org, mingo@redhat.com,  linux-mm@kvack.org,
	linux-kernel@vger.kernel.org,  Hugh Dickins <hughd@google.com>
Subject: Re: [PATCH] swap_readpage: avoid blk_wake_io_task() if !synchronous
Date: Thu, 4 Jul 2019 14:15:33 -0700 (PDT)	[thread overview]
Message-ID: <alpine.LSU.2.11.1907041408040.1762@eggly.anvils> (raw)
In-Reply-To: <20190704123218.87a763f771efad158e1b0a89@linux-foundation.org>

On Thu, 4 Jul 2019, Andrew Morton wrote:
> On Thu, 4 Jul 2019 18:03:01 +0200 Oleg Nesterov <oleg@redhat.com> wrote:
> 
> > swap_readpage() sets waiter = bio->bi_private even if synchronous = F,
> > this means that the caller can get the spurious wakeup after return. This
> > can be fatal if blk_wake_io_task() does set_current_state(TASK_RUNNING)
> > after the caller does set_special_state(), in the worst case the kernel
> > can crash in do_task_dead().
> 
> I think we need a Fixes: and a cc:stable here?
> 
> IIRC, we're fixing 0619317ff8baa2 ("block: add polled wakeup task helper").

Yes, you are right.

But catch me by surprise: I had been thinking this was a 5.2 regression.
I guess something in 5.2 (doesn't matter what) has made it significantly
easier to hit: but now I look at old records, see that I hit it once on
5.0-rc1, then never again until 5.2.

Thanks, and to Oleg,
Hugh


      reply	other threads:[~2019-07-04 21:15 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-29 20:25 [PATCH] block: fix a crash in do_task_dead() Qian Cai
2019-05-29 20:31 ` Jens Axboe
2019-05-30  8:03 ` Peter Zijlstra
2019-05-31 21:12   ` Jens Axboe
2019-06-03 12:37     ` Peter Zijlstra
2019-06-03 12:44       ` Peter Zijlstra
2019-06-03 16:09         ` Oleg Nesterov
2019-06-03 16:19           ` Peter Zijlstra
2019-06-03 16:23       ` Jens Axboe
2019-06-05 15:04       ` Jens Axboe
2019-06-07 13:35         ` Peter Zijlstra
2019-06-07 14:23           ` Peter Zijlstra
2019-06-08  8:39             ` Jens Axboe
2019-06-10 13:13             ` Gaurav Kohli
2019-06-10 14:46               ` Oleg Nesterov
2019-06-11  4:39                 ` Gaurav Kohli
2019-06-30 23:06         ` Hugh Dickins
2019-07-01 14:22           ` Jens Axboe
2019-07-02 22:06             ` Andrew Morton
2019-07-03 17:35               ` Oleg Nesterov
2019-07-03 17:44                 ` Hugh Dickins
2019-07-04 16:00                   ` Oleg Nesterov
2019-07-03 17:52                 ` Jens Axboe
2019-05-30 11:15 ` Oleg Nesterov
2019-05-31 21:10   ` Jens Axboe
2019-07-04 16:03 ` [PATCH] swap_readpage: avoid blk_wake_io_task() if !synchronous Oleg Nesterov
2019-07-04 19:32   ` Andrew Morton
2019-07-04 21:15     ` Hugh Dickins [this message]

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=alpine.LSU.2.11.1907041408040.1762@eggly.anvils \
    --to=hughd@google.com \
    --cc=akpm@linux-foundation.org \
    --cc=axboe@kernel.dk \
    --cc=cai@lca.pw \
    --cc=gkohli@codeaurora.org \
    --cc=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mingo@redhat.com \
    --cc=oleg@redhat.com \
    --cc=peterz@infradead.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