mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Gautam Menghani <gautam@linux.ibm.com>,
	kch@nvidia.com, ming.lei@redhat.com,
	damien.lemoal@opensource.wdc.com, zhouchengming@bytedance.com,
	nj.shetty@samsung.com, akinobu.mita@gmail.com
Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
	riteshh@linux.ibm.com
Subject: Re: [PATCH] drivers/block/null_blk: Switch from radix tree api to xarrays
Date: Fri, 29 Dec 2023 09:52:47 -0700	[thread overview]
Message-ID: <f1f002e9-8010-4b74-9da8-2551be97fa6f@kernel.dk> (raw)
In-Reply-To: <20231229164155.73541-1-gautam@linux.ibm.com>

On 12/29/23 9:41 AM, Gautam Menghani wrote:
> Convert the null_blk driver to use the xarray API instead of radix tree 
> API.
> 
> Testing:
> Used blktests test suite (block and zbd suites) to test the current 
> null_blk driver and null_blk driver with this patch applied. The tests 
> results in both the instances were the same.

What's the purpose of the change?

One thing that always annoys me slightly with xarray is the implied
locking. So now you're grabbing two locks rather than just utilizing the
lock that was already held. I think a better transformation would be to
first change the locking to be closer to the lookup and deletion, and
then convert to xarray and now being able to drop that other lock. Just
doing a blind conversion like this without potentially understanding the
details of it is not a good idea, imho.

-- 
Jens Axboe


  reply	other threads:[~2023-12-29 16:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-29 16:41 Gautam Menghani
2023-12-29 16:52 ` Jens Axboe [this message]
2024-01-04  4:35   ` Chaitanya Kulkarni

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=f1f002e9-8010-4b74-9da8-2551be97fa6f@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=akinobu.mita@gmail.com \
    --cc=damien.lemoal@opensource.wdc.com \
    --cc=gautam@linux.ibm.com \
    --cc=kch@nvidia.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ming.lei@redhat.com \
    --cc=nj.shetty@samsung.com \
    --cc=riteshh@linux.ibm.com \
    --cc=zhouchengming@bytedance.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 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®