mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Uzair Beg <uzairbeg11@gmail.com>
To: krisman@suse.de
Cc: io-uring@vger.kernel.org, axboe@kernel.dk,
	asml.silence@gmail.com, lin2530632123@gmail.com,
	linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH 1/3] io_uring/rsrc: allocate io_rsrc_node from a dedicated kmem_cache
Date: Fri, 25 Sep 2026 16:36:07 +0000	[thread overview]
Message-ID: <20260925163607.524636-1-uzairbeg11@gmail.com> (raw)
In-Reply-To: <87jyom1ju2.fsf@mailhost.krisman.be>

Gabriel Krisman Bertazi <krisman@suse.de> writes:

> Not opposed to having a slab, but I actually think it is
> unnecessary.  see patch 2.  If we do that, we actually should delete the
> async_size parameter in the opdef, since it is now redundant.  But
> see comments in patch 2.

Sorry for the slow reply, and thanks for the review. I couldn't find
your comments on 2/3, either in my inbox or on lore, so I may have
missed them. Could you resend?

For context, 1/3 and 2/3 were both neutral on their own and exist only
to support 3/3. If 3/3 changes shape as discussed in that thread, I
expect to drop both.

> FWIW, this is exactly why we have the (*free) callback, you should have a function
> for your specific type used as a callback that does the kmem_cache_free
> so you don't need the if/else here.
>
> But for a simple kmem_cache_free, kfree works just fine.

Agreed on both. I was guarding against a mismatch that kfree() already
handles for kmem_cache objects, so the free paths did not need touching.

  reply	other threads:[~2026-09-25 16:39 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-14  9:20 [RFC PATCH 0/3] io_uring/rsrc: reduce node allocation cost on sparse file table installs Uzair Beg
2026-09-14  9:20 ` [RFC PATCH 1/3] io_uring/rsrc: allocate io_rsrc_node from a dedicated kmem_cache Uzair Beg
2026-09-15 17:54   ` Gabriel Krisman Bertazi
2026-09-25 16:36     ` Uzair Beg [this message]
2026-09-14  9:20 ` [RFC PATCH 2/3] io_uring/rsrc: bulk refill the node cache on allocation miss Uzair Beg
2026-09-14  9:20 ` [RFC PATCH 3/3] io_uring/rsrc: prefill the node cache when a file table is registered empty Uzair Beg
2026-09-15 18:20   ` Gabriel Krisman Bertazi
2026-09-25 16:39     ` Uzair Beg
2026-09-25 19:42       ` Gabriel Krisman Bertazi

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=20260925163607.524636-1-uzairbeg11@gmail.com \
    --to=uzairbeg11@gmail.com \
    --cc=asml.silence@gmail.com \
    --cc=axboe@kernel.dk \
    --cc=io-uring@vger.kernel.org \
    --cc=krisman@suse.de \
    --cc=lin2530632123@gmail.com \
    --cc=linux-kernel@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

all inboxes | Powered by JetHome®