[PATCH] nvme: add nvme pci timeout testcase

Chaitanya Kulkarni chaitanyak at nvidia.com
Wed Jan 10 19:09:45 PST 2024


On 1/10/24 17:25, Yi Zhang wrote:
> On Wed, Jan 10, 2024 at 11:58 AM Chaitanya Kulkarni <kch at nvidia.com> wrote:
>> Trigger and test nvme-pci timeout with concurrent fio jobs.
>>
>> Signed-off-by: Chaitanya Kulkarni <kch at nvidia.com>
>> ---
>>   tests/nvme/050     | 43 +++++++++++++++++++++++++++++++++++++++++++
>>   tests/nvme/050.out |  2 ++
>>   2 files changed, 45 insertions(+)
>>   create mode 100755 tests/nvme/050
>>   create mode 100644 tests/nvme/050.out
>>
>> diff --git a/tests/nvme/050 b/tests/nvme/050
>> new file mode 100755
>> index 0000000..ba54bcd
>> --- /dev/null
>> +++ b/tests/nvme/050
>> @@ -0,0 +1,43 @@
>> +#!/bin/bash
>> +# SPDX-License-Identifier: GPL-3.0+
>> +# Copyright (C) 2024 Chaitanya Kulkarni.
>> +#
>> +# Test NVMe-PCI timeout with FIO jobs by triggering the nvme_timeout function.
>> +#
>> +
>> +. tests/nvme/rc
> How about restricting this test to pci only? just like nvme/032 did.
> nvme_trtype=pci

Yes it has to now, since I'm adding TEST_DEV, thanks for mentioning that
already added that change to v2.

>> +
>> +DESCRIPTION="test nvme-pci timeout with fio jobs."
>> +
>> +requires() {
>> +       _require_nvme_trtype pci
>> +       _have_fio
>> +       _nvme_requires
>> +}
> Check the test dev is nvme:
> device_requires() {
>          _require_test_dev_is_nvme
> }
>
>> +
>> +test() {
> Use test_device() here.

okay ..


-ck



More information about the Linux-nvme mailing list