<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/scsi/libfc, branch v3.6</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/scsi/libfc?h=v3.6</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/scsi/libfc?h=v3.6'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2012-07-20T07:58:56Z</updated>
<entry>
<title>[SCSI] libfc: fix sending REC after FCP_RESP is received</title>
<updated>2012-07-20T07:58:56Z</updated>
<author>
<name>Yi Zou</name>
<email>yi.zou@intel.com</email>
</author>
<published>2012-07-06T17:40:31Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=a752359f2b0a291c5f229e883842e4b30c698387'/>
<id>urn:sha1:a752359f2b0a291c5f229e883842e4b30c698387</id>
<content type='text'>
This is exposed in the case the FCP_DATA frames somehow got lost and fc_fcp got
the FCP_RSP, in fc_fcp_recv_resp(), since xfer_len is less than the expected_len
it resets the the timer to wait to 2 more jiffies in case the data frames are
already queued locally. However, for target does not support REC, it would just
send RJT w/ ELS_RJT_UNSUP. The rec response handler thus only clears the rport
flag for not doing REC later, but does not do fcp_io_complete() on the
associated fsp.

The fix is just check status of FCP_RSP being received already, i.e. using the
FC_SRB_RCV_STATUS flag, in fc_fcp_timeout before start sending REC. We should
have waited long enough if there is truely data frames queued locally.

Signed-off-by: Yi Zou &lt;yi.zou@intel.com&gt;
Tested-by: Ross Brattain &lt;ross.b.brattain@intel.com&gt;
Signed-off-by: Robert Love &lt;robert.w.love@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] libfc: fix retries with FDMI lport states</title>
<updated>2012-07-20T07:58:56Z</updated>
<author>
<name>Vasu Dev</name>
<email>vasu.dev@intel.com</email>
</author>
<published>2012-07-06T17:40:15Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=ac166d2fbd2d0c295454bcee7b3c930cb96e72cc'/>
<id>urn:sha1:ac166d2fbd2d0c295454bcee7b3c930cb96e72cc</id>
<content type='text'>
The FC-GS-3 sepc requires to wait for least 3 times R_A_TOV per
sec 4.6.1 "If the Requesting_CT does not receive a Response
CT_IU from the Responding_CT within three times R_A_TOV,
it shall consider this to be a protocol error."

This means added four new states with management server
could add significant delay with multiple retries
on default 12 second timeout(3 * R_A_TOV), so instead
just skip these states on very first timeout on any of
these states to not stuck with states for such longer
period.

Signed-off-by: Vasu Dev &lt;vasu.dev@intel.com&gt;
Tested-by: Marcus Dennis &lt;marcusx.e.dennis@intel.com&gt;
Signed-off-by: Robert Love &lt;robert.w.love@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] libfc: don't exch_done() on invalid sequence ptr</title>
<updated>2012-07-20T07:58:56Z</updated>
<author>
<name>Yi Zou</name>
<email>yi.zou@intel.com</email>
</author>
<published>2012-07-06T17:40:26Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=db95fc004ea50f661a98c9f25585c0a734b5c238'/>
<id>urn:sha1:db95fc004ea50f661a98c9f25585c0a734b5c238</id>
<content type='text'>
The lport_recv(), i.e., fc_lport_recv_req() may get called w/o the sequence ptr
being set in fr_seq(), particularly in the case of vn2vn mode, this may happen
if the passive fcp provider, e.g., tcm_fc, has not been registered yet.

Signed-off-by: Yi Zou &lt;yi.zou@intel.com&gt;
Tested-by: Ross Brattain &lt;ross.b.brattain@intel.com&gt;
Signed-off-by: Robert Love &lt;robert.w.love@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] libfc: add exch timer debug info</title>
<updated>2012-07-20T07:58:55Z</updated>
<author>
<name>Vasu Dev</name>
<email>vasu.dev@intel.com</email>
</author>
<published>2012-07-06T17:40:10Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=b29a4f309fb58165ebfcca0fba504ae90ec4cfa6'/>
<id>urn:sha1:b29a4f309fb58165ebfcca0fba504ae90ec4cfa6</id>
<content type='text'>
Add exch timeout info to have debug log with exch timeout
value to match with retries, also add debug info
on exch timer cancel.

Added common fc_exch_timer_cancel() func and grouped this
along with fc_exch_timer_set() function, so that
added debug code is not repeated.

Signed-off-by: Vasu Dev &lt;vasu.dev@intel.com&gt;
Signed-off-by: Robert Love &lt;robert.w.love@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] libfc: update fcp and exch stats</title>
<updated>2012-07-20T07:31:48Z</updated>
<author>
<name>Vasu Dev</name>
<email>vasu.dev@intel.com</email>
</author>
<published>2012-05-25T17:26:54Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=4e5fae7adbe4f21538b9e62c0fc9b029bbd606cb'/>
<id>urn:sha1:4e5fae7adbe4f21538b9e62c0fc9b029bbd606cb</id>
<content type='text'>
Updates newly added stats from fc_get_host_stats,
added new function fc_exch_update_stats to
update exches related stats from fc_exch.c
by going thru internal ema_list elements.

