Re: [PATCH blktests] nvme/069: add a test for multipath cdev lifetime

John Garry <[email protected]>
Newsgroups org.infradead.lists.linux-nvme,org.kernel.vger.linux-block
Organization Oracle Corporation
Message-ID <[email protected]>
On 15/07/2026 13:20, Daniel Wagner wrote:
> On Tue, Jul 14, 2026 at 09: 43: 45AM +0000, John Garry wrote: > + # nvme-delay-
> ioctl will open the nvme-generic cdev, sleep, and then > + # issue an ioctl. > +
> # We tear down the nvme-subsystem in the foreground so we can catch > +
> 
> 
> On Tue, Jul 14, 2026 at 09:43:45AM +0000, John Garry wrote:
>> +	# nvme-delay-ioctl will open the nvme-generic cdev, sleep, and then
>> +	# issue an ioctl.
>> +	# We tear down the nvme-subsystem in the foreground so we can catch
>> +	# if the ioctl triggers a use-after-free KASAN warn.
>> +	src/nvme-delay-ioctl "/dev/$nvmegeneric" &
>> +	sleep 0.5
>> +	_nvme_disconnect_ctrl "${nvmedev}"
> 
> The sleep above is to give nvme-delay-ioctl enough time to setup,
> right? 

Right

> Would it possible for nvme-delay-ioctl issue some signal (or any
> other working sync method) and we just wait for it to show up? IMO sleep
> should be avoided if possible.

I suppose we could do something like nvme-delay-ioctl writing to a file, 
which we can poll. Or use a signal.

Let me investigate.

John
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.