[PATCH v1] nvme: avoid race in shutdown namespace removal

Hannes Reinecke hare at suse.de
Mon Aug 30 10:14:02 PDT 2021


On 8/30/21 12:04 PM, Daniel Wagner wrote:
> On Mon, Aug 30, 2021 at 11:36:18AM +0200, Daniel Wagner wrote:
>> Though one thing I am not really sure how it interacts with
>> nvme_init_ns_head() as we could be in running nvme_init_ns_head()
>> after we have set last_path = true. I haven't really figured
>> out yet what this would mean. Is this a real problem?
> 
> I suspect it will regress the very thing 5396fdac56d8 ("nvme: fix
> refcounting imbalance when all paths are down") tried to fix.
> 
Most likely. Do drop me a mail on how to create a reproducer for that; 
it's not exactly trivial as you need to patch qemu for that
(and, of course, those patches will not go upstream as they again hit a 
section which the maintainer deemed to be reworked any time now. So of 
course he can't possibly apply them.)
(I seem to have a particular spell of bad luck, seeing that it's the 
_third_ time this happened to me :-( )

Cheers,

Hannes
-- 
Dr. Hannes Reinecke                Kernel Storage Architect
hare at suse.de                              +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer



More information about the Linux-nvme mailing list