Updated SRPT documentation.

git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1024 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2009-08-07 14:14:19 +00:00
parent 4588200994
commit c7572cd2cb
3 changed files with 67 additions and 23 deletions

View File

@@ -53,6 +53,7 @@ Unload any loaded InfiniBand drivers:
Remove any distro-provided InfiniBand drivers:
rm -rf /lib/modules/$(uname -r)/kernel/drivers/infiniband
rm -rf /lib/modules/$(uname -r)/kernel/drivers/net/mlx4
Now locate the file Makefile.lib and patch it such that it supports
the variable PRE_CFLAGS:

58
srpt/Testing.txt Normal file
View File

@@ -0,0 +1,58 @@
The following tests must be run at least before releasing a new SRPT version:
* Make sure that SRPT compiles and installs without triggering any
compiler warning. Use the following command to compile and install SRPT:
for d in scst srpt; do make -C $d -s clean && make -C $d -s install; done
* Verify the output of run-regression-tests for kernel versions starting at
2.6.23 up to and including the latest released kernel.
* Verify that SRPT compiles, installs and works fine when following the
instructions in README.ofed for the latest released OFED distribution and
at the latest released CentOS, Ubuntu and openSUSE distributions.
* Verify that module loading and unloading works fine.
* Verify that rejecting logins does not trigger a memory leak, e.g. as follows:
* Run the following command on the target system:
${SCST_TRUNK}/scripts/monitor-memory-usage | tee memlog.txt
* Run the following command on the initiator system:
for ((i=0;i<100000;i++)); do echo 'id_ext=0002c9030003cca2,ioc_guid=0002c9030003cca2,pkey=ffff,dgid=fe800000000000000002c9030003cca3,service_id=0002c9030003cca3' >/sys/class/infiniband_srp/srp-mlx4_0-1/add_target ; done
* Verify that an I/O stress test runs fine by running the following command
on an initiator system after having created two partitions:
fio <<EOF
[global]
bs=1M
direct=1
ioengine=sync
verify=meta
rw=write
verify_fatal=1
verify_async=1
loops=10
[partition1]
filename=/dev/sdb1
[partition2]
filename=/dev/sdb2
EOF
* Verify that a SCSI reset works properly by running the following command
on an initiator system:
sg_reset -d ${initiator_device}
* Run the following command on a target system:
while true; do /etc/init.d/scst stop; sleep 3; /etc/init.d/scst start; sleep 5; done
and the following commands on an initiator system:
target_id="id_ext=0002c9030003cca2,ioc_guid=0002c9030003cca2,dgid=fe800000000000000002c9030003cca3,pkey=ffff,service_id=0009030003cca2,ioc_guid=0002c9030003cca2,dgid=fe800000000000000002c9030003cca3,pkey=ffff,service_id=0002c9030003cca2"
while true; do date; rmmod ib_srp; modprobe ib_srp; echo "${target_id}" > /sys/class/infiniband_srp/srp-mlx4_0-1/add_target; sleep 2; done
and verify that nothin unexpected happens.

View File

@@ -4,33 +4,18 @@
2. The SRPT driver directly uses the internal state of the SCST core target
state machine (scmnd->state), which is bad, bad, bad and generally not
acceptable. Only dev handler are allowed to use them. This should be fixed.
state machine (scmnd->state field / SCST_CMD_STATE_* values), which is bad,
bad, bad and generally not acceptable. Only dev handler are allowed to use
them. This should be fixed: the SRPT driver should keep its internal state
in an SRPT-specific variable. For an example, see also the "Q2T_STATE_"
constants in the qla2x00t driver, and especially the function
q2t_do_ctio_completion().
3. Fix the race condition between srpt_refresh_port_work() and
srpt_remove_one(). Although the probability that this happens is very low,
at least in theory it is possible that srpt_refresh_port_work() gets
called for a port after srpt_remove_one() called kfree() on the data
structure that contains the work_struct passed to srpt_refresh_port_work().
It's not clear to me whether or not letting srpt_remove_one() wait until
srpt_refresh_work() finished can result in a deadlock.
4. Find out from which threads the srpt_devices list can be accessed and
whether it has to be protected by a spinlock or mutex.
5. Fix the issue that 'rmmod ib_srpt' under load hangs.
6. The initiator names supplied to the SCST core contain the target port name,
3. The initiator names supplied to the SCST core contain the target port name,
which is wrong. Nobody identifies a man by the door through which he entered.
Instead, a man has a name by which he is identified through his whole life.
7. Analyze and document the implications of
4. Analyze and document the implications of
sdev->mr = ib_get_dma_mr(sdev->pd, IB_ACCESS_LOCAL_WRITE).
8. Enable and test the LUN_RESET task management function.