All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Pavel Begunkov <asml.silence@gmail.com>,
	syzbot <syzbot+ac957324022b7132accf@syzkaller.appspotmail.com>,
	io-uring@vger.kernel.org, linux-kernel@vger.kernel.org,
	mingo@kernel.org, mingo@redhat.com, peterz@infradead.org,
	rostedt@goodmis.org, syzkaller-bugs@googlegroups.com,
	will@kernel.org
Subject: Re: [syzbot] INFO: task hung in io_sq_thread_park (2)
Date: Mon, 19 Jul 2021 12:38:37 -0600	[thread overview]
Message-ID: <98a5f4a7-428b-fc0c-3f8c-c368f98d79a2@kernel.dk> (raw)
In-Reply-To: <b48f3e01-c07d-56ac-3624-afc74ef08acd@gmail.com>

On 7/19/21 11:28 AM, Pavel Begunkov wrote:
> On 7/19/21 6:13 PM, Jens Axboe wrote:
>> On 7/19/21 10:57 AM, Pavel Begunkov wrote:
>>> On 7/16/21 11:57 AM, syzbot wrote:
>>>> Hello,
>>>>
>>>> syzbot has tested the proposed patch but the reproducer is still triggering an issue:
>>>> WARNING in io_uring_cancel_generic
>>>
>>> __arm_poll doesn't remove a second poll entry in case of failed
>>> __io_queue_proc(), it's most likely the cause here.
>>>
>>> #syz test: https://github.com/isilence/linux.git syztest_sqpoll_hang
>>
>> Was my thought on seeing the last debug run too. Haven't written a test
>> case, but my initial thought was catching this at the time that double
>> poll is armed, in __io_queue_proc(). Totally untested, just tossing
>> it out there.
> 
> Wouldn't help, unfortunately, the way syz triggers it is making a
> request to go through __io_queue_proc() three times.
> 
> Either it's 3 waitqueues or we need to extend the check below to
> the double poll entry.
> 
> if (poll_one->head == head)
> 	return;

Yes good point, that'd depend on single poll erroring first. Given
the variety of cases for it, catching it after the fact like in your
patch is likely the simplest/cleanest way.

-- 
Jens Axboe


  reply	other threads:[~2021-07-19 19:15 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-15  3:19 [syzbot] INFO: task hung in io_sq_thread_park (2) syzbot
2021-07-15  8:44 ` Pavel Begunkov
2021-07-15  9:15   ` syzbot
2021-07-15 18:16     ` Pavel Begunkov
2021-07-16  0:14       ` syzbot
2021-07-16 10:38         ` Pavel Begunkov
2021-07-16 10:57           ` syzbot
2021-07-19 13:15             ` Pavel Begunkov
2021-07-19 13:46               ` syzbot
2021-07-19 16:57             ` Pavel Begunkov
2021-07-19 17:13               ` Jens Axboe
2021-07-19 17:28                 ` Pavel Begunkov
2021-07-19 18:38                   ` Jens Axboe [this message]
2021-07-19 17:15               ` syzbot

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=98a5f4a7-428b-fc0c-3f8c-c368f98d79a2@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=asml.silence@gmail.com \
    --cc=io-uring@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=syzbot+ac957324022b7132accf@syzkaller.appspotmail.com \
    --cc=syzkaller-bugs@googlegroups.com \
    --cc=will@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.