[PATCH WIP/RFC v3 3/6] nvme_rdma: keep a ref on the ctrl during delete/flush
Sagi Grimberg
sagi at grimberg.me
Thu Sep 1 02:31:51 PDT 2016
On 01/09/16 11:36, Christoph Hellwig wrote:
> On Tue, Aug 30, 2016 at 08:24:50PM +0300, Sagi Grimberg wrote:
>>
>>> - /* Queue controller deletion */
>>> + /*
>>> + * Queue controller deletion. Keep a reference until all
>>> + * work is flushed since delete_work will free the ctrl mem
>>> + */
>>> + kref_get(&ctrl->ctrl.kref);
>>
>> kref_get_unless_zero?
>
> How could the refcount be zero here?
If another del_ctrl is invoked while the first puts the
final ref?
More information about the Linux-nvme
mailing list