All of lore.kernel.org
 help / color / mirror / Atom feed
From: tada keisuke <keisuke1.tada@kioxia.com>
To: Yu Kuai <yukuai1@huaweicloud.com>, "song@kernel.org" <song@kernel.org>
Cc: "linux-raid@vger.kernel.org" <linux-raid@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"yukuai (C)" <yukuai3@huawei.com>
Subject: Re: [PATCH 00/11] md: avoid counter operation conflicts
Date: Wed, 27 Mar 2024 01:27:19 +0000	[thread overview]
Message-ID: <481dc71231494b729b13dcc7392deb00@kioxia.com> (raw)
In-Reply-To: <140c7f16-4c2a-390a-7021-53d3723626ec@huaweicloud.com>

>> Currently, active_aligned_reads and nr_pending used as counters are atomic types.
>> Therefore, when inc/dec in a multi-core results in conflicts.
>
> I don't uderstand what's the problem here, what's wrong with atomic
> types in a multi-core system?

Hi Kuai

This patch is not a fix for the problem, but an improvement.
This patch makes the counter inc/dec faster.

For the same reason, active_io was changed from atomic_t to percpu_ref.
https://marc.info/?l=linux-raid&m=167514225920879

Thanks,
Keisuke


  reply	other threads:[~2024-03-27  1:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-26 10:29 [PATCH 00/11] md: avoid counter operation conflicts tada keisuke
2024-03-26 14:01 ` Yu Kuai
2024-03-27  1:27   ` tada keisuke [this message]
2024-04-10 21:13 ` Song Liu

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=481dc71231494b729b13dcc7392deb00@kioxia.com \
    --to=keisuke1.tada@kioxia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-raid@vger.kernel.org \
    --cc=song@kernel.org \
    --cc=yukuai1@huaweicloud.com \
    --cc=yukuai3@huawei.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.