diff mbox series

[blktests,4/4] tests/srp/015: Add a test that uses the SoftiWARP (siw) driver

Message ID 20191115170711.232741-5-bvanassche@acm.org (mailing list archive)
State New, archived
Headers show
Series Add an SRP test for the SoftiWARP driver | expand

Commit Message

Bart Van Assche Nov. 15, 2019, 5:07 p.m. UTC
Recently support has been added in the SRP initiator and target drivers
for the SoftiWARP driver. Add a test for SRP over SoftiWARP.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>
---
 tests/srp/015     | 42 ++++++++++++++++++++++++++++++++++++++++++
 tests/srp/015.out |  2 ++
 2 files changed, 44 insertions(+)
 create mode 100755 tests/srp/015
 create mode 100644 tests/srp/015.out

Comments

Omar Sandoval Nov. 25, 2019, 8:13 p.m. UTC | #1
On Fri, Nov 15, 2019 at 09:07:11AM -0800, Bart Van Assche wrote:
> Recently support has been added in the SRP initiator and target drivers
> for the SoftiWARP driver. Add a test for SRP over SoftiWARP.
> 
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
> ---
>  tests/srp/015     | 42 ++++++++++++++++++++++++++++++++++++++++++
>  tests/srp/015.out |  2 ++
>  2 files changed, 44 insertions(+)
>  create mode 100755 tests/srp/015
>  create mode 100644 tests/srp/015.out

Hi, Bart,

I'm getting:

srp/015 (File I/O on top of multipath concurrently with logout and login (mq) using the SoftiWARP (siw) driver) [failed]
    runtime  1.076s  ...  1.026s
    --- tests/srp/015.out       2019-11-25 12:07:06.749425714 -0800
    +++ /home/vmuser/repos/blktests/results/nodev/srp/015.out.bad       2019-11-25 12:12:07.634062201 -0800
    @@ -1,2 +1 @@
    -Configured SRP target driver
    -Passed
    +mkdir: cannot create directory ‘0x52540012345600000000000000000000’: Invalid argument

This is on v5.4-rc8 with CONFIG_RDMA_SIW=m. Do you know what is wrong
here?

Thanks!
Bart Van Assche Nov. 25, 2019, 8:49 p.m. UTC | #2
On 11/25/19 12:13 PM, Omar Sandoval wrote:
> On Fri, Nov 15, 2019 at 09:07:11AM -0800, Bart Van Assche wrote:
>> Recently support has been added in the SRP initiator and target drivers
>> for the SoftiWARP driver. Add a test for SRP over SoftiWARP.
>>
>> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
>> ---
>>   tests/srp/015     | 42 ++++++++++++++++++++++++++++++++++++++++++
>>   tests/srp/015.out |  2 ++
>>   2 files changed, 44 insertions(+)
>>   create mode 100755 tests/srp/015
>>   create mode 100644 tests/srp/015.out
> 
> Hi, Bart,
> 
> I'm getting:
> 
> srp/015 (File I/O on top of multipath concurrently with logout and login (mq) using the SoftiWARP (siw) driver) [failed]
>      runtime  1.076s  ...  1.026s
>      --- tests/srp/015.out       2019-11-25 12:07:06.749425714 -0800
>      +++ /home/vmuser/repos/blktests/results/nodev/srp/015.out.bad       2019-11-25 12:12:07.634062201 -0800
>      @@ -1,2 +1 @@
>      -Configured SRP target driver
>      -Passed
>      +mkdir: cannot create directory ‘0x52540012345600000000000000000000’: Invalid argument
> 
> This is on v5.4-rc8 with CONFIG_RDMA_SIW=m. Do you know what is wrong
> here?

Hi Omar,

I should have mentioned that the SRP iWARP support patches have been 
accepted in the RDMA tree but that these are not yet in Linus' tree. The 
SRP iWARP patches should be merged in Linus' tree during the current 
merge window. If you would like to test these patches before Linus 
merges the RDMA pull request, please have a look at 
https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git/log/?h=for-next&ofs=1000

Thanks,

Bart.
Omar Sandoval Nov. 25, 2019, 9:10 p.m. UTC | #3
On Mon, Nov 25, 2019 at 12:49:51PM -0800, Bart Van Assche wrote:
> On 11/25/19 12:13 PM, Omar Sandoval wrote:
> > On Fri, Nov 15, 2019 at 09:07:11AM -0800, Bart Van Assche wrote:
> > > Recently support has been added in the SRP initiator and target drivers
> > > for the SoftiWARP driver. Add a test for SRP over SoftiWARP.
> > > 
> > > Signed-off-by: Bart Van Assche <bvanassche@acm.org>
> > > ---
> > >   tests/srp/015     | 42 ++++++++++++++++++++++++++++++++++++++++++
> > >   tests/srp/015.out |  2 ++
> > >   2 files changed, 44 insertions(+)
> > >   create mode 100755 tests/srp/015
> > >   create mode 100644 tests/srp/015.out
> > 
> > Hi, Bart,
> > 
> > I'm getting:
> > 
> > srp/015 (File I/O on top of multipath concurrently with logout and login (mq) using the SoftiWARP (siw) driver) [failed]
> >      runtime  1.076s  ...  1.026s
> >      --- tests/srp/015.out       2019-11-25 12:07:06.749425714 -0800
> >      +++ /home/vmuser/repos/blktests/results/nodev/srp/015.out.bad       2019-11-25 12:12:07.634062201 -0800
> >      @@ -1,2 +1 @@
> >      -Configured SRP target driver
> >      -Passed
> >      +mkdir: cannot create directory ‘0x52540012345600000000000000000000’: Invalid argument
> > 
> > This is on v5.4-rc8 with CONFIG_RDMA_SIW=m. Do you know what is wrong
> > here?
> 
> Hi Omar,
> 
> I should have mentioned that the SRP iWARP support patches have been
> accepted in the RDMA tree but that these are not yet in Linus' tree. The SRP
> iWARP patches should be merged in Linus' tree during the current merge
> window. If you would like to test these patches before Linus merges the RDMA
> pull request, please have a look at https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git/log/?h=for-next&ofs=1000

