From: Christoph Hellwig <[email protected]>
To: Breno Leitao <[email protected]>
Cc: Christoph Hellwig <[email protected]>,
[email protected], [email protected],
[email protected], [email protected], [email protected],
[email protected], [email protected],
[email protected], [email protected], [email protected]
Subject: Re: [PATCH 1/2] io_uring: Pass whole sqe to commands
Date: Thu, 20 Apr 2023 14:31:39 +0200 [thread overview]
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
On Thu, Apr 20, 2023 at 05:29:18AM -0700, Breno Leitao wrote:
> > > - cmd_size = uring_cmd_pdu_size(req->ctx->flags & IORING_SETUP_SQE128);
> > > + if (req->ctx->flags & IORING_SETUP_SQE128)
> > > + size <<= 1;
> >
> >
> > Why does this stop using uring_cmd_pdu_size()?
>
> Before, only the cmd payload (sqe->cmd) was being copied to the async
> structure. We are copying over the whole sqe now, since we can use SQE
> fields inside the ioctl callbacks (instead of only cmd fields). So, the
> copy now is 64 bytes for single SQE or 128 for double SQEs.
That's the point of this series and I get it. But why do we remove
the nice and self-documenting helper that returns once or twice
the sizeof of the SQE structure and instead add a magic open coded
left shift?
next prev parent reply other threads:[~2023-04-20 12:32 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-19 10:29 [PATCH 0/2] io_uring: Pass whole sqe to commands Breno Leitao
2023-04-19 10:29 ` [PATCH 1/2] " Breno Leitao
2023-04-20 4:57 ` Christoph Hellwig
2023-04-20 12:29 ` Breno Leitao
2023-04-20 12:31 ` Christoph Hellwig [this message]
2023-04-20 12:38 ` Breno Leitao
2023-04-20 12:46 ` Christoph Hellwig
2023-04-30 14:37 ` Breno Leitao
2023-04-21 15:11 ` Breno Leitao
2023-04-24 5:08 ` Christoph Hellwig
2023-04-19 10:29 ` [PATCH 2/2] io_uring: Remove unnecessary BUILD_BUG_ON Breno Leitao
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 \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
/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