linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Moyer <jmoyer@redhat.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: "linux-fsdevel\@vger.kernel.org" <linux-fsdevel@vger.kernel.org>,
	"linux-block\@vger.kernel.org" <linux-block@vger.kernel.org>,
	linux-aio@kvack.org
Subject: Re: [PATCH] fs: kill unused ret2 argument from iocb->ki_complete()
Date: Wed, 20 Oct 2021 14:37:03 -0400	[thread overview]
Message-ID: <x494k9bo84w.fsf@segfault.boston.devel.redhat.com> (raw)
In-Reply-To: <16a7a029-0d23-6a14-9ae9-79ab8a9adb34@kernel.dk> (Jens Axboe's message of "Wed, 20 Oct 2021 12:21:55 -0600")

Jens Axboe <axboe@kernel.dk> writes:

> On 10/20/21 12:16 PM, Jeff Moyer wrote:
>> Hi, Jens,
>> 
>> Jens Axboe <axboe@kernel.dk> writes:
>> 
>>> It's not used for anything, and we're wasting time passing in zeroes
>>> where we could just ignore it instead. Update all ki_complete users in
>>> the kernel to drop that last argument.
>> 
>> What does "wasting time passing in zeroes" mean?
>
> That everybody but the funky usb gadget code passes in zero, hence it's
> a waste of time to pass it in as an argument.

OK.  Just making sure you hadn't found some performance gain from this.
:)

>> We can't know whether some userspace implementation relies on this
>> behavior, so I don't think you can change it.
>
> Well, I think we should find out, particularly as it's the sole user of
> that extra argument.

How can we find out?  Anyone can write userspace usb gadget code.  Some
of those users may be proprietary.  Is that likely?  I don't know.  I'd
rather err on the side of not (potentially) breaking existing
applications, though.

> No generic aio code would look at res2, exactly because it is always
> zero for anything but some weird usb gadget code.

I think that no generic code looks at it because it isn't meant to be
interpreted by generic code.  :)

-Jeff


  reply	other threads:[~2021-10-20 18:35 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-20 16:49 [PATCH] fs: kill unused ret2 argument from iocb->ki_complete() Jens Axboe
2021-10-20 17:30 ` Christoph Hellwig
2021-10-20 17:35   ` Jens Axboe
2021-10-20 17:49     ` Greg Kroah-Hartman
2021-10-21 16:40       ` John Keeping
2021-10-21 16:56         ` Jens Axboe
2021-10-22 15:44         ` Jens Axboe
2021-10-23  9:09           ` Greg Kroah-Hartman
2021-10-23 14:01             ` Jens Axboe
2021-10-20 18:16 ` Jeff Moyer
2021-10-20 18:21   ` Jens Axboe
2021-10-20 18:37     ` Jeff Moyer [this message]
2021-10-20 18:41       ` Jens Axboe
2021-10-20 18:56         ` Jens Axboe
2021-10-20 19:11           ` Jeff Moyer
2021-10-20 19:12             ` Jens Axboe
2021-10-20 19:47               ` Jeff Moyer
2021-10-20 19:54                 ` 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=x494k9bo84w.fsf@segfault.boston.devel.redhat.com \
    --to=jmoyer@redhat.com \
    --cc=axboe@kernel.dk \
    --cc=linux-aio@kvack.org \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-fsdevel@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).