Okay, I figured I was missing something. Can we detect this in
requires() so that it doesn't fail on old kernels?
Bart Van Assche Nov. 25, 2019, 9:41 p.m. UTC | #4
On 11/25/19 1:10 PM, Omar Sandoval wrote:
> On Mon, Nov 25, 2019 at 12:49:51PM -0800, Bart Van Assche wrote:
>> On 11/25/19 12:13 PM, Omar Sandoval wrote:
>>> On Fri, Nov 15, 2019 at 09:07:11AM -0800, Bart Van Assche wrote:
>>>> Recently support has been added in the SRP initiator and target drivers
>>>> for the SoftiWARP driver. Add a test for SRP over SoftiWARP.
>>>>
>>>> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
>>>> ---
>>>>    tests/srp/015     | 42 ++++++++++++++++++++++++++++++++++++++++++
>>>>    tests/srp/015.out |  2 ++
>>>>    2 files changed, 44 insertions(+)
>>>>    create mode 100755 tests/srp/015
>>>>    create mode 100644 tests/srp/015.out
>>>
>>> Hi, Bart,
>>>
>>> I'm getting:
>>>
>>> srp/015 (File I/O on top of multipath concurrently with logout and login (mq) using the SoftiWARP (siw) driver) [failed]
>>>       runtime  1.076s  ...  1.026s
>>>       --- tests/srp/015.out       2019-11-25 12:07:06.749425714 -0800
>>>       +++ /home/vmuser/repos/blktests/results/nodev/srp/015.out.bad       2019-11-25 12:12:07.634062201 -0800
>>>       @@ -1,2 +1 @@
>>>       -Configured SRP target driver
>>>       -Passed
>>>       +mkdir: cannot create directory ‘0x52540012345600000000000000000000’: Invalid argument
>>>
>>> This is on v5.4-rc8 with CONFIG_RDMA_SIW=m. Do you know what is wrong
>>> here?
>>
>> Hi Omar,
>>
>> I should have mentioned that the SRP iWARP support patches have been
>> accepted in the RDMA tree but that these are not yet in Linus' tree. The SRP
>> iWARP patches should be merged in Linus' tree during the current merge
>> window. If you would like to test these patches before Linus merges the RDMA
>> pull request, please have a look at https://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma.git/log/?h=for-next&ofs=1000
> 
> Okay, I figured I was missing something. Can we detect this in
> requires() so that it doesn't fail on old kernels?

Sure, I will make that change.

Bart.
diff mbox series

Patch

diff --git a/tests/srp/015 b/tests/srp/015
new file mode 100755
index 000000000000..faef5089ec4c
--- /dev/null
+++ b/tests/srp/015
@@ -0,0 +1,42 @@ 
+#!/bin/bash
+# SPDX-License-Identifier: GPL-2.0+
+# Copyright 2019 Google LLC
+
+. tests/srp/rc
+
+DESCRIPTION="File I/O on top of multipath concurrently with logout and login (mq) using the SoftiWARP (siw) driver"
+TIMED=1
+
+requires() {
+	_have_modules siw
+}
+
+test_disconnect_repeatedly() {
+	local dev fio_status m
+
+	use_blk_mq y y || return $?
+	dev=$(get_bdev 0) || return $?
+	m=$(mountpoint 0) || return $?
+	create_filesystem "$dev" || return $?
+	mount_and_check "$dev" "$m" || return $?
+	# shellcheck disable=SC2064
+	trap "unmount_and_check $m" RETURN
+	simulate_network_failure_loop "$dev" "$TIMEOUT" &
+	run_fio --verify=md5 --rw=randwrite --bs=4K --loops=$((10**6)) \
+		--iodepth=64 --group_reporting --sync=1 --direct=1 \
+		--ioengine=libaio --directory="$m" --runtime="${TIMEOUT}" \
+		--name=data-integrity-test-mq --thread --numjobs=16 \
+		--output="${RESULTS_DIR}/srp/fio-output-015.txt" \
+		>>"$FULL"
+	fio_status=$?
+	wait
+	log_in
+	return $fio_status
+}
+
+test() {
+	: "${TIMEOUT:=30}"
+	trap 'trap "" EXIT; teardown' EXIT
+	use_siw=1
+	setup && test_disconnect_repeatedly && echo Passed
+}
diff --git a/tests/srp/015.out b/tests/srp/015.out
new file mode 100644
index 000000000000..5e25d8e8672d
--- /dev/null
+++ b/tests/srp/015.out
@@ -0,0 +1,2 @@ 
+Configured SRP target driver
+Passed