[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <e27ea63a-8dd5-afad-b5d6-deabf879d191@huaweicloud.com>
Date: Mon, 16 Jan 2023 11:25:07 +0800
From: Yu Kuai <yukuai1@...weicloud.com>
To: Tejun Heo <tj@...nel.org>, Yu Kuai <yukuai1@...weicloud.com>
Cc: hch@...radead.org, josef@...icpanda.com, axboe@...nel.dk,
cgroups@...r.kernel.org, linux-block@...r.kernel.org,
linux-kernel@...r.kernel.org, yi.zhang@...wei.com,
"yukuai (C)" <yukuai3@...wei.com>
Subject: Re: [PATCH v2 1/2] blk-iocost: add refcounting for iocg
Hi,
在 2023/01/14 1:16, Tejun Heo 写道:
> As we discussed before, you'd have to order the actual freeing by shifting
> the ref puts into the free_work. If you move `blkg_put(blkg->parent)` and
> `list_del_init(&blkg->q_node)` to blkg_free_workfn() (this will require
> adjustments as these things are used from other places too), the free work
> items will be ordered and the blkg would remain iterable - IOW,
> deactivate_policy would be able to see it allowing the two paths to
> synchronize, right?
That sounds reasonable to only remove blkg from queue list if
pd_free_fn() is done.
It's right this way deactivate_policy will be able to see it, and if
deactivate_policy is called first, pd_free_fn() can be called here, and
later blkg_free_workfn() should skip pd_free_fn().
It's glad that we come up with suitable solution finially. 😃
BTW, it might take some time before I send a new patchset cause Spring
Festival is coming.
Thanks,
Kuai
>
> Thanks.
>
Powered by blists - more mailing lists