Signed-off-by: Vasu Dev &lt;vasu.dev@intel.com&gt;
Acked-by : Robert Love &lt;robert.w.love@intel.com&gt;
Tested-by: Ross Brattain &lt;ross.b.brattain@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] libfc: adds FCP failures stats</title>
<updated>2012-07-20T07:31:48Z</updated>
<author>
<name>Vasu Dev</name>
<email>vasu.dev@intel.com</email>
</author>
<published>2012-05-25T17:26:48Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=0f02a6652803235a4893c7b01dd6eab862a913ec'/>
<id>urn:sha1:0f02a6652803235a4893c7b01dd6eab862a913ec</id>
<content type='text'>
Adds stats to track FCP pkt and frame alloc
failure.

Signed-off-by: Vasu Dev &lt;vasu.dev@intel.com&gt;
Acked-by : Robert Love &lt;robert.w.love@intel.com&gt;
Tested-by: Ross Brattain &lt;ross.b.brattain@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] libfc, fcoe, bnx2fc: cleanup fcoe_dev_stats</title>
<updated>2012-07-20T07:31:47Z</updated>
<author>
<name>Vasu Dev</name>
<email>vasu.dev@intel.com</email>
</author>
<published>2012-05-25T17:26:43Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=1bd49b482077e231842352621169dedff1f41931'/>
<id>urn:sha1:1bd49b482077e231842352621169dedff1f41931</id>
<content type='text'>
The libfc is used by fcoe but fcoe agnostic,
and therefore should not have any fcoe references.

So renaming fcoe_dev_stats from libfc as its for fc_stats.
After that libfc is fcoe string free except some strings for
Open-FCoE.org.

Signed-off-by: Vasu Dev &lt;vasu.dev@intel.com&gt;
Acked-by : Robert Love &lt;robert.w.love@intel.com&gt;
Tested-by: Ross Brattain &lt;ross.b.brattain@intel.com&gt;
Acked-by: Bhanu Prakash Gollapudi &lt;bprakash@broadcom.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'isci-for-3.5' into misc</title>
<updated>2012-05-21T11:17:30Z</updated>
<author>
<name>James Bottomley</name>
<email>JBottomley@Parallels.com</email>
</author>
<published>2012-05-21T11:17:30Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=e34693336564f02b3e2cc09d8b872aef22a154e9'/>
<id>urn:sha1:e34693336564f02b3e2cc09d8b872aef22a154e9</id>
<content type='text'>
isci update for 3.5

1/ Rework remote-node-context (RNC) handling for proper management of
   the silicon state machine in error handling and hot-plug conditions.
   Further details below, suffice to say if the RNC is mismanaged the
   silicon state machines may lock up.

2/ Refactor the initialization code to be reused for suspend/resume support

3/ Miscellaneous bug fixes to address discovery issues and hardware
   compatibility.

RNC rework details from Jeff Skirvin:

In the controller, devices as they appear on a SAS domain (or
direct-attached SATA devices) are represented by memory structures known
as "Remote Node Contexts" (RNCs).  These structures are transferred from
main memory to the controller using a set of register commands; these
commands include setting up the context ("posting"), removing the
context ("invalidating"), and commands to control the scheduling of
commands and connections to that remote device ("suspensions" and
"resumptions").  There is a similar path to control RNC scheduling from
the protocol engine, which interprets the results of command and data
transmission and reception.

In general, the controller chooses among non-suspended RNCs to find one
that has work requiring scheduling the transmission of command and data
frames to a target.  Likewise, when a target tries to return data back
to the initiator, the state of the RNC is used by the controller to
determine how to treat the incoming request. As an example, if the RNC
is in the state "TX/RX Suspended", incoming SSP connection requests from
the target will be rejected by the controller hardware.  When an RNC is
"TX Suspended", it will not be selected by the controller hardware to
start outgoing command or data operations (with certain priority-based
exceptions).

As mentioned above, there are two sources for management of the RNC
states: commands from driver software, and the result of transmission
and reception conditions of commands and data signaled by the controller
hardware.  As an example of the latter, if an outgoing SSP command ends
with a OPEN_REJECT(BAD_DESTINATION) status, the RNC state will
transition to the "TX Suspended" state, and this is signaled by the
controller hardware in the status to the completion of the pending
command as well as signaled in a controller hardware event.  Examples of
the former are included in the patch changelogs.

Driver software is required to suspend the RNC in a "TX/RX Suspended"
condition before any outstanding commands can be terminated.  Failure to
guarantee this can lead to a complete hardware hang condition.  Earlier
versions of the driver software did not guarantee that an RNC was
correctly managed before I/O termination, and so operated in an unsafe
way.

Further, the driver performed unnecessary contortions to preserve the
remote device command state and so was more complicated than it needed
to be.  A simplifying driver assumption is that once an I/O has entered
the error handler path without having completed in the target, the
requirement on the driver is that all use of the sas_task must end.
Beyond that, recovery of operation is dependent on libsas and other
components to reset, rediscover and reconfigure the device before normal
operation can restart.  In the driver, this simplifying assumption meant
that the RNC management could be reduced to entry into the suspended
state, terminating the targeted I/O request, and resuming the RNC as
needed for device-specific management such as an SSP Abort Task or LUN
Reset Management request.
</content>
</entry>
<entry>
<title>[SCSI] libfc: flush lport worker after its disabled</title>
<updated>2012-05-10T07:59:25Z</updated>
<author>
<name>Vasu Dev</name>
<email>vasu.dev@intel.com</email>
</author>
<published>2012-04-20T19:16:32Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=061446a159c5a0ec7047f9979866ffa7e0587b25'/>
<id>urn:sha1:061446a159c5a0ec7047f9979866ffa7e0587b25</id>
<content type='text'>
The lport could get timeout armed while its getting disabled,
so flush lport worker after its disabled and ignore lport
retry in that case instead of WARN_ON.

 [13192.936858] WARNING: at drivers/scsi/libfc/fc_lport.c:1573 fc_lport_timeout+0x53/0xa9 [libfc]()
 [13192.938026] Hardware name: Bochs
 [13192.938620] Modules linked in: fcoe libfcoe libfc scsi_transport_fc scsi_tgt fuse 8021q garp stp llc sunrpc ipv6 uinput microcode joydev pcspkr ixgbe e1000 i2c_piix4 i2c_core virtio_balloon dca mdio virtio_blk virtio_pci virtio_ring virtio floppy [last unloaded: speedstep_lib]
 [13192.942589] Pid: 23605, comm: kworker/0:6 Tainted: G        W    3.2.0+ #71
 [13192.943587] Call Trace:
 [13192.944052]  [&lt;ffffffff810403f4&gt;] warn_slowpath_common+0x85/0x9d
 [13192.944940]  [&lt;ffffffff81040426&gt;] warn_slowpath_null+0x1a/0x1c
 [13192.945734]  [&lt;ffffffffa02746eb&gt;] fc_lport_timeout+0x53/0xa9 [libfc]
 [13192.946665]  [&lt;ffffffff81058d88&gt;] process_one_work+0x20c/0x3ad
 [13192.947541]  [&lt;ffffffff81058cbe&gt;] ? process_one_work+0x142/0x3ad
 [13192.948423]  [&lt;ffffffffa0274698&gt;] ? fc_lport_enter_ns+0x178/0x178 [libfc]
 [13192.949363]  [&lt;ffffffff8105a313&gt;] worker_thread+0xfd/0x181
 [13192.950191]  [&lt;ffffffff8105a216&gt;] ? manage_workers.clone.15+0x173/0x173
 [13192.951100]  [&lt;ffffffff8105e19b&gt;] kthread+0xa4/0xac
 [13192.951755]  [&lt;ffffffff814edbb4&gt;] kernel_thread_helper+0x4/0x10
 [13192.952520]  [&lt;ffffffff814e5cb4&gt;] ? retint_restore_args+0x13/0x13
 [13192.953398]  [&lt;ffffffff8105e0f7&gt;] ? __init_kthread_worker+0x5b/0x5b
 [13192.954278]  [&lt;ffffffff814edbb0&gt;] ? gs_change+0x13/0x13
 [13192.954911] ---[ end trace 9763213b95bbd803 ]---

Signed-off-by: Vasu Dev &lt;vasu.dev@intel.com&gt;
Acked-by: Neil Horman &lt;nhorman@tuxdriver.com&gt;
Tested-by: Ross Brattain &lt;ross.b.brattain@intel.com&gt;
Signed-off-by: Robert Love &lt;robert.w.love@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
<entry>
<title>[SCSI] libfc: update mfs boundry checking</title>
<updated>2012-04-25T07:46:29Z</updated>
<author>
<name>Vasu Dev</name>
<email>vasu.dev@intel.com</email>
</author>
<published>2012-04-06T22:52:51Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=93f90e5186053611fe93d889e99ee2852f4da250'/>
<id>urn:sha1:93f90e5186053611fe93d889e99ee2852f4da250</id>
<content type='text'>
A previous commit changed the mfs checking to ensure the new
mfs is less or equal to the mfs supported by the FCF. This
doesn't work for BRDCM cards as they set an mfs of 2048 regardless
of whether the switch returns a larger mfs.

This patch validates the new mfs against the upper and lower spec
defined boundries for a FCoE mfs.

Signed-off-by: Vasu Dev &lt;vasu.dev@intel.com&gt;
Signed-off-by: Bhanu Prakash Gollapudi &lt;bprakash@broadcom.com&gt;
Signed-off-by: Robert Love &lt;robert.w.love@intel.com&gt;
Signed-off-by: James Bottomley &lt;JBottomley@Parallels.com&gt;
</content>
</entry>
</feed>
