commit 9d7e04f9db64a1df159be21fb6557510f907b877 Author: Mike Christie Date: Wed Nov 11 16:34:36 2009 -0600 [SCSI] libiscsi: hook into ramp up/down handling It is rare to get a queue full with iscsi, because targets seem to just reduce the iscsi cmd window. However, there is at least one iscsi target that will throw a queue full when overloaded. This hooks the iscsi code in to the ramp up/down code, so we can handle it. Signed-off-by: Mike Christie Signed-off-by: James Bottomley commit 6e7c102bdb3098b5b31e4ac8ffd23d08706dc480 Author: Mike Christie Date: Wed Nov 11 16:34:35 2009 -0600 [SCSI] iser: set tgt and lu reset timeout When iser enabled lu reset support it did not set the bit to allow userspace to get/set the timeout. This sets the tgt and lu reset timeout bits. Signed-off-by: Mike Christie Signed-off-by: James Bottomley commit af6fb5ee0714089578b4600dfe7bcb0adefd5e26 Author: Mike Christie Date: Wed Nov 11 16:34:34 2009 -0600 [SCSI] iscsi class: modify handling of replacement timeout This patch modifies the replacement/recovery_timeout so it works more like the fc fast io fail tmo. If userspace tries to set the replacement/recovery_timeout to less than zero, we will turn off the forced recovery cleanup. If userspace sets the value to 0 then we will force the recovery cleanup immediately. Signed-off-by: Mike Christie Signed-off-by: James Bottomley commit ee28e795ac107f0a54b209c6a91fb861e35e6c91 Author: Mike Christie Date: Wed Nov 11 16:34:33 2009 -0600 [SCSI] libiscsi: add warm target reset tmf support This implements warm target reset tmf support for the scsi-ml target reset callback. Previously we would just drop the session in that callback. This patch will now try a target reset and if that fails drop the session. Signed-off-by: Mike Christie Signed-off-by: James Bottomley commit feef68c96d6e0d565c0eaf1237092638cb0c01b1 Author: Mike Christie Date: Wed Nov 11 16:34:32 2009 -0600 [SCSI] libiscsi: Check TMF state before sending PDU Patch and mail from both MikeC and HannesR: Before we're trying to send a PDU we have to check whether a TMF is active. If so and if the PDU will be affected by the TMF we should allow only Data-out PDUs to be sent. If fast_abort is set, no Data-out PDUs will be sent while a LUN reset is being processed for a affected LUN. fast_abort is now ingored during a ABORT TASK tmf. We will not send any Data-outs for a task if the task is being aborted. Signed-off-by: Mike Christie Signed-off-by: Hannes Reinecke Signed-off-by: James Bottomley commit e14e06d480846be2b3ad515fef63ae12d320f033 Author: Mike Christie Date: Wed Nov 11 16:34:31 2009 -0600 [SCSI] libiscsi: fix login/text checks in pdu injection code For some reason we used to check for the the immediate bit set and the opcocde in many places instead of just masking the opcode. In the passthrough code this is a problem because userspace may or may not have set the immediate bit and it does not have to. This fixes up the opcode checks in the passthrough code, so we mask off the opcode then check against the iscsi proto definition like is done in other places. Signed-off-by: Mike Christie Signed-off-by: James Bottomley commit e9f763b4ab2f0cc80a66728998fe7c331ec72f4c Author: Mike Christie Date: Wed Nov 11 16:34:30 2009 -0600 [SCSI] bnx2i: use common iscsi suspend queue This just has bnx2i use the iscsi_suspend_queue helper. The suspend works as follows: When ep_poll has succeeed iscsid will call conn_bind, the LLD will then call iscsi_conn_bind which will clear the suspend bit. When ep_disconnect is called (or if there is a conn error) we set the suspend bit. For the ep_disconnect case I added a helper in the previous kernel that will take the session lock to make sure iscsi_queuecommand/xmit_task is not running and it will set the suspend bit. Signed-off-by: Mike Christie Acked-by: Anil Veerabhadrappa Signed-off-by: James Bottomley commit 045ba557f522234638262b8b4b4c0081f82937a2 Author: Takahiro Yasui Date: Tue Nov 10 16:22:19 2009 -0500 [SCSI] scsi_devinfo: update Hitachi entries (v2) Four models, OPEN-/DF400/DF500/DISK-SUBSYSTEM, can handle REPORT_LUN, and the BLIST_REPORTLUN2 flag needs to be set. And DF600 doesn't require any flags because it returns ANSI 03h (SPC). Signed-off-by: Takahiro Yasui Signed-off-by: James Bottomley commit 46e2596ce698372b6f71b7fc22d2f801c08bb7a6 Author: Mike Christie Date: Thu Nov 5 11:37:28 2009 -0600 [SCSI] add scsi target reset support to scsi ioctl The scsi ioctl code path was missing scsi target reset support. This patch just adds it. Signed-off-by: Mike Christie Signed-off-by: James Bottomley commit 543812eb146ea926108c836e787af3a459d7fea5 Author: Mike Christie Date: Thu Nov 5 11:18:09 2009 -0600 [SCSI] fc class: fail fast bsg requests If the port state is blocked and the fast io fail tmo has fired then this patch will fail bsg requests immediately. This is needed if userspace is sending IOs to test the transport like with fcping, so it will not have to wait for the dev loss tmo. With this patch he bsg req fast io fail code behaves like the normal and sg io/passthrough fast io fail. Signed-off-by: Mike Christie Acked-By: James Smart Signed-off-by: James Bottomley commit d93e341433c668bf63b16b7d09738c5f8d1f950c Author: jack_wang Date: Thu Nov 5 22:33:51 2009 +0800 [SCSI] pm8001: Fixes for tag alloc, error goto and code cleanup Allocate right size for bitmap tag,fix error goto and cleanup print message and undocable commemts. patch attached. Signed-off-by: Lindar Liu Signed-off-by: Jack Wang Signed-off-by: James Bottomley commit dc010cb5669bc11efd1fcf095d0f23d27a73c877 Author: jack_wang Date: Thu Nov 5 22:33:35 2009 +0800 [SCSI] pm8001: enhance IOMB process modules We set interupt cascading count of outbound queue to get better performance, correct some unnecessary return values and some noisy print messages. patch attached. Signed-off-by: Jack Wang Signed-off-by: Lindar Liu Signed-off-by: James Bottomley commit 47cbcc41a7a7de2fb80609ac04e0ab3af782f63c Author: jack_wang Date: Thu Nov 5 22:32:31 2009 +0800 [SCSI] pm8001: add reinitialize SPC parameters before phy start Signed-off-by: Jack Wang Signed-off-by: Lindar Liu Signed-off-by: James Bottomley commit 2cbf595a1dc7c63c8aec257b41cf7631163fae86 Author: James Bottomley Date: Thu Nov 5 13:33:12 2009 -0600 [SCSI] scsi_lib_dma: fix bug with dma maps on nested scsi objects Some of our virtual SCSI hosts don't have a proper bus parent at the top, which can be a problem for doing DMA on them This patch makes the host device cache a pointer to the physical bus device and provides an extra API for setting it (the normal API picks it up from the parent). This patch also modifies the qla2xxx and lpfc vport logic to use the new DMA host setting API. Acked-By: James Smart Cc: Stable Tree Signed-off-by: James Bottomley commit 5b2685343ece70edf7ddb9dec5ee84bf4a64080c Author: Chandra Seetharaman Date: Fri Sep 11 10:20:35 2009 -0700 [SCSI] scsi_dh: create sysfs file, dh_state for all SCSI disk devices Create the sysfs file, dh_state even if the new SCSI device is not in the any of the device handler's internal lists. Signed-Off-by: Chandra Seetharaman Acked-by: Hannes Reinecke Signed-off-by: James Bottomley commit ae412d09fcdcaceb596c16f08edb40c93294713c Author: Roel Kluin Date: Wed Nov 4 00:38:44 2009 +0100 [SCSI] qlogicpti: add missing parentheses `+' has a higher precedence than `?' so the condition always evaluates to true and this is preprocessed to `7*((ql) - 1)' Signed-off-by: Roel Kluin Acked-by: David S. Miller Signed-off-by: James Bottomley commit 1998e37f25c79bc756451c0ed974018edb49e8a9 Author: Joe Eykholt Date: Tue Nov 3 11:50:21 2009 -0800 [SCSI] libfc fcoe: increase ELS and CT timeouts The FC-LS spec. says ELS timeouts should be 2 x R_A_TOV. The FC-GS spec. says CT timeouts should be 3 x R_A_TOV. We've been using E_D_TOV for both of those. Change for all ELS and CT requests except FLOGI, which we leave at 2 seconds (using E_D_TOV). One could argue that R_A_TOV is locally determined until after FLOGI succeeds. This does change FLOGI for vports which becomes FDISC. This does not change the REC/SRR timeout which is 2 seconds. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 1b9acb967d1437d620bf26b39702d7c71122c163 Author: Yi Zou Date: Tue Nov 3 11:50:16 2009 -0800 [SCSI] libfcoe: Do not pad FIP keep-alive to full frame size According to the FC-BB-5 Rev2.0, 7.8.6.2, we should not pad FIP keep-alive frames. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit c13d60402cf1ba54e73704f794ee502589c91b31 Author: Vasu Dev Date: Tue Nov 3 11:50:10 2009 -0800 [SCSI] libfc: fix an issue of pending exch/es after i/f destroyed or rmmod fcoe All exches must be freed before its EM mempool destroyed in this case but currently some exches could be still pending in their scheduled delayed work after EM mempool is destroyed causing this issue discussed and reported in this latest email thread:- http://www.open-fcoe.org/pipermail/devel/2009-October/004788.html This patch fixes this issue by adding dedicated work queue thread fc_exch_workqueue for exch delayed work and then flush this work queue before destroying EM mempool. The cancel_delayed_work_sync cannot be called during final fc_exch_reset due to lport and exch locking ordering, so removes related comment block not relevant any more with this patch. Reported-by: Joe Eykholt Signed-off-by: Vasu Dev Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 35077d075abe7dcb098e42e8fd3b70383ce013c3 Author: Chris Leech Date: Tue Nov 3 11:50:05 2009 -0800 [SCSI] libfc, fcoe: fixes for highmem skb linearize panics There are cases outside of our control that may result in a transmit skb being linearized in dev_queue_xmit. There are a couple of bugs in libfc/fcoe that can result in a panic at that point. This patch contains two fixes to prevent those panics. 1) use fast cloning instead of shared skbs with dev_queue_xmit dev_queue_xmit doen't want shared skbuffs being passed in, and __skb_linearize will BUG if the skb is shared. FCoE is holding an extra reference around the call to dev_queue_xmit, so that when it returns an error code indicating the frame has been dropped it can maintain it's own backlog and retransmit. Switch to using fast skb cloning for this instead. 2) don't append compound pages as > PAGE_SIZE skb fragments fc_fcp_send_data will append pages from a scatterlist to the nr_frags[] if the netdev supports it. But, it's using > PAGE_SIZE compound pages as a single skb_frag. In the highmem linearize case that page will be passed to kmap_atomic to get a mapping to copy out of, but kmap_atomic will only allow access to the first PAGE_SIZE part. The memcpy will keep going and cause a page fault once is crosses the first boundary. If fc_fcp_send_data uses linear buffers from the start, it calls kmap_atomic one PAGE_SIZE at a time. That same logic needs to be applied when setting up skb_frags. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit b915b319142ad217b11cc39223d785deec7d4823 Author: Yi Zou Date: Tue Nov 3 11:49:59 2009 -0800 [SCSI] fcoe: Fix using VLAN ID in creating lport's WWWN/WWPN If the underlying netdev is a VLAN device, make sure the VLAN ID is integrated into the WWNN/WWPN name generation. Also added/updated the comments to reflect this change. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 219bad1f92434bcea1cd7ed721e638fbeb2fe2b5 Author: Mike Christie Date: Tue Nov 3 11:49:54 2009 -0800 [SCSI] libfc: do not use DID_NO_CONNECT for pkt alloc failures. DID_NO_CONNECT is not a nice value to use for pkt alloc failures, because you can probably retry and IO will become available again. For the device reset callout, we do not want to set the scsi command result for the above reason, and because we do not need to set the scsi_cmd->result in this path. We and other drivers do not set it for success for example, and we do not set it for other failure. And scsi-ml does not send every command through this path, and it is not expecting us to use the scsi_cmnd struct like a cmd coming thruogh queuecommand. I think it is more for storage in case we need a cmd struct for a tmf and to give us certain params like the LUN. Patch was made over scsi-misc today. Signed-off-by: Mike Christie Signed-off-by: Robert Love Signed-off-by: James Bottomley commit b2a28fbdbb00929555071acf62a87c4ba5dfa04b Author: Yi Zou Date: Tue Nov 3 11:49:49 2009 -0800 [SCSI] fcoe: Fix setting lport's WWNN/WWPN to use san mac address We are still using netdev->dev_addr to generate lport's WWNN/WWPN even if the LLD has support for NETDEV_HW_ADDR_T_SAN. Instead, we should just use the fip->ctl_src_addr, which is the NETDEV_HW_ADDR_T_SAN if LLD supports it or it is just the netdev->dev_addr if it does not. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit e116dee847d36d321f4f89eab6a0b42494159a39 Author: Yi Zou Date: Tue Nov 3 11:49:43 2009 -0800 [SCSI] fcoe: Fix getting san mac for VLAN interface Make sure we are get the SAN MAC address from the real netdev if the input netdev is a VLAN device. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit b7df6c472daae30e9539d6eb3dfcad8145720375 Author: Yi Zou Date: Tue Nov 3 11:49:38 2009 -0800 [SCSI] fcoe: Fix checking san mac address This was fixed before in 7a7f0c7 but it's introduced again recently. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 7f93cf09d12e01c59f8e12b66e320dc36e1abe0d Author: Joe Eykholt Date: Tue Nov 3 11:49:32 2009 -0800 [SCSI] fnic: enable bsg pass-thru for fcping Add initialization of .bsg_request in the scsi_transport_fc template so that fcping works. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 78f1b6ead34cfe7d4ce81dbd1178309296c914f0 Author: Joe Eykholt Date: Tue Nov 3 11:49:27 2009 -0800 [SCSI] libfc: register FC4 features with the FC switch Customers and certification tests have pointed out that we don't show up on the switch management software as an initiator. On some MDS switches 'show fcns database' command shows libfc initiators as 'fcp' not 'fcp:init' like other initiators. On others switches, I think the switch gets the features by doing a PRLI, but it may be only certain models or under certain configurations. Fix this by registering our FC4 features with the RFF_ID CT request after local port login and after the RFT_ID. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 093f984eca1b5c9cfc8b1491e53e6ae4b84e7674 Author: Joe Eykholt Date: Tue Nov 3 11:49:22 2009 -0800 [SCSI] fnic: Add FIP support to the fnic driver Use libfcoe as a common FIP implementation with fcoe. FIP or non-FIP mode is fully automatic if the firmware supports and enables it. Even if FIP is not supported, this uses libfcoe for the non-FIP handling of FLOGI and its response. Use the new lport_set_port_id() notification to capture successful FLOGI responses and port_id resets. While transitioning between Ethernet and FC mode, all rx and tx FC frames are queued. In Ethernet mode, all frames are passed to the exchange manager to capture FLOGI responses. Change to set data_src_addr to the ctl_src_addr whenever it would have previously been zero because we're not logged in. This seems safer so we'll never send a frame with a 0 source MAC. This also eliminates a special case for sending FLOGI frames. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit d993800d5f4ec62d22a876860111e409eb3b84b8 Author: Joe Eykholt Date: Tue Nov 3 11:49:16 2009 -0800 [SCSI] libfcoe: fcoe: simplify receive FLOGI response There was a locking problem where the fip->lock was held during the call to update_mac(). The rtnl_lock() must be taken before the fip->lock, not the other way around. This fixes that. Now that fcoe_ctlr_recv_flog() is called only from the response handler to a FLOGI request, some checking can be eliminated. Instead of calling update_mac(), just fill in the granted_mac address for the passed-in frame (skb). Eliminate the passed-in source MAC address since it is also in the skb. Also, in fcoe, call fcoe_set_src_mac() directly instead of going thru the fip function pointer. This will generate less code. Then, since fip isn't needed for LOGO response, use lport as the arg. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 903251d6d99f2fcb51d733a9322a9c367563af78 Author: Joe Eykholt Date: Tue Nov 3 11:49:11 2009 -0800 [SCSI] libfc: add host number to lport link up/down messages. The libfc link up/down messages don't indicate which port is changing. The Port ID will often be 0. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit df8bb9f4e4e35c11dea51f879cd8467698a14fb8 Author: Joe Eykholt Date: Tue Nov 3 11:49:05 2009 -0800 [SCSI] libfc: add set_fid function to libfc template This is to notify the LLD when an FC_ID is assigned to the local port. The fnic driver needs to push the assigned FC_ID to firmware. It currently does this by intercepting the FLOGI responses, and in order to make that code more common with FIP and NPIV, it makes more sense to wait until the local port has completely handled the FLOGI or FDISC response. Also, when we fix point-to-point FC_ID assignment, we'll need this callback as well. Add a call to the libfc template, which is called whenever the local port FC_ID is being assigned. It defaults to fc_lport_set_fid(), supplied by libfc. As additional benefit of this function, the LLD may determine the MAC address that caused the change by looking at the received frame. We also print the assigned port ID as long as it isn't 0. Setting port ID to 0 happens often in reset while retrying FLOGI, and would be uninteresting. This replaces the previous message which didn't identify the host adapter instance. patch v2 note: changed one word in a comment. "intercepted" -> "provided". Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 413247a8dc8f79f8f05ae8807167d667c1620a9c Author: Joe Eykholt Date: Tue Nov 3 11:49:00 2009 -0800 [SCSI] libfc: fix fc_els_resp_type to correct display of CT responses Local port debug messages were using fc_els_resp_type() which showed all CT responses as rejects. Handle CT responses correctly based by inspecting fh_type. I decided not to rename the function to keep the patch smaller. We could call it just fc_resp_type() or fc_elsct_resp_type(). Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 390588c4ae9ab5700c93271ed79357b74f327f00 Author: Joe Eykholt Date: Tue Nov 3 11:48:55 2009 -0800 [SCSI] libfc: fix symbolic name registrations smashing skb data The strncpy for RSPN_ID and RSNN_NN requests was padding past the allocated frame size. Get the string length before filling in the ct header. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 8d26af70fb4e828fbb60bc00803c32299c38b183 Author: Joe Eykholt Date: Tue Nov 3 11:48:50 2009 -0800 [SCSI] libfc: fix RNN_ID smashing skb payload The code that filled in the name server RNN_ID (register node name) request had somehow gotten a line in it from the RFT_ID code which copies 32 bytes of data over the relatively short payload. This caused some corruption and hangs. Simply deleted the extraneous line. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 5e2f8c00a883ca3c384169cd1aeb8c064113d76b Author: john fastabend Date: Tue Nov 3 11:48:44 2009 -0800 [SCSI] fcoe: add check to fail gracefully in bonding mode This patch adds a check to fail gracefully when the netdevice is bonded. Previously, the error was detected but the stack would continue to load. This resulted in a partially enabled fcoe intance and errors when the fcoe instance was destroy. Signed-off-by: John Fastabend Signed-off-by: Robert Love Signed-off-by: James Bottomley commit e336a004bdc8f782204d15c1611e9889c1d99868 Author: Yi Zou Date: Tue Nov 3 11:48:39 2009 -0800 [SCSI] fcoe: remove extra function decalrations Remove the two extra function decalartions in fcoe.c. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 41b8bc609486e649bff9b68b35d006bcf5b48f4a Author: Joe Eykholt Date: Tue Nov 3 11:48:32 2009 -0800 [SCSI] libfcoe: don't send ELS in FIP mode if no FCF selected If link is up, but no FCF is selected, don't send any ELS frames. This came up when an fnic received a multicast advertisement but no solitited advertisments, so no FCF was selected. It tried to send FLOGIs anyway. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 6b4e420da5ed6702251a252e270e089cead39978 Author: Joe Eykholt Date: Tue Nov 3 11:48:27 2009 -0800 [SCSI] libfcoe: FIP should report link to libfc whether selected or not The fnic driver with FIP is reporting link up, even though it's down. When the interface is shut down by the switch, we receive a clear virtual link, and set the state reported to libfc as down, although we still report it up. Clearly wrong. That causes the subsequent link down event not to be reported, and /sys shows the host "Online". Currently, in FIP mode, if an FCF times out, then link to libfc is reported as down, to stop FLOGIs. That interferes with the LLD link down being reported. Users really need to know the physical link information, to diagnose cabling issues, so physical link status should be reported to libfc. If the selected FCF needs to be reported, that should be done separately, in a later patch. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit d11f16cba15ee111c02023de9abbffe4b82157e3 Author: Joe Eykholt Date: Tue Nov 3 11:48:22 2009 -0800 [SCSI] libfcoe: fip: allow FIP receive to be called from IRQ. FIP's fcoe_ctlr_recv() function was previously only called from the soft IRQ in FCoE. It's not performance critical and is more convenient for some drivers to call it from the IRQ level. Just Change to use skb_queue()/dequeue() which uses spinlock_irqsave instead of separate locking with _bh locks. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 264f34fb71c4b02bdb3faac5a224b567a24de03b Author: Joe Eykholt Date: Tue Nov 3 11:48:16 2009 -0800 [SCSI] libfcoe: fip: use SCSI host number to identify debug messages. Use scsi host number to identify debug messages. Previously, no instance information was given, so if multiple ports were active, it became confusing. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 654fc22235cc8f4329ef2721509eea7278bbba08 Author: Joe Eykholt Date: Tue Nov 3 11:48:11 2009 -0800 [SCSI] libfcoe: Allow FIP to be disabled by the driver Allow FIP to be disabled by the driver for devices that want to use libfcoe in non-FIP mode. The driver merely sets the fcoe_ctlr mode to the state which should be entered when the link comes up. The default is auto. No change is needed for fcoe.c which uses auto mode. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit aa56995fb3bb92d79b13a17082bed903ebf0a34c Author: Vasu Dev Date: Tue Nov 3 11:48:06 2009 -0800 [SCSI] libfc: adds can_queue ramp up Adds last_can_queue_ramp_down_time and updates this on every ramp down. If last_can_queue_ramp_down_time is not zero then do ramp up on any IO completion in added fc_fcp_can_queue_ramp_up. Reset last_can_queue_ramp_down_time to zero once can_queue is ramped up to added max_can_queue limit, this is to avoid any more ramp up attempts on subsequent IO completion. The ramp down and up are skipped for FC_CAN_QUEUE_PERIOD to avoid infrequent changes to can_queue, this required keeping track of ramp up time also in last_can_queue_ramp_up_time. Adds code to ramp down can_queue if lp->qfull is set, with added new ramp up code the can_queue will be increased after FC_CAN_QUEUE_PERIOD, therefore it is safe to do ramp down without fsp in this case and will avoid thrash. This required fc_fcp_can_queue_ramp_down locking change so that it can be called with Scsi_Host lock held. Removes si->throttled and fsp state FC_SRB_NOMEM, not needed with added ramp up code. Signed-off-by: Vasu Dev Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 00f135b18e1725a678ea70b94e6b1d6d4573562b Author: Vasu Dev Date: Tue Nov 3 11:48:00 2009 -0800 [SCSI] libfc: reduce can_queue for all FCP frame allocation failures Currently can_queue is reduced only if frame alloc fails during fc_fcp_send_data but frame alloc can fail at several other places in FCP data path and can_queue needs to be reduced for any FCP frame alloc failure. This patch adds fc_fcp_frame_alloc for all FCP frame allocations and if fc_frame_alloc fails in fc_fcp_frame_alloc then reduce can_queue in fc_fcp_frame_alloc, this will reduce can_queue for all FCP frame alloc failures. This required moving fc_fcp_reduce_can_queue up, to build without adding its prototype. Also renamed fc_fcp_reduce_can_queue to fc_fcp_can_queue_ramp_down. Removes fc_fcp_reduce_can_queue calling from fc_fcp_recv since not needed with added fc_fcp_frame_alloc reducing can_queue. Signed-off-by: Vasu Dev Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 68f96ff45fcfcdc01c8aea8ffd07aec80bc68ae7 Author: Vasu Dev Date: Tue Nov 3 11:47:55 2009 -0800 [SCSI] fcoe, libfc: use single frame allocation API Cleans up frame allocation APIs to have just single fc_frame_alloc API. Removes _fc_frame_alloc, renames __fc_frame_alloc to _fc_frame_alloc. Modifies fc_fcp_send_data for removed _fc_frame_alloc, fc_fcp_send_data was the only user of removed _fc_frame_alloc. Also Adds check in fc_frame_alloc to do mod by 4 for only non-zero len value. This patch is prep work to fix can_queue reducing in next patch. Single fc_frame_alloc API helps in fixing can_queue reducing in next patch. Signed-off-by: Vasu Dev Signed-off-by: Robert Love Signed-off-by: James Bottomley commit a352ca463d24d9efae1a99bf13970f59cc9b7751 Author: Robert Love Date: Tue Nov 3 11:47:50 2009 -0800 [SCSI] fcoe: Formatting cleanups and commenting Added kernel-doc comment blocks to all structures and functions. Renamed fc_lport instances rom lp to lport to be inline with our naming convention. Renamed all misnamed net_device instances to netdev to be inline with our naming convention. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 0f5986c62fc6ec9601a113a8e62c5dfc0f646f01 Author: Robert Love Date: Tue Nov 3 11:47:45 2009 -0800 [SCSI] libfcoe: formatting and comment cleanups Ensures that there are kernel-doc style comments for all routines and structures. There were also a few instances of fc_lport's named 'lp' which were switched to 'lport' as per the libfc/libfcoe/fcoe naming convention. Also, emacs 'indent-region' and 'tabify' were ran on libfcoe.c. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit ae3cc717e6e06a91c97c6170a29213ca35c55aef Author: Robert Love Date: Tue Nov 3 11:47:39 2009 -0800 [SCSI] libfc: Formatting cleanups across libfc This patch makes a variety of cleanup changes to all libfc files. This patch adds kernel-doc headers to all functions lacking them and attempts to better format existing headers. It also add kernel-doc headers to structures. This patch ensures that the current naming conventions for local ports, remote ports and remote port private data is upheld in the following manner. struct instance (i.e. variable name) -------------------------------------------------- fc_lport lport fc_rport rport fc_rport_libfc_priv rpriv fc_rport_priv rdata I also renamed dns_rp and ptp_rp to dns_rdata and ptp_rdata respectively. I used emacs 'indent-region' and 'tabify' on all libfc files to correct spacing alignments. I feel sorry for anyone attempting to review this patch. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit ea9609d52b3db87a91b1ebf534f144b7531f79ad Author: Steve Ma Date: Tue Nov 3 11:47:34 2009 -0800 [SCSI] libfc, fcoe: Add FC passthrough support This is the Open-FCoE implementation of the FC passthrough support via bsg interface. Passthrough support is added to both N_Ports and VN_Ports. Signed-off-by: Steve Ma Signed-off-by: Robert Love Signed-off-by: James Bottomley commit a6c7722ec9046fe97b28c207ec5db6f0a96eb28e Author: Robert Love Date: Tue Nov 3 11:47:28 2009 -0800 [SCSI] libfc: Add routine to copy data from a buffer to a SG list When handling the multi-frame responses of fc pass-thru requests, a code segment similar to fc_fcp_recv_data (routine to receive inbound SCSI data) is used in the response handler. This patch is to add a routine, called fc_copy_buffer_to_sglist(), to handle the common function of copying data from a buffer to a scatter- gather list in order to avoid code duplication. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 55b46badeae3109945d2ac1a096257370d69ccc4 Author: Robert Love Date: Tue Nov 3 11:47:23 2009 -0800 [SCSI] libfc: Export FC headers Export fc_els.h, fc_fs.h, fc_gs.h and fc_ns.h so that they may be used by applications. This will be needed for FC Passthrough applications like fcping, but could be used by other applications. Fix to include to exported files provided by Chris Leech . Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 314cf1448e69b8740a754a406333038957c7681e Author: Chris Leech Date: Tue Nov 3 11:47:18 2009 -0800 [SCSI] fcoe: vport symbolic name support Allow a vport specific string to be appended to the port symbolic name. The new symbolic name is sent to the name server after it is set. This currently messes with libhbalinux, which is looking for the fcoe "fcoe over " string and expects whatever comes after the "over" to be a network interface name only. Adds an EXPORT_SYMBOL to libfc for fc_frame_alloc_fill, which is needed to allow fcoe to allocate a frame of variable length for the RSPN request. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 7bfeaf73dcbf97c138ad71433425ad580aa836bc Author: Chris Leech Date: Tue Nov 3 11:47:12 2009 -0800 [SCSI] libfc: combine name server registration request functions Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 14c0f0ac2b3d7265dcd4a7675d70b2801af73ae9 Author: Chris Leech Date: Tue Nov 3 11:47:07 2009 -0800 [SCSI] libfc: combine name server registration response handlers They all do the same thing, so combine them into a single function. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit dd26f69ebf2a8a5c72914ef8d2bc953fe79599d4 Author: Chris Leech Date: Tue Nov 3 11:47:01 2009 -0800 [SCSI] libfc: Register Symbolic Port Name (RSPN_ID) Register the fc_host symbolic name as the symbolic port name with the fabric name server. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 60e7c7e129e253b4923416d1b5b239e4e6836fc8 Author: Chris Leech Date: Tue Nov 3 11:46:56 2009 -0800 [SCSI] libfc: Register Symbolic Node Name (RSNN_NN) Register the fc_host symbolic name as the symbolic node name with the fabric name server. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit c9c4730119f3025b4c2d475f9a3cc5db729e4bfc Author: Chris Leech Date: Tue Nov 3 11:46:51 2009 -0800 [SCSI] libfc: RNN_ID may be required before RSNN_NN with some switches One could interpret FC-GS-5 to say that an explicit RNN_ID is required before RSNN_NN is allowed to succeed, which is why RNN_ID was not obsoleted along with RPN_ID acording to this document: ftp://ftp.t11.org/t11/member/fc/gs-5/05-546v2.pdf Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 8f2197797da031011628cc90726c0f339f1b3020 Author: Chris Leech Date: Tue Nov 3 11:46:46 2009 -0800 [SCSI] libfc: RPN_ID is obsolete and unnecessary RPN_ID has been obsolete per FC-GS-5 for several years. The port name is registered implicitly as part of FLOGI, and it is undesirable for ports to change a registered port name using RPN_ID while logged into the fabric. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 2fd0479d4c7b682e7b19a5f0bdc8d6416f1e2044 Author: Chris Leech Date: Tue Nov 3 11:46:40 2009 -0800 [SCSI] fcoe: NPIV vport create/destroy Add NPIV vport create and destroy handlers and register them with the FC transport. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 7e259730b655fec98971402bd3f088e8003ed144 Author: Chris Leech Date: Tue Nov 3 11:46:34 2009 -0800 [SCSI] fcoe: add a separate scsi transport template for NPIV vports Right now it's exactly the same as the physical port template, and there is no way to create a port on anything other than the netdev. When the vport_create entry point gets hooked up it will create lports on top of vport devices, which will use this. Rename scsi_transport_fcoe_sw to fcoe_transport_template to be more clear with naming now that there are two templates. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 3a721ab21b0192c5d99f079fbed8f5670a3a7380 Author: Chris Leech Date: Tue Nov 3 11:46:29 2009 -0800 [SCSI] libfcoe, fcoe: libfcoe NPIV support The FIP code in libfcoe needed several changes to support NPIV 1) dst_src_addr needs to be managed per-n_port-ID for FPMA fabrics with NPIV enabled. Managing the MAC address is now handled in fcoe, with some slight changes to update_mac() and a new get_src_addr() function pointer. 2) The libfc elsct_send() hook is used to setup FCoE specific response handlers for FIP encapsulated ELS exchanges. This lets the FCoE specific handling know which VN_Port the exchange is for, and doesn't require tracking OX_IDs. It might be possible to roll back to the full FIP frame in these, but for now I've just stashed the contents of the MAC address descriptor in the skb context block for later use. Also, because fcoe_elsct_send() just passes control on to fc_elsct_send(), all transmits still come through the normal frame_send() path. 3) The NPIV changes added a mutex hold in the keep alive sending, the lport mutex is protecting the vport list. We can't take a mutex from a timer, so move the FIP keep alive logic to the link work struct. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit a69b0f6532425d884a5ac8022d081325b0c11213 Author: Chris Leech Date: Tue Nov 3 11:46:24 2009 -0800 [SCSI] libfc, libfcoe: FDISC ELS for NPIV Add FDISC ELS handling to libfc and libfcoe, treat it the same as FLOGI where appropriate. Add checking for NPIV support in the FLOGI LS_ACC service parameters. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit af2cef96f7e28af79d537f68f20af58e45e79172 Author: Chris Leech Date: Tue Nov 3 11:46:19 2009 -0800 [SCSI] libfc: vport link handling and fc_vport state managment NPIV vports are managed in libfc by changing their virtual link state when the parent N_Ports internal state changes. The vport link is only online when the N_Port is in a ready state (logged into the fabric). vport_state is updated as needed in this patch as well, currently the states LINKDOWN, INITIALIZING, ACTIVE, DSIABLED, and NO_FABRIC_SUPP are used. This also changes the fc_host port_state handling to differentiate between LINKDOWN and OFFLINE. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit e33738af5faaffcc00283433a54833b1414be65d Author: Chris Leech Date: Tue Nov 3 11:46:14 2009 -0800 [SCSI] libfc: add some generic NPIV support routines to libfc Adds a function to create a new VN_Port instances, which share the EM list with the N_Port, VN_Port lookup by fabric ID when responding to a new request (otherwise the exchange lookup from the N_Ports EM list is trusted to return an exchange with a cached lport value for the correct VN_Port), a pointer to a fc_vport structure for VN_Ports, and flags to indicate if an N_Port supports NPIV and if the switch/fabric allows it. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit db27033865550e186ed867debf678a22afa2f32d Author: Chris Leech Date: Tue Nov 3 11:46:08 2009 -0800 [SCSI] libfc: changes to libfc_host_alloc to consolidate initialization with allocation I'd like to keep basic initialization together with allocation, which means this can't just be a tail-call to scsi_host_alloc. This is needed to create a generic libfc host allocation routine for NPIV VN_Ports, which will share the exchange ID space (through sharing exchange manager structures) with the parent lport. In order to clone the exchange manager list when the lport is allocated, the list head must be initialized earlier. Also, update fnic to use the libfc_host_alloc so that later changes do not break it. (contribution by Joe Eykholt) Signed-off-by: Chris Leech Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 26bb9a7799b0fd698ef60ecfe4705e38708b98ae Author: Robert Love Date: Tue Nov 3 11:46:03 2009 -0800 [SCSI] libfc: Move libfc_init and libfc_exit to fc_libfc.c These routines are for the libfc kernel module and should be in the libfc .c file. Moving the libfc __init routine into fc_libfc.c caused the creation of the fc_setup_fcp() and fc_destroy_fcp() routines so that scsi_pkt_cachep was not exposed outside of fc_fcp.c. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 6e45cd4e5e8e17ffb3e47ae553331a3ec3dcb696 Author: Robert Love Date: Tue Nov 3 11:45:58 2009 -0800 [SCSI] libfc: Add libfc/fc_libfc.[ch] for libfc internal routines include/scsi/libfc.h is currently loaded with common code shared between libfc's sub-modules as well as shared between libfc and fcoe. Previous patches attempted to move out non-common code. This patch creates two files for common libfc routines that will not be shared with fcoe, fnic or any other LLDs. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit a69bf4982baaa8467396a0f4fa24a3972e0565b5 Author: Robert Love Date: Tue Nov 3 11:45:52 2009 -0800 [SCSI] libfc: Remove fc_fcp_complete This function is never used, let's remove it. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit a01718bbc7856dea6b96aacbc87dccb49d20aded Author: Robert Love Date: Tue Nov 3 11:45:47 2009 -0800 [SCSI] libfc: Move non-common routines and prototypes out of libfc.h This patch moves all non-common routines and function prototypes out of libfc.h and into the appropriate .c files. It makes these routines 'static' when necessary and removes any unnecessary EXPORT_SYMBOL statements. A result of moving the fc_exch_seq_send, fc_seq_els_rsp_send, fc_exch_alloc and fc_seq_start_next prototypes out of libfc.h is that they were no longer being imported into fc_exch.c when libfc.h was included. This caused errors where routines in fc_exch.c were looking for undefined symbols. To fix this this patch reorganizes fc_seq_alloc, fc_seq_start_next and fc_seq_start_next_locked. This move also made it so that fc_seq_start_next_locked did not need to be prototyped at the top of fc_exch.c. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit ec70435914b2cba0dfbfe218e4a8602b233febcb Author: Robert Love Date: Tue Nov 3 11:45:42 2009 -0800 [SCSI] fcoe: Increase FCOE_MAX_LUN to 0xFFFF (65535) The maximum number of LUNs was far too low. This value is what most other FC HBAs are using. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit f513a17c80b391901e235b124607ce07b9e48a8d Author: Abhijeet Joglekar Date: Tue Nov 3 11:45:37 2009 -0800 [SCSI] fnic: Allocate OS interrupt resources just before enabling interrupts The OS interrupt vectors were getting allocated before the interrupt resources were mapped from hardware. For Legacy interrupts, since they are shared with other devices, as soon as an interrupt is registered with the OS, it can fire while the fnic isr resource is still unmapped. This can cause crash because of access to unmapped resources. For MSIX and MSI, since interrupts are not shared with other devices, this problem didnt happen, because the interrupt is enabled as the last step before returning from _probe. For Legacy however, since the interrupt is shared, the handler can be called as soon as it is registered. Solution is to register interrupt handlers with OS as last step before enabling device interrupts. Signed-off-by: Abhijeet Joglekar Signed-off-by: Robert Love Signed-off-by: James Bottomley commit d0148dc708c774a0b5631c8d47c4ceb758634d10 Author: Christof Schmitt Date: Fri Oct 30 17:59:29 2009 +0100 [SCSI] scsi_transport_fc: Introduce helper function for blocking scsi_eh Move the duplicated code from FC LLDs to SCSI FC transport class. Acked-by: James Smart Acked-by: Giridhar Malavali Acked-by: Abhijeet Joglekar Signed-off-by: Christof Schmitt Signed-off-by: James Bottomley commit af604381d1aed5a653a373e664d7bc43e1fe4160 Author: Jiri Slaby Date: Wed Sep 23 16:15:35 2009 +0200 [SCSI] scsi_lib: fix potential NULL dereference Stanse found a potential NULL dereference in scsi_kill_request. Instead of triggering BUG() in 'if (unlikely(cmd == NULL))' branch, the kernel will Oops earlier on cmd dereference. Move the dereferences after the if. Signed-off-by: Jiri Slaby Signed-off-by: James Bottomley commit 5009bd4466b709bfcfe690d20dac08cf2c0c5c4f Author: adam radford Date: Fri Oct 23 14:52:33 2009 -0700 [SCSI] 3w-sas: Add new driver for LSI 3ware 9750 [jejb: fix up for new queue depth code] Signed-off-by: Adam Radford Signed-off-by: James Bottomley commit ef94667f7bbefd9c100fbbbd28cab12f258d4394 Author: Douglas Gilbert Date: Thu Oct 29 01:48:31 2009 -0400 [SCSI] scsi_debug: fix Thin provisioning support While testing scsi_debug with these patches I found a problem with the Block Limits VPD page function. The length returned by the inquiry_evpd_b0() function was too short. A patch to fix that and a cosmetic change (that the form factor of scsi_debug is less than 1.8 inches) is attached. Signed-off-by: Douglas Gilbert Signed-off-by: James Bottomley commit 8ffa03d9584e440816ef642ca4e44b3c377da9fe Author: Alok Kataria Date: Tue Oct 13 14:51:05 2009 -0700 [SCSI] vmw_pvscsi: SCSI driver for VMware's virtual HBA. This is a driver for VMware's paravirtualized SCSI device, which should improve disk performance for guests running under control of VMware hypervisors that support such devices. Signed-off-by: Alok N Kataria Signed-off-by: James Bottomley commit c52e582665993a3d568996e37dabc65cc1990136 Author: Chandra Seetharaman Date: Wed Oct 21 09:23:04 2009 -0700 [SCSI] scsi_dh: Make alua hardware handler's activate() async Make the activate function asynchronous by using blk_execute_rq_nowait() Signed-off-by: Chandra Seetharaman Signed-off-by: James Bottomley commit aaf35a139c80424db5c910ace96a53720e2da8d7 Author: Chandra Seetharaman Date: Wed Oct 21 09:22:58 2009 -0700 [SCSI] scsi_dh: Make hp hardware handler's activate() async Make the activate function asynchronous by using blk_execute_rq_nowait() Signed-off-by: Chandra Seetharaman Signed-off-by: James Bottomley commit 87f5f7800a3477b20c2a7760d5a150da572424d3 Author: Chandra Seetharaman Date: Wed Oct 21 09:22:51 2009 -0700 [SCSI] scsi_dh: Make rdac hardware handler's activate() async Batch up MODE_SELECT in rdac device handler. LSI RDAC storage has the capability of handling mode selects for multiple luns in a same command. Make use of that ability to send as few MODE SELECTs as possible to the storage controller as possible. This patch creates a work queue and queues up activate requests when a MODE SELECT is sent down the wire. When that MODE SELECT completes, it compiles queued up activate requests for multiple luns into a single MODE SELECT. This reduces the time to do failover/failback of large number of LUNS. Signed-off-by: Babu Moger Signed-off-by: Chandra Seetharaman Signed-off-by: James Bottomley commit d1c55de2d73e9cdc7b4839bf3b3dc2ca8c146605 Author: Chandra Seetharaman Date: Wed Oct 21 09:22:46 2009 -0700 [SCSI] scsi_dh: Change the scsidh_activate interface to be asynchronous Make scsi_dh_activate() function asynchronous, by taking in two additional parameters, one is the callback function and the other is the data to call the callback function with. Signed-off-by: Chandra Seetharaman Signed-off-by: James Bottomley commit 08d33e3de4d27f820724a12059360289fdd290d7 Author: Christof Schmitt Date: Thu Oct 15 17:47:11 2009 -0700 [SCSI] zfcp: Adapt change_queue_depth for queue full tracking Adapt the change_queue_depth callback in zfcp for the new reason parameter. Simply pass each call back to the SCSI midlayer, there are no resource adjustments necessary for zfcp. Signed-off-by: Christof Schmitt Removes check for (depth <= default_depth) in case of SCSI_QDEPTH_RAMP_UP call back, not needed after added max_queue_depth per sdev. Signed-off-by: Vasu Dev Signed-off-by: James Bottomley commit a19d788b120b9af18417db839e530a01c9908116 Author: Vasu Dev Date: Thu Oct 15 17:47:06 2009 -0700 [SCSI] libfc: add queue_depth ramp up Adjust queue_depth on fc_change_queue_depth call back with reason SCSI_QDEPTH_RAMP_UP, no additional resource adjustments necessary for libfc. Signed-off-by: Vasu Dev Acked-by: Robert Love Signed-off-by: James Bottomley commit 4bf73c617e7078743a728767e2ed4e99a2f1b471 Author: Vasu Dev Date: Thu Oct 22 15:46:33 2009 -0700 [SCSI] add queue_depth ramp up code Current FC HBA queue_depth ramp up code depends on last queue full time. The sdev already has last_queue_full_time field to track last queue full time but stored value is truncated by last four bits. So this patch updates last_queue_full_time without truncating last 4 bits to store full value and then updates its only current usages in scsi_track_queue_full to ignore last four bits to keep current usages same while also use this field in added ramp up code. Adds scsi_handle_queue_ramp_up to ramp up queue_depth on successful completion of IO. The scsi_handle_queue_ramp_up will do ramp up on all luns of a target, just same as ramp down done on all luns on a target. The ramp up is skipped in case the change_queue_depth is not supported by LLD or already reached to added max_queue_depth. Updates added max_queue_depth on every new update to default queue_depth value. The ramp up is also skipped if lapsed time since either last queue ramp up or down is less than LLD specified queue_ramp_up_period. Adds queue_ramp_up_period to sysfs but only if change_queue_depth is supported since ramp up and queue_ramp_up_period is needed only in case change_queue_depth is supported first. Initializes queue_ramp_up_period to 120HZ jiffies as initial default value, it is same as used in existing lpfc and qla2xxx. -v2 Combined all ramp code into this single patch. -v3 Moves max_queue_depth initialization after slave_configure is called from after slave_alloc calling done. Also adjusted max_queue_depth check to skip ramp up if current queue_depth is >= max_queue_depth. -v4 Changes sdev->queue_ramp_up_period unit to ms when using sysfs i/f to store or show its value. Signed-off-by: Vasu Dev Tested-by: Christof Schmitt Tested-by: Giridhar Malavali Signed-off-by: James Bottomley commit 25c8edbdb3be4b0b42c06544b35f3c4744e10502 Author: Vasu Dev Date: Thu Oct 15 17:46:55 2009 -0700 [SCSI] fcoe, libfc: fix an libfc issue with queue ramp down in libfc The cmd_per_lun value is used by scsi-ml as fall back lowest queue_depth value but in case of libfc cmd_per_lun is set to same value as max queue_depth = 32. So this patch reduces cmd_per_lun value to 3 and configures each lun with default max queue_depth 32 in fc_slave_alloc. Signed-off-by: Vasu Dev Acked-by: Robert Love Signed-off-by: James Bottomley commit 239f19d5f3e715de83ccf5ed2d83f9143443582c Author: Mike Christie Date: Thu Oct 15 17:46:50 2009 -0700 [SCSI] libfc: convert to scsi_track_queue_full This converts the libfc using scsi_track_queue_full to track the queue full from the change_queue_depth callback. Signed-off-by: Mike Christie Signed-off-by: Vasu Dev Acked-by: Robert Love Signed-off-by: James Bottomley commit ae446b446a9905dbbf434850bbce0ca8651c1ac1 Author: Mike Christie Date: Thu Oct 15 17:46:44 2009 -0700 [SCSI] scsi error: have scsi-ml call change_queue_depth to handle QUEUE_FULL This has scsi-ml call the change_queue_depth functions when we get a QUEUE_FULL. It will only change the queue depth if change_queue_depth is set because the LLD may have to modify some internal resources, so I thought this would be the safest route. Signed-off-by: Mike Christie -v2 Limits change_queue_depth to only all luns of target by adding channel check while iterating for all luns of Scsi_Host. This is same as currently qla2xxx FC HBA does on QUEUE_FULL event. Signed-off-by: Vasu Dev Signed-off-by: James Bottomley commit d544d3979b2df2c23c0fb653fff12d5c90a765f2 Author: Mike Christie Date: Thu Oct 15 17:46:39 2009 -0700 [SCSI] modify change_queue_depth to take in reason why it is being called This patch modifies scsi_host_template->change_queue_depth so that it takes an argument indicating why it is being called. This will be used so that if a LLD needs to do some extra processing when handling queue fulls or later ramp ups, it can do so. This is a simple port of the drivers setting a change_queue_depth callback. In the patch I just have these LLDs adjust the queue depth if the user was requesting it. Signed-off-by: Mike Christie [Vasu.Dev: v2 Also converted pmcraid_change_queue_depth and then verified all modules compile using "make allmodconfig" for any new build warnings on X86_64. Updated original description after combing two original patches from Mike to make this patch git bisectable.] Signed-off-by: Vasu Dev [jejb: fixed up 53c700] Signed-off-by: James Bottomley commit 005ef1abe756c7d2743a0574018c7bb1fa508108 Author: jack wang Date: Wed Oct 14 16:19:21 2009 +0800 [SCSI] pm8001: add SAS/SATA HBA driver This driver supports PMC-Sierra PCIe SAS/SATA 8x6G SPC 8001 chip based host adapters. Signed-off-by: Jack Wang Signed-off-by: Lindar Liu Signed-off-by: Tom Peng Signed-off-by: Kevin Ao Signed-off-by: James Bottomley commit 3263bca6f4110bc97d9a77c62aa23a49d65c68ec Author: Jayamohan Kallickal Date: Fri Oct 23 11:53:49 2009 +0530 [SCSI] be2iscsi: Adding Ring Mode Wrb's V3 This patch adds support for ring based wrbs Signed-off-by: Jayamohan Kallickal Signed-off-by: James Bottomley commit b542165f704fc4a9f120396c313e5ade39ca42d7 Author: Jayamohan Kallickal Date: Fri Oct 23 11:52:33 2009 +0530 [SCSI] be2iscsi: Adding msix and mcc_rings V3 This patch enables msix for be2iscsi. It also enables use of mcc_rings for fw commands. Since the mcc eq creation is dependent on msix I am sending as one patch Signed-off-by: Jayamohan Kallickal Signed-off-by: James Bottomley commit bb565acd143342268464bf995301a18c4b5898a7 Author: Joe Eykholt Date: Wed Oct 21 16:28:30 2009 -0700 [SCSI] libfc: fix free of fc_rport_priv with timer pending Timer crashes were caused by freeing a struct fc_rport_priv with a timer pending, causing the timer facility list to be corrupted. This was during FC uplink flap tests with a lot of targets. After discovery, we were doing an PLOGI on an rdata that was in DELETE state but not yet removed from the lookup list. This moved the rdata from DELETE state to PLOGI state. If the PLOGI exchange allocation failed and needed to be retried, the timer scheduling could race with the free being done by fc_rport_work(). When fc_rport_login() is called on a rport in DELETE state, move it to a new state RESTART. In fc_rport_work, when handling a LOGO, STOPPED or FAILED event, look for restart state. In the RESTART case, don't take the rdata off the list and after the transport remote port is deleted and exchanges are reset, re-login to the remote port. Note that the new RESTART state also corrects a problem we had when re-discovering a port that had moved to DELETE state. In that case, a new rdata was created, but the old rdata would do an exchange manager reset affecting the FC_ID for both the new rdata and old rdata. With the new state, the new port isn't logged into until after any old exchanges are reset. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 406df4abe902b6c360d94d0d478ccb9701fc5591 Author: Abhijeet Joglekar Date: Wed Oct 21 16:28:25 2009 -0700 [SCSI] fnic: Pad the unused bytes of CDB to 0s Signed-off-by: Abhijeet Joglekar Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 43628ac2066b725170d81e5232046aca0384ec7e Author: Abhijeet Joglekar Date: Wed Oct 21 16:28:19 2009 -0700 [SCSI] fnic: Set max_cmd_len to driver supported CDB length Signed-off-by: Abhijeet Joglekar Signed-off-by: Robert Love Signed-off-by: James Bottomley commit d36d79e336114dbb686cba4f152deb464b658c32 Author: Abhijeet Joglekar Date: Wed Oct 21 16:28:14 2009 -0700 [SCSI] fnic: Process all cq entries per ISR Driver was processing a fixed max number of cq descriptors per ISR. For instance, for the SCSI IO queue, number of IOs processed per ISR were 8. If hardware writes 9 cq descriptors to the cq and generates an interrupt, driver would process only 8 descriptors and decrement the outstanding credit count by 8. Unless another interrupt event happens, the hw does not generate any additional interrupt. This results in the cq descriptor sitting in the queue without being procesed and can cause IO timeouts and aborts. Modify all ISR functions to process all queued cq descriptors in one shot. Since bulk of ELS frame processing is done in thread context and bulk of SCSI IO processing is done in soft ISR deferred context, the cycles spent in the ISR per cq descriptor is small. Signed-off-by: Herman Lee Signed-off-by: Abhijeet Joglekar Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 5573a2a258fc1a72cb4b39d4d862f032bc4bb5d4 Author: Chris Leech Date: Wed Oct 21 16:28:09 2009 -0700 [SCSI] libfc: fix memory corruption caused by double frees and bad error handling I was running into several different panics under stress, which I traced down to a few different possible slab corruption issues in error handling paths. I have not yet looked into why these exchange sends fail, but with these fixes my test system is much more stable under stress than before. fc_elsct_send() could fail and either leave the passed in frame intact (failure in fc_ct/els_fill) or the frame could have been freed if the failure was is fc_exch_seq_send(). The caller had no way of knowing, and there was a potential double free in the error handling in fc_fcp_rec(). Make fc_elsct_send() always free the frame before returning, and remove the fc_frame_free() call in fc_fcp_rec(). While fc_exch_seq_send() did always consume the frame, there were double free bugs in the error handling of fc_fcp_cmd_send() and fc_fcp_srr() as well. Numerous calls to error handling routines (fc_disc_error(), fc_lport_error(), fc_rport_error_retry() ) were passing in a frame pointer that had already been freed in the case of an error. I have changed the call sites to pass in a NULL pointer, but there may be more appropriate error codes to use. Question: Why do these error routines take a frame pointer anyway? I understand passing in a pointer encoded error to the response handlers, but the error routines take no action on a valid pointer and should never be called that way. Signed-off-by: Chris Leech Signed-off-by: Robert Love Signed-off-by: James Bottomley commit c40e063a9136fca4432290add2cd7ffbfd328de7 Author: Yi Zou Date: Wed Oct 21 16:28:03 2009 -0700 [SCSI] fcoe: Call ndo_fcoe_enable/disable to turn FCoE feature on/off in LLD Calls ndo_fcoe_enabled() of the associated netdev upon creating the FCoE instance to make sure LLD has all necessary resources allocated and setup properly before passing FCoE traffic. Similarly, calls ndo_fcoe_disable() upon destroying the FCoE instance on the associated netdev to allow the LLD to release all allocated resources for FCoE. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit adfd6110906280cb5b2eb03f089bd8ed766ce96f Author: Yi Zou Date: Wed Oct 21 16:27:58 2009 -0700 [SCSI] libfc: Fix frags in frame exceeding SKB_MAX_FRAGS in fc_fcp_send_data In case of sequence offload, in fc_fcp_send_data(), the skb_fill_page_info() called may end up adding more frags to the skb_shinfo(fp_skb(fp))->frags[], exceeding SKB_MAX_FRAGS, this eventually corrupts the memory. I am adding the FR_FRAME_SG_LEN back, but as SKB_MAX_FRAGS -1, leaving 1 for our fcoe_eof_crc page. And send will be broken into multiple large sends if the frame already contains more frags than skb handle. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 690037cae7209e39bfa938b6455c9d658a32ead8 Author: Yi Zou Date: Wed Oct 21 16:27:52 2009 -0700 [SCSI] fcoe: Use NETIF_F_FCOE_MTU flag to set up max frame size (lport->mfs) Add a define of FCOE_MTU as 2158 bytes and use FCOE_MTU when the LLD is found to support NETIF_F_FCOE_MTU. The lport->mfs is then calculated out of the 2158 FCOE_MTU. Otherwise, we stick with the netdev->mtu, i.e., LAN MTU. Also, change the notification on NETDEV_CHANGEMTU event to bypass changing mfs when LAN MTU is changed if NETIF_F_FCOE_MTU is supported. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 6855441b0fd376bad57f22f4d6106664bf9bd867 Author: Mike Christie Date: Wed Oct 21 16:27:44 2009 -0700 [SCSI] fcoe: initialize return value in fcoe_destroy When doing echo ethX > /sys..../destroy I am getting errors when the tear down succeeds. It looks like the reason for this is because the rc var is not getting set when the destruction works. This just sets it to zero. Signed-off-by: Mike Christie Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 42a99c369aa720c8a83ace78281f7dd64cca2d57 Author: Vasu Dev Date: Wed Oct 21 16:27:39 2009 -0700 [SCSI] libfc: removes unused disc_work and ex_list Reported-by: Alex Lyakas Signed-off-by: Vasu Dev Signed-off-by: Robert Love Signed-off-by: James Bottomley commit d6382faefd229edbe51e8257b09d9b91e581d48f Author: Vasu Dev Date: Wed Oct 21 16:27:33 2009 -0700 [SCSI] libfc: adds missing exch release for accepted RRQ Adds missing exch release when RRQ is accepted by calling fc_seq_ls_acc. Adds common exch release for fc_exch_els_rrq by use of out label. Reported-by: Alex Lyakas Signed-off-by: Vasu Dev Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 97ca2ac2f9de86fae13aaaba10aca760110ef54a Author: Vasu Dev Date: Wed Oct 21 16:27:28 2009 -0700 [SCSI] libfc: removes initializing fc_cpu_order and fc_cpu_mask per lport Initializing these libfc globals per lport could mess up exch allocation/free for existing lport. So this patch moves their initialization to fc_setup_exch_mgr so that these globals gets initialized only once for libfc. Reported-by: Alex Lyakas Signed-off-by: Vasu Dev Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 9df6d30fd68c8853a0f20d84cf9f7ec0bc8ebc47 Author: Joe Eykholt Date: Wed Oct 21 16:27:22 2009 -0700 [SCSI] libfc: don't WARN_ON in lport_timeout for RESET state It's possible and harmless to get FLOGI timeouts while in RESET state. Don't do a WARN_ON in that case. Also, split out the other WARN_ONs in fc_lport_timeout, so we can tell which one is hit by its line number. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 50d1e1e17c55c823b47d437d752cdfcaae1d8172 Author: Joe Eykholt Date: Wed Oct 21 16:27:17 2009 -0700 [SCSI] libfc: lport: fix minor documentation errors Fix minor errors. A debug message said an RLIR was received instead of ECHO. "Expected" was misspelled in several places. Fix a type cast from u32 to __be32. Rob, Some of these may have been also taken care of in your other doc cleanup patch. Feel free to fold them in. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 50b62e80d7f216a17fc69d6baa106bf530489b45 Author: Yi Zou Date: Wed Oct 21 16:27:12 2009 -0700 [SCSI] libfc: Fix wrong scsi return status under FC_DATA_UNDRUN This bug is exposed when there is a link flap in LLD. Particularly, when it happens right after a SCSI write command is sent out, no FCP_DATA is sent, causing fsp->status_code to be set as FC_DATA_UNDRUN in fc_fcp_complete_locked even no SCSI status is received. Consequently, fc_io_compl treats this as DID_OK. This results in SCSI returning successful to the initial I/O request even there is no DATA actually sent. Particularly, if you run an I/O tool w/ data verification on, the read back for verification is gonna fail. This is fixed here by checking when FC_DATA_UNDRUN happens, SCSI status is received w/ FC_SRB_RCV_STATUS set in fsp->state. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 3ba524442a55519f7d6f91598223b1ff8660f690 Author: Robert Love Date: Wed Oct 21 16:27:06 2009 -0700 [SCSI] libfc: Remove unused fc_lport pointer from fc_fcp_pkt_abort This argument isn't used, let's not pass it into the routine. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 9a23a28d5cbca2e6f342faa96e0560f98060baad Author: Robert Love Date: Wed Oct 21 16:27:01 2009 -0700 [SCSI] libfc, fcoe: Don't EXPORT_SYMBOLS unnecessarily These are a few functions that were not used by other modules. They did not need to be exported so this patch removes the EXPORT_SYMBOLS call for each. Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 834bb069e30598679e2046c19a2a45e4e4cb95f0 Author: Yi Zou Date: Wed Oct 21 16:26:55 2009 -0700 [SCSI] fcoe: remove redundant checking of netdev->netdev_ops Remove the redundant checking of netdev->netdev_ops as it will never be NULL. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit a0e19698d12d3d3f3565b8b25cdc95ac8c8dea36 Author: Yi Zou Date: Wed Oct 21 16:26:50 2009 -0700 [SCSI] libfc: fix ddp in fc_fcp for 0 xid xid 0 was used as an indication of invalid xid before but now xid 0 can be used as a valid exchange i. This patch fixes the ddp completion in fcp layer, i.e., in fc_fcp.c:fc_fcp_ddp_done() function, to make sure it does not use xid 0 for indication of an invalid xid, instead, it now uses use FC_XID_UNKNOWN for such indication. Signed-off-by: Yi Zou Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 7c0d79c44dd303088c03070f7904c9652dc7d8a3 Author: Joe Eykholt Date: Wed Oct 21 16:26:45 2009 -0700 [SCSI] libfc: fix typo in retry check on received PRLI A received Fibre Channel ELS PRLI request contains a bit that indicates whether the remote port supports certain retry processing sequences. The test for this bit was somehow coded to use multiply instead of AND! This case would apply only for target mode operation, and it is unlikely to be noticed as an initiator. Signed-off-by: Joe Eykholt Signed-off-by: Robert Love Signed-off-by: James Bottomley commit 98b7412c278b735011bde62197ce51f4479b1387 Author: Brian King Date: Mon Oct 19 15:07:55 2009 -0500 [SCSI] ibmvfc: Driver version 1.0.7 Bump driver version to 1.0.7. Signed-off-by: Brian King Signed-off-by: James Bottomley commit 51a46dc692d587bf49366fbc08be3b170995cdad Author: Brian King Date: Mon Oct 19 15:07:54 2009 -0500 [SCSI] ibmvfc: Add FC Passthru support Adds support for FC passthru via BSG. Signed-off-by: Brian King Signed-off-by: James Bottomley commit c8d4245c7c641bc9cbc41c03fcb7768b4af8e424 Author: Brian King Date: Mon Oct 19 15:07:53 2009 -0500 [SCSI] ibmvfc: Fix adapter cancel flags for terminate_rport_io When issuing a Cancel to the virtual fibre channel adapter, the interface specifies a flags field for the client to indicate what kind of error recovery is being performed. Fix up these flags for terminate_rport_io to indicate an abort task set rather than a target reset. Signed-off-by: Brian King Signed-off-by: James Bottomley commit bf6f8ddf867926fef4e64b9ecb5cb4689e161726 Author: Brian King Date: Mon Oct 19 15:07:49 2009 -0500 [SCSI] ibmvfc: Remove unnecessary parameter to ibmvfc_init_host Remove a parameter to ibmvfc_init_host which is always set to zero by all callers. Signed-off-by: Brian King Signed-off-by: James Bottomley commit 802351bb86b1f6d27e743fec97f10f9d6630c8cb Author: Brian King Date: Mon Oct 19 15:07:48 2009 -0500 [SCSI] ibmvfc: Fix locking in ibmvfc_remove Need to grab the host lock around the call to ibmvfc_link_down. Signed-off-by: Brian King Signed-off-by: James Bottomley commit 360c2a0f80088bdf952b23c6c63f4f27a7d5bd5f Author: Brian King Date: Mon Oct 19 15:07:47 2009 -0500 [SCSI] ibmvfc: Fixup TMF response handling When processing the response to either a LUN reset, target reset, or an abort task set, the ibmvfc driver needs to treat as success receiving a response with a non-zero status in the response IU along with a general transport error with the FCP response code being zero. The VIOS currently guarantees this cannot happen, but a future version of VIOS may allow this to be returned, so ensure we handle this response combination correctly for TMFs, as we already do for SCSI commands. Signed-off-by: Brian King Signed-off-by: James Bottomley commit 0d83fc5cfbe0cc1381b167cdef798678134b5f9f Author: Martin K. Petersen Date: Thu Oct 15 14:45:27 2009 -0400 [SCSI] scsi_debug: Thin provisioning support This version fixes 64-bit modulo on 32-bit as well as inadvertent map updates when TP was disabled. Implement support for thin provisioning in scsi_debug. No actual memory de-allocation is taking place. The intent is to emulate a thinly provisioned storage device, not to be one. There are four new module options: - unmap_granularity specifies the granularity at which to track mapped blocks (specified in number of logical blocks). 2048 (1 MB) is a realistic value for disk arrays although some may have a finer granularity. - unmap_alignment specifies the first LBA which is naturally aligned on an unmap_granularity boundary. - unmap_max_desc specifies the maximum number of ranges that can be unmapped using one UNMAP command. If this is 0, only WRITE SAME is supported and UNMAP will cause a check condition. - unmap_max_blocks specifies the maximum number of blocks that can be unmapped using a single UNMAP command. Default is 0xffffffff. These parameters are reported in the new and extended block limits VPD. If unmap_granularity is specified the device is tagged as thin provisioning capable in READ CAPACITY(16). A bitmap is allocated to track whether blocks are mapped or not. A WRITE request will cause a block to be mapped. So will WRITE SAME unless the UNMAP bit is set. Blocks can be unmapped using either WRITE SAME or UNMAP. No accounting is done to track partial blocks. This means that only whole blocks will be marked free. This is how the array people tell me their firmwares work. GET LBA STATUS is also supported. This command reports whether a block is mapped or not, and how long the adjoining mapped/unmapped extent is. The block allocation bitmap can also be viewed from user space via: /sys/bus/pseudo/drivers/scsi_debug/map Signed-off-by: Martin K. Petersen Acked-by: Douglas Gilbert Signed-off-by: James Bottomley commit 9e70ed0006efba59f0dae7eef536a6b1432d07cb Author: Martin K. Petersen Date: Thu Oct 15 14:43:23 2009 -0400 [SCSI] scsi: Add missing command definitions Add definitions for UNMAP, WRITE SAME{16,32} and GET LBA STATUS commands. Signed-off-by: Martin K. Petersen Signed-off-by: James Bottomley commit 3b7f3c608f6a1703e958ca0ae21d1619d29a05ed Author: Giridhar Malavali Date: Tue Oct 13 15:16:53 2009 -0700 [SCSI] qla2xxx: Update version number to 8.03.01-k7 Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit ac3b0219937d85b223598655935dd62e85dcef8f Author: Lalit Chandivade Date: Tue Oct 13 15:16:52 2009 -0700 [SCSI] qla2xxx: Properly handle UNDERRUN completion statuses. Correct issues where the lower scsi-status would be improperly cleared, instead, allow the midlayer to process the status after the proper residual-count checks are performed. Finally, validate firmware status flags prior to assigning values from the FCP_RSP frame. Signed-off-by: Lalit Chandivade Signed-off-by: Michael Hernandez Signed-off-by: Ravi Anand Signed-off-by: Andrew Vasquez Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit 302778be3d49f174f648e8f8c0cfa7ccd4892ee4 Author: Andrew Vasquez Date: Tue Oct 13 15:16:51 2009 -0700 [SCSI] qla2xxx: Properly re-register FC4/FDMI after physical and logical link disruptions. Original code would not register FC4 nor FDMI information after a logical tear-down of an VFC link. Code now triggers registration date during processing of a 'Report ID Acquisition IOCB', which is submitted after a FLOGI or FDISC completes. Signed-off-by: Andrew Vasquez Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit 6a9517c261ccf0bf3f17cc6b70c3902f9a5cae3a Author: Andrew Vasquez Date: Tue Oct 13 15:16:50 2009 -0700 [SCSI] qla2xxx: Properly check FCP_RSP response-info field after TMF completion. Original code discarded response-info field information and assumed the command completed successfully without verifying the target's status within the FCP_RSP packet. Signed-off-by: Andrew Vasquez Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit c655314e8bdff0c29f8aa1032515aed789b39538 Author: Andrew Vasquez Date: Tue Oct 13 15:16:49 2009 -0700 [SCSI] qla2xxx: Retrieve firmware's maximum number of supported FCFs. Signed-off-by: Andrew Vasquez Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit 29915d0880aa0224b918c16741b3bbe9d587a37f Author: Giridhar Malavali Date: Tue Oct 13 15:16:48 2009 -0700 [SCSI] qla2xxx: Set the size of the host buffer used to fetch DCBX and XGMAC parameters to 4K. Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit 759b9d2994b4b196cc05e829c72029159c4fd41f Author: Lalit Chandivade Date: Tue Oct 13 15:16:47 2009 -0700 [SCSI] qla2xxx: Reread firmware versions information after an ISP abort. In some case, the MPI and PHY versions when retrieved after the Execute-FW mailbox-command are incorrect (255.255.255.255). Instead, query the information after the check for firmware ready is done in the abort ISP path. Signed-off-by: Lalit Chandivade Signed-off-by: Andrew Vasquez Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit 0e94e844963f32d33a8b5b255adeea07ffe4816b Author: Andrew Vasquez Date: Tue Oct 13 15:16:46 2009 -0700 [SCSI] qla2xxx: Display additional mailbox registers during AEN handling. The mailbox register values may assist in debugging efforts. Signed-off-by: Andrew Vasquez Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit 0a2a429ed1dd964c115c78e1264464f07f6d4aa3 Author: Andrew Vasquez Date: Tue Oct 13 15:16:45 2009 -0700 [SCSI] qla2xxx: Add firmware-dump kobject uevent notification. Signed-off-by: Andrew Vasquez Signed-off-by: Giridhar Malavali Signed-off-by: James Bottomley commit 1b9414cb20ff5ec90d6991feff9b284aaa6944f0 Author: Jing Huang Date: Fri Sep 25 12:29:54 2009 -0700 [SCSI] bfa: fixed checkpatch errors for bfad files This patch fixes checkpatch errors/warnings in bfad files. Signed-off-by: Jing Huang Signed-off-by: James Bottomley commit 71c309995bff5b5e84253931888b6e8163ee1df0 Author: Ed Lin Date: Fri Oct 9 15:23:27 2009 -0700 [SCSI] fix inconsistent usage of max_lun max_lun in struct Scsi_Host is used as actual max lun plus 1 in scsi_sequential_lun_scan()(scsi_scan.c). However it is also used as actual max lun in some other cases. According to the comment in the definition of struct Scsi_Host, max_lun should be set to 1 more than the actual max lun, just like max_id. Fix the problem according to this definition. Signed-off-by: Ed Lin Signed-off-by: James Bottomley commit 8798a694da59486e4a3ff0abeec183202fb34c20 Author: Michael Reed Date: Fri Oct 9 14:15:59 2009 -0500 [SCSI] scsi_transport_fc: remove invalid BUG_ON I was doing some large lun count testing with 2.6.31 and hit a BUG_ON() in fc_timeout_deleted_rport(), and it seems like it should have been just a matter of time before someone did. It seems invalid to set port_state under lock, then expect it to remain set after releasing the lock. Another thread called fc_remote_port_add() when the lock was released, changing the port_state. This patch removes the BUG_ON and moves the test of the port_state to inside the host_lock. It's been running for several weeks now with no ill effect. Signed-off-by: Michael Reed Acked-by: James Smart Signed-off-by: James Bottomley commit ad63082626f99651d261ccd8698ce4e997362f7e Author: Mike Christie Date: Mon Sep 28 15:50:52 2009 -0500 [SCSI] fix propogation of integrity errors When the Integrity check is done in scsi_io_completion it will set error to -EILSEQ. However, at this point error is no longer used, and blk_end_request_err has -EIO hardcoded. It looks like there was just porting mistake with this patch http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=3e695f89c5debb735e4ff051e9e58d8fb4e95110 and we meant to send error upwards, so this patch changes the hard coded EIO to the error variable. I have only boot tested this patch. Signed-off-by: Mike Christie Acked-by: Martin K. Petersen Signed-off-by: James Bottomley commit cce9c8aed7d3ac0a14815e99b4602ae6c854a0ba Author: Ed Lin Date: Mon Sep 28 22:58:36 2009 -0800 [SCSI] stex: update version to 4.6.0000.4 Update version to 4.6.0000.4. Signed-off-by: Ed Lin Signed-off-by: James Bottomley commit 9eb46d2a08de537e14e92216bf18e7cb541d2f67 Author: Ed Lin Date: Mon Sep 28 22:58:33 2009 -0800 [SCSI] stex: add support for reset request from firmware Add support for reset request from firmware for controllers of st_shasta and st_yel type. Code adjustments necessary for this change are also included. Signed-off-by: Ed Lin Signed-off-by: James Bottomley commit cbacfb5fd9a4689b55157753b8ba4455415fb85c Author: Ed Lin Date: Mon Sep 28 22:58:17 2009 -0800 [SCSI] stex: add small dma buffer support The controllers of st_seq and st_vsc type can work if only small dma buffer is available, with a reduced firmware feature set. Add support for this case. Signed-off-by: Ed Lin Signed-off-by: James Bottomley commit 080bb708ad8f21ea743d1a9233fbc62af0feb10b Author: Kashyap, Desai Date: Wed Oct 7 11:28:50 2009 +0530 [SCSI] mptfusion: Bump version to 3.04.13 Bump version 3.04.13. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley commit 9b53b39243cf23a0b68eaa16c37ce16eada69a46 Author: Kashyap, Desai Date: Wed Oct 7 11:27:40 2009 +0530 [SCSI] mptspi: Fix for incorrect data underrun errata Errata: Certain conditions on the scsi bus may casue the 53C1030 to incorrectly signal a SCSI_DATA_UNDERRUN to the host. Workaround 1: For an Errata on LSI53C1030 When the length of request data and transfer data are different with result of command (READ or VERIFY), DID_SOFT_ERROR is set. Workaround 2: For potential trouble on LSI53C1030. It is checked whether the length of request data is equal to the length of transfer and residual. MEDIUM_ERROR is set by incorrect data. Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley commit e39e145dfb78d4e20d89139d2576306b4279c126 Author: Kashyap, Desai Date: Wed Oct 7 11:26:54 2009 +0530 [SCSI] mptctl : Remove printk which floods unnecessary messages to var/log/message Signed-off-by: Kashyap Desai Signed-off-by: James Bottomley commit a0b7736828f7615823a7dec680632656d9a9edde Author: Yang, Bo Date: Tue Oct 6 14:55:09 2009 -0600 [SCSI] megaraid_sas: Update version number and documentation Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 7218df69e3609d1fcf4d83cf8f3fc89dbfbf82a8 Author: Yang, Bo Date: Tue Oct 6 14:52:20 2009 -0600 [SCSI] megaraid_sas: use the firmware boot timeout when waiting for commands use the constant MEGASAS_RESET_WAIT_TIME when waiting for firmware commands to complete (currently 3 minutes). Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 7b2519afa1abd1b9f63aa1e90879307842422dae Author: Yang, Bo Date: Tue Oct 6 14:52:20 2009 -0600 [SCSI] megaraid_sas: fix 64 bit sense pointer truncation The current sense pointer is cast to a u32 pointer, which can truncate on 64 bits. Fix by using unsigned long instead. Signed-off-by Bo Yang Cc: stable@kernel.org Signed-off-by: James Bottomley commit 7e8a75f4dfbff173977b2f58799c3eceb7b09afd Author: Yang, Bo Date: Tue Oct 6 14:50:17 2009 -0600 [SCSI] megaraid_sas: Add the support for updating the OS after adding/removing the devices from FW Driver will update the OS devices after adding and deleting the device from FW. When driver receive add or delete AEN from FW, driver will send the DCMD cmd to get the System PD list from FW. Then driver will check if this device already in the OS: If add event and OS don't have the device (but it is in the list), driver add the device to OS, otherwise driver will not add. If remove event, driver will check the list, if is not in the list, but OS have the device, driver will remove the device. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 0c79e681eef10810a5ed41a2eb1dce244ab1c37d Author: Yang, Bo Date: Tue Oct 6 14:47:35 2009 -0600 [SCSI] megaraid_sas: Fix the fix for fw hang caused by megaraid sas application Add a lock to the skinny firmware initialisation sequence to prevent the two stage write being non atomic if multiple instances use it. Add a flag to the driver shutdown sequence to prevent aen ioctls being called after shutdown begins. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit f4c9a1317d32bb0af7546ef0c1dcc3be52dc8d0a Author: Yang, Bo Date: Tue Oct 6 14:43:28 2009 -0600 [SCSI] megaraid_sas: add the IEEE SGE support to SAS2 controller To increase the performance, megaraid sas driver added the IEEE SGE support to support SAS2 controller. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 7bebf5c79cb62766c76c6c1b9c77b86496fd363e Author: Yang, Bo Date: Tue Oct 6 14:40:58 2009 -0600 [SCSI] megaraid_sas: allocate the application cmds to sas2 controller MegaRAID SAS2 controller ioctl can't use 32 cmd for applications. Driver need to divide different number of cmds to IO and application. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 044833b572b96afe91506a0edec42efd84ba4939 Author: Yang, Bo Date: Tue Oct 6 14:33:06 2009 -0600 [SCSI] megaraid_sas: report system PDs to OS When OS issue inquiry, it will check driver's internal pd_list. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 81e403ce3c6a34cd705bf54d4cdeefdeb7068a8d Author: Yang, Bo Date: Tue Oct 6 14:27:54 2009 -0600 [SCSI] megaraid_sas: infrastructure to get PDs from FW Add system PDs to OS. Driver implemented the get_pd_list function to get the system PD from FW. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 879111224d0784eab623fe8130a1f4481e0e1966 Author: Yang, Bo Date: Tue Oct 6 14:31:54 2009 -0600 [SCSI] megaraid_sas: Add new megaraid SAS 2 controller support to the driver Add the new megaraid sas 2 controller to the driver. megaraid sas2 is LSI next generation SAS products. driver add the interface to support this product. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 72c4fd36dc7f755a5245ef2495fe27d5084d776d Author: Yang, Bo Date: Tue Oct 6 14:20:59 2009 -0600 [SCSI] megaraid_sas: add sysfs for AEN polling update the sysfs parameter to tell application driver support AEN poll Signed-off-by Bo Yang Signed-off-by: James Bottomley commit c35188377f12e5e0a74f18c3dfdd67baf88db514 Author: Yang, Bo Date: Tue Oct 6 14:18:02 2009 -0600 [SCSI] megaraid_sas: Add poll mechanism to megaraid sas driver Add Poll_wait mechanism to SAS-2 MegaRAID SAS Linux driver. Driver will wakeup poll after the driver get event from MegaRAID SAS FW. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 8d56825321339f0ef7ad08eb58332e1836881e3b Author: Yang, Bo Date: Tue Oct 6 14:12:21 2009 -0600 [SCSI] megaraid_sas: tape drive support fix Add the Tape drive fix to the megaraid_sas driver: If the command is for the tape device, set the FW pthru timeout to the os layer timeout value. Signed-off-by Bo Yang Signed-off-by: James Bottomley commit 153f251e477f41dab0314c4cd2004b9e7ebac4eb Author: Kashyap, Desai Date: Wed Sep 23 17:40:05 2009 +0530 [SCSI] mpt2sas: Bump version 03.100.03.00 Bump version to 03.100.03.00 Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit e7d59c17a70e59a052d29467bbefb23ce700dcd4 Author: Kashyap, Desai Date: Wed Sep 23 17:36:52 2009 +0530 [SCSI] mpt2sas: No link rate change, do not call update links nor unblock device (1) target resets are sending link change rate events with no link rate change -> thus said the driver was modified so when there is no link rate change, we don't need to call mpt2sas_transport_update_links nor _scsih_ublock_io_device. (2) There were changes made in _scsih_sas_topology_change_event_debug to change the debug strings so they are more clear. Also the link rate change information was added to display the new and previous link rate. for the MPI2_EVENT_SAS_TOPOLOGY_CHANGE_LIST event when the ExpStatus is set to zero, display "responding" instead of "unknown status". Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 744090d38b47ed8ead8f68b6f0c65866c0b9b17a Author: Kashyap, Desai Date: Mon Oct 5 15:56:56 2009 +0530 [SCSI] mpt2sas : Add support for RAID Action System Shutdown Initiated at OS shutdown (1) Added new function _scsih_ir_shutdown. This function will issue the MPI2_RAID_ACTION_SYSTEM_SHUTDOWN_INITIATED request via MPI2_FUNCTION_RAID_ACTION. The function will wait 10 seconds for reply message frame, then print out the ioc status and loginfo. This function is only called when there are raid volumes present. (2) Add shutdown callback in the struct pci_driver object scsih_driver. This will be called only when the system is shutting down. From this function, we will call _scsih_ir_shutdown mentioned above. (3) Add support in _scsih_remove to call _scsih_ir_shutdown. The function _scsih_remove will be called when the driver is unloaded (and system is still running). scsih internal command contex is added to send internal message frames from mpt2sas_scsih.c. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 8ffc457ed6fe33728657a0cfb7509b90d554c21f Author: Kashyap, Desai Date: Wed Sep 23 17:35:41 2009 +0530 [SCSI] mpt2sas: Freeze the sdev IO queue when firmware sends internal dev reset When receiving the MPI2_EVENT_SAS_DEV_STAT_RC_INTERNAL_DEVICE_RESET event, the driver will set the tm_busy flag in the sdev private host data, When tm_busy flag is set, the driver will return SCSI_MLQUEUE_DEVICE_BUSY, effectly freezing the IO to the device. The tm_busy flag is cleared with the MPI2_EVENT_SAS_DEV_STAT_RC_CMP_INTERNAL_DEV_RESET event. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 463217bfecbf5d17a30133a55553d94aa9fc255e Author: Kashyap, Desai Date: Mon Oct 5 15:53:06 2009 +0530 [SCSI] mpt2sas : PPC (power pc) endian bug fix's (1) EEDP(End to End data protection) was not working. This was due to not setting EEDP BlockSize and Flags to little endian format in the message frame. (2) Some expander sysfs attributes were not getting set properly. The sas format was not getting set due to endian issues with sas_format field in the struct rep_manu_reply. Since sas_format was not set properly, the component_vendor_id, component_revision_id, and component_id were not set. (3) In _transport_smp_handler: we don't need to convert the smid from little endian to cpu prior to calling mpt2sas_base_free_smid, because its allready in cpu format. (4) Some loginfos and ioc status were not xonverted from little endian to cpu. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit ec9472c74c3074541ea8389517f406b5c7ad0632 Author: Kashyap, Desai Date: Wed Sep 23 17:34:13 2009 +0530 [SCSI] mpt2sas: mpt2sas_base_get_sense_buffer_dma should be returning little endian cpu_to_le64 when calculating the physical dma address. This will properly handle endianess on big endian systems. The return value of this function was changed from dma_addr_t to __le64. Remove the typecasting of u32 when setting the SenseBufferLowAddress, since its already in __le32 format. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit e4e7c7ed3485bc530499158e28539e00d47f9ef2 Author: Kashyap, Desai Date: Wed Sep 23 17:33:14 2009 +0530 [SCSI] mpt2sas: Return DID_TRANSPORT_DISRUPTED in nexus loss,SCSI_MLQUEUE_DEVICE_BUSY if device is busy 1 Its observed that the OS was sending request to the driver after it had been put into blocking state, so the driver was modified to return SCSI_MLQUEUE_DEVICE_BUSY. 2. Driver will return DID_TRANSPORT_DISRUPTED when sdev is haivng nexus loss. This occurrs when sdev is blocked, between the MPI2_EVENT_SAS_TOPO_RC_DELAY_NOT_RESPONDING and MPI2_EVENT_SAS_TOPO_RC_TARG_NOT_RESPONDING events. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 96b681c6ad3f2f5013c0ffc558969ee6ac8c450b Author: Kashyap, Desai Date: Wed Sep 23 17:32:06 2009 +0530 [SCSI] mpt2sas: Retrieve the ioc facts prior to putting the controller into READY state The driver needs to retrieve the ioc facts prior to putting the controller into READY state. The current design is calling ioc facts after putting the controller into READY state, which means the driver is sending a diag reset instead of message unit reset becuase the capability information is not yet available. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit ec6c2b43b08f29e08ed5440abae1ec18d80fa8b7 Author: Kashyap, Desai Date: Wed Sep 23 17:31:01 2009 +0530 [SCSI] mpt2sas: Added new info messages for IR and Expander events. (1) for the MPI2_EVENT_IR_OPERATION_STATUS event, add support to print "background init" or "make data consistent" for debugging purposes. If the RAIDOperation is set to a value not defined, then don't print anything (2) for the MPI2_EVENT_SAS_DEVICE_STATUS_CHANGE event, add support to print "expander reduced functionality" and "expander reduced functionality complete", which are new events. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit e0077d607f716f68d15ab6fbf3d9f4c41434142d Author: Kashyap, Desai Date: Wed Sep 23 17:30:22 2009 +0530 [SCSI] mpt2sas: Limit the max_depth to 32 for SATA devices which are not part of volume Added sanity check in _scsih_change_queue_depth to limit the max_depth to 32 for SATA devices. This is only for physical devices not part of a volume. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit a8ebd76c49fa45d93a736ae0b0f192b554cc8c3f Author: Kashyap, Desai Date: Wed Sep 23 17:29:29 2009 +0530 [SCSI] mpt2sas: Added support to set the TimeStamp when sending ioc_init Added support to set the TimeStamp when sending ioc_init. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 1b01fe3aa58b114b2dc296676023451c6434561e Author: Kashyap, Desai Date: Wed Sep 23 17:28:59 2009 +0530 [SCSI] mpt2sas: Add Extended Type for Diagnostic Buffer support Added tests for registry entries of EXBuffSize, EXImmed, and EXType to support the new Extended diag buffer type. Modified code where necessary to handle the new ExtendedType field in the F/W diagnostic Post and Release messages. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 32e0eb569df09a8cb790cf370ee498721d88e5c6 Author: Kashyap, Desai Date: Wed Sep 23 17:28:09 2009 +0530 [SCSI] mpt2sas: Added command line option diag_buffer_enable. Added command line option diag_buffer_enable. When the command line option is set, the driver will automatically post diag buffers at driver load time. The command line option diag_buffer_enable is bitwise, so it's possible to enable both and/or snapshot + trace buffers. For trace, the driver will allocate 1MB buffer, whereas for snapshot its 2MB. The purpose for this is so the enduser doesn't have to manually use an application to setup diag buffers for debugging firmware related issues. Here is some examples trace: # insmod mpt2sas.ko diag_buffer_enable=1 snapshot: # insmod mpt2sas.ko diag_buffer_enable=2 both trace and snapshot: # insmod mpt2sas.ko diag_buffer_enable=3 Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit cef7a12cd1e0647ce2b566a76bbf4cd132b9118d Author: Kashyap, Desai Date: Wed Sep 23 17:27:41 2009 +0530 [SCSI] mpt2sas: Fixed some of the comment Fixed some of the comments sections for some of the function so "@ioc: pointer to scsi command object" was changed to "@ioc: per adapter object" Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit fa7f31673583a6e0876f8bb420735cdd8a3ffa57 Author: Kashyap, Desai Date: Wed Sep 23 17:26:58 2009 +0530 [SCSI] mpt2sas: Support for stopping driver when Firmware encounters Added command line option and shost sysfs attribute called mpt2sas_fwfault_debug. When enduser writes a "1" to this parameter, this will enable support in the driver for debugging firmware timeout related issues. This handling was added in three areas (a) scsi error handling callback called task_abort, (b) IOCTL interface, and (c) other timeouts that result in diag resets, such as manufacturing config pages. When this support is enabled, the driver will provide dump_stack to console, halt controller firmware, and panic driver. The end user probably would want to setup serial console redirection so the dump stack can be seen. Here are the three methods for enable this support: (a) # insmod mpt2sas.ko mpt2sas_fwfault_debug=1 (b) # echo 1 > /sys/module/mpt2sas/parameters/mpt2sas_fwfault_debug (c) # echo 1 > /sys/class/scsi_host/host#/fwfault_debug (where # is the host number) Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 9fec5f9fc2fbe7c6e39db01ae296528d9a20a5b1 Author: Kashyap, Desai Date: Wed Sep 23 17:26:20 2009 +0530 [SCSI] mpt2sas: Adding MPI Headers - revision L The new headers contain the following changes: (1) Added IO Unit Page 7. (2) Added new device ids for SAS2208. (3) Added SAS IO Unit Page 5. (4) Added partial and slumber power management capable flags to SAS Device Page 0 Flags field. (5) Added PhyInfo defines for power condition. (6) Added Ethernet configuration pages. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit db27136a89d061bf9dceb28953a61a8ef862ca7f Author: Kashyap, Desai Date: Wed Sep 23 17:24:27 2009 +0530 [SCSI] mpt2sas: New device SAS2208 support is added Added device ids range for { 0x80 - 87 } , modified mpi/mpi2_cnfg.h containing MPI2_MFGPAGE_DEVID_SAS2208_X. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit 9982f59450930138eb0bf9a4ebf865e8c06ba705 Author: Kashyap, Desai Date: Wed Sep 23 17:23:07 2009 +0530 [SCSI] mpt2sas: Add support in the driver to check for valid response info Add support in the driver to check for valid response info in the scsi state, then check to see if the response code is MPI2_SCSITASKMGMT_RSP_INVALID_FRAME; when this condition occurrs, the driver will return DID_SOFT_ERROR. A return code of DID_SOFT_ERROR will result in a retry at the scsi-mid layer level. An additional change added to obtain the response code from the 1st byte of the response info instead of last. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit a28eb222e3890a4ce190a430e24c483d2b5bb13b Author: Kashyap, Desai Date: Wed Sep 23 17:22:37 2009 +0530 [SCSI] mpt2sas: Expander remove fails when it is processing another expander add. This handles the case where driver receives a expander removal event while it is in the middle of processing an expander add event. The existing implementation will stop processing futher device adds when a expander delete arrives on top of add expander add. Due to a sanity check in the driver, the devices there were not added, were never handshaked to firmware with the device removal handshake protocal. Since the driver didnt' do the handshake, the controller never provide further add events. To fix this issue, the sanity check was removed so the driver will always do the device removal handshake protocal. Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley commit c5e039be7e81168a9156e801cfef2adae72e775b Author: Kashyap, Desai Date: Wed Sep 23 17:21:29 2009 +0530 [SCSI] mpt2sas: Driver will use sas address instead of handle as a lookup The device driver was not handling updating device handles in all cases across diag resets. To fix this issue, the driver is converted to using sas address instead of handle as a lookup reference to the parent expander or sas_host. Also, for both expanders and sas host, the phy handle will be one unique handle. In the sas host case, the phy handle can be different for every phy, so the change is to set the handle to the handle of the first phy; every phy will be one single sas address(phy 0) instead of a different sas address for every phy(previous implementation). So making one consistent sas address for all the direct attachedports to the sas host, will make it better user experience when using udev /dev/disk/by-path dev nodes Signed-off-by: Kashyap Desai Signed-off-by: Eric Moore Signed-off-by: James Bottomley