IB/srp: Maintain a single connection per I_T nexus
commit96fc248a4c6fe1e5ffac4903b39d2dd5cbe2dc9a
authorBart Van Assche <bvanassche@acm.org>
Fri, 28 Jun 2013 12:51:26 +0000 (28 14:51 +0200)
committerRoland Dreier <roland@purestorage.com>
Mon, 1 Jul 2013 17:40:07 +0000 (1 10:40 -0700)
tree53f84bcd15b51bfc415f9b74331753eb1850bdeb
parent99e1c1398f44a056b16e78122133988c82b66d97
IB/srp: Maintain a single connection per I_T nexus

An SRP target is required to maintain a single connection between
initiator and target.  This means that if the 'add_target' attribute
is used to create a second connection to a target, the first
connection will be logged out and that the SCSI error handler will
kick in.  The SCSI error handler will cause the SRP initiator to
reconnect, which will cause I/O over the second connection to fail.
Avoid such ping-pong behavior by disabling relogins.

If reconnecting manually is necessary, that is possible by deleting
and recreating an rport via sysfs.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Sebastian Riemer <sebastian.riemer@profitbricks.com>
Acked-by: David Dillow <dillowda@ornl.gov>
Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/infiniband/ulp/srp/ib_srp.c