Re: [bug report] blktests nvme/047 failed due to /dev/nvme0n1 not created in time

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 10, 2023 at 12:19:39AM +0000, Shinichiro Kawasaki wrote:
> Yi, could you try and see if it avoids the failure?
> 
> diff --git a/tests/nvme/rc b/tests/nvme/rc
> index 4f3a994..005db80 100644
> --- a/tests/nvme/rc
> +++ b/tests/nvme/rc
> @@ -740,7 +740,7 @@ _find_nvme_dev() {
>  		if [[ "$subsysnqn" == "$subsys" ]]; then
>  			echo "$dev"
>  			for ((i = 0; i < 10; i++)); do
> -				if [[ -e /sys/block/$dev/uuid &&
> +				if [[ -e /dev/$dev && -e /sys/block/$dev/uuid &&
>  					-e /sys/block/$dev/wwid ]]; then
>  					return
>  				fi

The path for uuid is not correct. It's needs to be something like

	if [[ -e /dev/$dev && -e /sys/block/"${dev}n1"/uuid &&
		-e /sys/block/"${dev}n1"/wwid ]]; then
			return
	fi



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux