Linux-Block Archive mirror
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: Ming Lei <ming.lei@redhat.com>
Cc: Jens Axboe <axboe@kernel.dk>,
	linux-block@vger.kernel.org, Waiman Long <longman@redhat.com>,
	Jay Shin <jaeshin@redhat.com>
Subject: Re: [PATCH 1/2] blk-cgroup: fix list corruption from resetting io stat
Date: Wed, 15 May 2024 06:49:54 -1000	[thread overview]
Message-ID: <ZkTnsu3gfxCJEnd6@slm.duckdns.org> (raw)
In-Reply-To: <20240515013157.443672-2-ming.lei@redhat.com>

On Wed, May 15, 2024 at 09:31:56AM +0800, Ming Lei wrote:
> Since commit 3b8cc6298724 ("blk-cgroup: Optimize blkcg_rstat_flush()"),
> each iostat instance is added to blkcg percpu list, so blkcg_reset_stats()
> can't reset the stat instance by memset(), otherwise the llist may be
> corrupted.
> 
> Fix the issue by only resetting the counter part.
> 
> Cc: Tejun Heo <tj@kernel.org>
> Cc: Waiman Long <longman@redhat.com>
> Cc: Jay Shin <jaeshin@redhat.com>
> Fixes: 3b8cc6298724 ("blk-cgroup: Optimize blkcg_rstat_flush()")
> Signed-off-by: Ming Lei <ming.lei@redhat.com>

Acked-by: Tejun Heo <tj@kernel.org>

Thanks.

-- 
tejun

  parent reply	other threads:[~2024-05-15 16:49 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-15  1:31 [PATCH 0/2] blk-cgroup: two fixes on list corruption Ming Lei
2024-05-15  1:31 ` [PATCH 1/2] blk-cgroup: fix list corruption from resetting io stat Ming Lei
2024-05-15 13:59   ` Waiman Long
2024-05-15 16:49   ` Tejun Heo [this message]
2024-05-15  1:31 ` [PATCH 2/2] blk-cgroup: fix list corruption from reorder of WRITE ->lqueued Ming Lei
2024-05-15 14:09   ` Waiman Long
2024-05-15 14:46     ` Waiman Long
2024-05-16  0:58     ` Ming Lei
2024-05-16  2:21 ` [PATCH 0/2] blk-cgroup: two fixes on list corruption 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=ZkTnsu3gfxCJEnd6@slm.duckdns.org \
    --to=tj@kernel.org \
    --cc=axboe@kernel.dk \
    --cc=jaeshin@redhat.com \
    --cc=linux-block@vger.kernel.org \
    --cc=longman@redhat.com \
    --cc=ming.lei@redhat.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).