All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kanchan Joshi <joshi.k@samsung.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: anuj20.g@samsung.com, io-uring@vger.kernel.org, ming.lei@redhat.com
Subject: Re: [PATCH] io_uring: fix error handling for io_uring_cmd
Date: Thu, 11 Aug 2022 23:05:53 +0530	[thread overview]
Message-ID: <20220811173553.GA16993@test-zns> (raw)
In-Reply-To: <f172af9b-2321-c819-2e29-357d4f130159@kernel.dk>

[-- Attachment #1: Type: text/plain, Size: 969 bytes --]

On Thu, Aug 11, 2022 at 10:55:29AM -0600, Jens Axboe wrote:
>On 8/11/22 9:38 AM, Jens Axboe wrote:
>> On Thu, 11 Aug 2022 14:44:59 +0530, Anuj Gupta wrote:
>>> Commit 97b388d70b53 ("io_uring: handle completions in the core") moved the
>>> error handling from handler to core. But for io_uring_cmd handler we end
>>> up completing more than once (both in handler and in core) leading to
>>> use_after_free.
>>> Change io_uring_cmd handler to avoid calling io_uring_cmd_done in case
>>> of error.
>>>
>>> [...]
>>
>> Applied, thanks!
>>
>> [1/1] io_uring: fix error handling for io_uring_cmd
>>       commit: f1bb0fd63c374e1410ff05fb434aa78e1ce09ae4
>
>Ehm, did you compile this:
Sorry. Version that landed here got a upgrade in
commit-description but downgrade in this part :-(

BTW, we noticed the original issue while testing fixedbufs support.
Thinking to add a liburing test that involves sending a command which
nvme will fail during submission. Can come in handy.

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



  reply	other threads:[~2022-08-11 17:46 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20220811092503epcas5p2e945f7baa5cb0cd7e3d326602c740edb@epcas5p2.samsung.com>
2022-08-11  9:14 ` [PATCH] io_uring: fix error handling for io_uring_cmd Anuj Gupta
2022-08-11 15:38   ` Jens Axboe
2022-08-11 16:55     ` Jens Axboe
2022-08-11 17:35       ` Kanchan Joshi [this message]
2022-08-11 17:51         ` Jens Axboe
2022-08-11 17:57           ` Kanchan Joshi
2022-08-11 18:08             ` 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=20220811173553.GA16993@test-zns \
    --to=joshi.k@samsung.com \
    --cc=anuj20.g@samsung.com \
    --cc=axboe@kernel.dk \
    --cc=io-uring@vger.kernel.org \
    --cc=ming.lei@redhat.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 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.