Re: [PATCH] percpu-refcount: relax limit on percpu_ref_reinit()

Tejun Heo
2018-09-11T16:39:03Z

Hello, Ming.

On Wed, Sep 12, 2018 at 12:34:44AM +0800, Ming Lei wrote:
> > Why aren't switch_to_atomic/percpu enough?
>
> The blk-mq's use case is this _reinit is done on one refcount which was
> killed via percpu_ref_kill(), so the DEAD flag has to be cleared.

If you killed and waited until kill finished, you should be able to
re-init. Is it that you want to kill but abort killing in some cases?
How do you then handle the race against release? Can you please
describe the exact usage you have on mind?

Thanks.

--
tejun