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

John Garry john.g.garry at oracle.com
Wed Jul 15 06:19:59 PDT 2026


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



More information about the Linux-nvme mailing list