Kashyap, Desai [Thu, 17 Jun 2010 08:19:28 +0000 (13:49 +0530)]
[SCSI] mpt2sas: Copy sense buffer instead of working on direct memory location
(1) driver was not setting the sense data size prior to sending SCSI_IO,
resulting in the 0x31190000 loginfo
(2) The driver needs to copy the sense data to local buffer prior
to releasing the request message frame. If not, the sense buffer gets
overwritten by the next SCSI_IO request.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:18:46 +0000 (13:48 +0530)]
[SCSI] mpt2sas: Adding additional message to error escalation callback
Adding additional messages to the error escallation callbacks which
displays the wwid, sas address, handle, phy number, enclosure logical id,
and slot. In the same eh callbacks, routines, the printks were converted
to sdev_printks, which displays the bus target mapping. These additional
modifications help better identify the device which is in recovery.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:18:10 +0000 (13:48 +0530)]
[SCSI] mpt2sas: Add additional check for responding volumes after Host Reset
ISSUE DESCRIPTION:
This test case involves creating two RAID1 volumes, then
simultaneiously issue host reset and pull all the drives associated to
the 1st raid volume. The observed behavour is the physical drives are
removed, however the volume remains. The expected behavour is the
volume as well as physical drives should be removed from OS.
FIX:
Add support in the post host reset device scan logic for raid volumes
where the driver will have an additional check for responding raid
volume where the status should be either online, optimal, or degraded.
So for voluemes that have a status of missing or failed, the driver
will mark them for deletion.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:17:29 +0000 (13:47 +0530)]
[SCSI] mpt2sas: Added -ENOMEM return type when allocation fails
In the driver mpt2sas_base_attach subroutine, we need to add
support to return the proper error code when there are memory allocation
failures, e.g. returning -ENOMEM.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:16:13 +0000 (13:46 +0530)]
[SCSI] mpt2sas: Redesign Raid devices event handling using pd_handles per HBA
Actual problem :
Driver may receiving the top level expander
removal event prior to all the individual PD removal events, hence the
driver is breaking down all the PDs in advanced to the actaul PD UNHIDE
event. Driver sends multiple
Target Resets to the same volume handle for each individual PD removal.
FIX DESCRIPTION:
To fix this issue, the entire PD device handshake protocal has to be
moved to interrupt context so the breakdown occurs immediately after the
actual UNHIDE event arrives. The driver will only issue one Target Reset to
the volume handle, occurring after the FAILED or MISSING volume status
event arrives from interrupt context. For the PD UNHIDE event, the driver
will issue target resets to the PD handles, followed by OP_REMOVE. The
driver will set the "deteleted" flag during interrupt context. A "pd_handle"
bitmask was introduced so the driver has a list of known pds during entire
life of the PD; this replaces the "hidden_raid_component" flag handle in
the sas_device object. Each bit in the bitmask represents a device handle.
The bit in the bitmask would be toggled ON/OFF when the HIDE/UNHIDE
events arrive; also this pd_handle bitmask would bould be refreshed
across host resets.
Here we kept older behavior of sending target reset to volume when there is
a single drive pull, wait for the reply, then send target resets
to the PDs. We kept this behavior so the driver will
behave the same for older versions of firmware.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:15:17 +0000 (13:45 +0530)]
[SCSI] mpt2sas: Tie a log info message to a specific PHY.
Add support to display additional debug info for SCSI_IO and
RAID_SCSI_IO_PASSTHROUGH sent from the normal entry queued entry
point, as well as internal generated commands, and IOCTLS. The
additional debug info included the phy number, as well as the
sas address, enclosure logical id, and slot number. This debug info
has to be enabled thru the logging_level command line option, by
default this will not be displayed.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:13:57 +0000 (13:43 +0530)]
[SCSI] mpt2sas: print level KERN_DEBUG is replaced by KERN_INFO
Converting print level from MPT2SAS_DEBUG_FMT to MPT2SAS_INFO_FMT.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:13:17 +0000 (13:43 +0530)]
[SCSI] mpt2sas: Added sysfs support for trace buffer
Added support so the diag ring buffer can be pulled via sysfs
Added three new shost attributes: host_trace_buffer,
host_trace_buffer_enable, and host_trace_buffer_size. The
host_trace_buffer_enable attribute is used to either post or release
the trace buffers. The host_trace_buffer_size attribute contains
the size of the trace buffer. The host_trace_buffer atttribute contains
a maximum 4KB window of the buffer. In order to read the entire host buffer,
you will need to write the offset to host_trace_buffer prior to reading
it. release the host buffer, then write the entire host buffer contents to
a file.
In addition to this enhancement, we moved the automatic posting of host buffers
at driver load time to be called prior to port_enable, instead of after.
That way discovery is available in the host buffer.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:07:59 +0000 (13:37 +0530)]
[SCSI] mpt2sas: MPI header version N is updated.
Updating MPI header version N.
Removed mpi_history.txt.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:06:53 +0000 (13:36 +0530)]
[SCSI] mpt2sas: Added sysfs counter for ioc reset
Added a new sysfs shost attribute called ioc_reset_count. This will
keep count of host resets (both diagnostic and message unit).
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:04:31 +0000 (13:34 +0530)]
[SCSI] mpt2sas: Added expander phy control support
Added support to send link resets, hard resets, enable/disable phys, and
changing link rates for for expanders. This will be exported to
attributes within the sas transport layer. A new wrapper function was
added for sending SMP passthru to expanders for phy control.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:02:54 +0000 (13:32 +0530)]
[SCSI] mpt2sas: Added expander phy counter support
Added support to retrieve the invalid_dword_count,
running_disparity_error_count, loss_of_dword_sync_count, and
phy_reset_problem_count for expanders. This will be exported to
attributes within the sas transport layer. A new wrapper function was
added for sending SMP passthru to retrieve the expander phy error log.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 08:01:17 +0000 (13:31 +0530)]
[SCSI] mpt2sas: staged device discovery. disable_discovery module parameter is added.
Added command line option called disable_discovery. When enabled
on the command line, the driver will not send a port_enable when loaded
for the first time. If port_enable is not called, then there is
no discovery of devices, as well as the sas topology. Then later if one
desires to invoke discovery, then they will need to issue a diagnostic reset.
A diagnostic reset can be issued various ways. One of the way is throught
sysfs.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 07:58:55 +0000 (13:28 +0530)]
[SCSI] mpt2sas: Hold Controller reset when another reset is in progress
Driver should not allow multiple host reset when already host reset is in
progress. It is possible that host reset was sent by scsi mid layer while there was already an host reset active,
either issued via IOCTL interface or internaly, like a config page timeout.
Since there was a host reset active, the driver would return a FAILED response
to the scsi mid layer. The solution is make sure pending host resets will
wait for the active host reset to complete before returning control
back up the call stack.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Kashyap, Desai [Thu, 17 Jun 2010 07:55:13 +0000 (13:25 +0530)]
[SCSI] mpt2sas: Fix to use sas device list instead of enclosure list for _transpor_get_enclosure_identifier.
Enclosure_identifier not being returned by mpt2sas
The driver exports callback function to the sas transport layer
for obtaining the enclosure logical id. This function is called
_transport_get_enclosure_identifier. The driver was searching
the wrong list for the enclosure_identifier. The driver should be
searching the sas device list instead of enclosure list. The
sas address that is passed to the driver is for the end device, not
enclosure.
Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Karen Xie [Thu, 17 Jun 2010 00:10:37 +0000 (17:10 -0700)]
[SCSI] cxgb3i: zero out reserved or un-used fields.
Zero out the reserved or un-used CPL message fields to prevent any garbage
value.
Signed-off-by: Karen Xie <kxie@chelsio.com>
Reviewed-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:56 +0000 (13:51 -0500)]
[SCSI] hpsa: sanitize max commands
Some controllers might try to tell us they support 0 commands
in performant mode. This is a lie told by buggy firmware.
We have to be wary of this lest we try to allocate a negative
number of command blocks, which will be treated as unsigned,
and get an out of memory condition.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:50 +0000 (13:51 -0500)]
[SCSI] hpsa: separate intx and msi/msix interrupt handlers
There are things which need to be done in the intx
interrupt handler which do not need to be done in
the msi/msix interrupt handler, like checking that
the interrupt is actually for us, and checking that the
interrupt pending bit on the hardware is set (which we
weren't previously doing at all, which means old controllers
wouldn't work), so it makes sense to separate these into
two functions.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:45 +0000 (13:51 -0500)]
[SCSI] hpsa: forbid hard reset of 640x boards
The 6402/6404 are two PCI devices -- two Smart Array controllers
-- that fit into one slot. It is possible to reset them independently,
however, they share a battery backed cache module. One of the pair
controls the cache and the 2nd one access the cache through the first
one. If you reset the one controlling the cache, the other one will
not be a happy camper. So we just forbid resetting this conjoined
mess.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:40 +0000 (13:51 -0500)]
[SCSI] hpsa: Fix hard reset code.
Smart Array controllers newer than the P600 do not honor the
PCI power state method of resetting the controllers. Instead,
in these cases we can get them to reset via the "doorbell" register.
This escaped notice until we began using "performant" mode because
the fact that the controllers did not reset did not normally
impede subsequent operation, and so things generally appeared to
"work". Once the performant mode code was added, if the controller
does not reset, it remains in performant mode. The code immediately
after the reset presumes the controller is in "simple" mode
(which previously, it had remained in simple mode the whole time).
If the controller remains in performant mode any code which presumes
it is in simple mode will not work. So the reset needs to be fixed.
Unfortunately there are some controllers which cannot be reset by
either method. (eg. p800). We detect these cases by noticing that
the controller seems to remain in performant mode even after a
reset has been attempted. In those case, we proceed anyway,
as if the reset has happened (and skip the step of waiting for
the controller to become ready -- which is expecting it to be in
"simple" mode.) To sum up, we try to do a better job of resetting
the controller if "reset_devices" is set, and if it doesn't work,
we print a message and try to continue anyway.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:35 +0000 (13:51 -0500)]
[SCSI] hpsa: factor out the code to reset controllers on driver load
for kdump support
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:30 +0000 (13:51 -0500)]
[SCSI] hpsa: factor out hpsa_find_cfg_addrs.
Rationale for this is that I will also need to use this code
in fixing kdump host reset code prior to having the hba structure.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:25 +0000 (13:51 -0500)]
[SCSI] hpsa: make hpsa_find_memory_BAR not require the per HBA structure.
Rationale for this is that in order to fix the hard reset code used
by kdump, we need to use this function before we even have the per
HBA structure.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:20 +0000 (13:51 -0500)]
[SCSI] hpsa: Make "hpsa_allow_any=1" boot param enable Compaq Smart Arrays.
We were previously only accepting HP boards.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Wed, 16 Jun 2010 18:51:15 +0000 (13:51 -0500)]
[SCSI] hpsa: add new controllers
Add 5 CCISSE smart array controllers
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Nick Cheng [Fri, 18 Jun 2010 07:39:12 +0000 (15:39 +0800)]
[SCSI] arcmsr: Support 1024 scatter-gather list entries and improve AP while FW trapped and behaviors of EHs
1. To support 4M/1024 scatter-gather list entry, reorganize struct
ARCMSR_CDB and struct CommandControlBlock
2. To modify arcmsr_probe
3. In order to help fix F/W issue, add the driver mode for type B card
4. To improve AP's behavior while F/W resets
5. To unify struct MessageUnit_B's members' naming in all OS drivers'
6. To improve error handlers, arcmsr_bus_reset(), arcmsr_abort()
7. To fix the arcmsr_queue_command() in bus reset stage, just let the
commands pass down to FW, don't block
Signed-off-by: Nick Cheng <nick.cheng@areca.com.tw>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Joe Eykholt [Fri, 11 Jun 2010 23:44:57 +0000 (16:44 -0700)]
[SCSI] libfc: fix indefinite rport restart
Remote ports were restarting indefinitely after getting
rejects in PRLI.
Fix by adding a counter of restarts and limiting that with
the port login retry limit as well.
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Joe Eykholt [Fri, 11 Jun 2010 23:44:51 +0000 (16:44 -0700)]
[SCSI] libfc: Fix remote port restart problem
This patch somewhat combines two fixes to remote port handing in libfc.
The first problem was that rport work could be queued on a deleted
and freed rport. This is handled by not resetting rdata->event
ton NONE if the rdata is about to be deleted.
However, that fix led to the second problem, described by
Bhanu Gollapudi, as follows:
> Here is the sequence of events. T1 is first LOGO receive thread, T2 is
> fc_rport_work() scheduled by T1 and T3 is second LOGO receive thread and
> T4 is fc_rport_work scheduled by T3.
>
> 1. (T1)Received 1st LOGO in state Ready
> 2. (T1)Delete port & enter to RESTART state.
> 3. (T1)schdule event_work, since event is RPORT_EV_NONE.
> 4. (T1)set event = RPORT_EV_LOGO
> 5. (T1)Enter RESTART state as disc_id is set.
> 6. (T2)remember to PLOGI, and set event = RPORT_EV_NONE
> 6. (T3)Received 2nd LOGO
> 7. (T3)Delete Port & enter to RESTART state.
> 8. (T3)schedule event_work, since event is RPORT_EV_NONE.
> 9. (T3)Enter RESTART state as disc_id is set.
> 9. (T3)set event = RPORT_EV_LOGO
> 10.(T2)work restart, enter PLOGI state and issues PLOGI
> 11.(T4)Since state is not RESTART anymore, restart is not set, and the
> event is not reset to RPORT_EV_NONE. (current event is RPORT_EV_LOGO).
> 12. Now, PLOGI succeeds and fc_rport_enter_ready() will not schedule
> event_work, and hence the rport will never be created, eventually losing
> the target after dev_loss_tmo.
So, the problem here is that we were tracking the desire for
the rport be restarted by state RESTART, which was otherwise
equivalent to DELETE. A contributing factor is that we dropped
the lock between steps 6 and 10 in thread T2, which allows the
state to change, and we didn't completely re-evaluate then.
This is hopefully corrected by the following minor redesign:
Simplify the rport restart logic by making the decision to
restart after deleting the transport rport. That decision
is based on a new STARTED flag that indicates fc_rport_login()
has been called and fc_rport_logoff() has not been called
since then. This replaces the need for the RESTART state.
Only restart if the rdata is still in DELETED state
and only if it still has the STARTED flag set.
Also now, since we clear the event code much later in the
work thread, allow for the possibility that the rport may
have become READY again via incoming PLOGI, and if so,
queue another event to handle that.
In the problem scenario, the second LOGO received will
cause the LOGO event to occur again.
Reported-by: Bhanu Gollapudi <bprakash@broadcom.com>
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Roel Kluin [Fri, 11 Jun 2010 23:44:46 +0000 (16:44 -0700)]
[SCSI] fnic: fnic_scsi.c: clean up
In fnic_abort_cmd() and fnic_device_reset() assign `rport' earlier to make
FNIC_SCSI_DBG() calls cleaner.
In fnic_clean_pending_aborts() `rport' is not used.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Acked-by: Abhijeet Joglekar <abjoglek@cisco.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Yi Zou [Fri, 11 Jun 2010 23:44:41 +0000 (16:44 -0700)]
[SCSI] libfc: lport state is enum not bit mask
lport state is enum not bit mask.
Signed-off-by: Yi Zou <yi.zou@intel.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:44:36 +0000 (16:44 -0700)]
[SCSI] libfcoe: Check for order and missing critical descriptors for FIP ELS requests
As per FC-BB-5 rev.2, section 7.8.7.1, strict ordering of FIP descriptors
is required for ELS requests. Also, look for missing and duplicate critical
descriptors.
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:44:31 +0000 (16:44 -0700)]
[SCSI] libfcoe: Host doesnt handle CVL to NPIV ports
Clear virtual link for NPIV ports is now handled by resetting
the matching vnport.
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:44:25 +0000 (16:44 -0700)]
[SCSI] libfcoe: Handle duplicate critical descriptors
As per FC-BB-5 rev 2, section 7.8.6.2, malformed FIP frame shall be
discarded. Drop discovery adv, ELS and CLV's with duplicate critical
descriptors.
[Resending after incorporating Joe's review comments]
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Joe Eykholt [Fri, 11 Jun 2010 23:44:20 +0000 (16:44 -0700)]
[SCSI] libfcoe: update FIP FCF D flag from advertisments
Allow the D flag (indicating that keep-alives are not needed) to
be updated dynamically from received FIP advertisements.
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Joe Eykholt [Fri, 11 Jun 2010 23:44:15 +0000 (16:44 -0700)]
[SCSI] libfcoe: Use fka_period as periodic timeouts to age out fcf if
keep alives are disabled due to fd_flags set and also
stop updating keep alive values in that case.
Update select fcf time only if fcf is not already selected or
select time is not already determined from parse adv, and then
have select time cleared only once after fcf is selected.
Changed deadline check to time_after_eq() from time_after()
since now next timeout will be on exact 2.5 times FKA followed
by first advertisement.
Signed-off-by: Vasu Dev <vasu.dev@intel.com>
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Joe Eykholt [Fri, 11 Jun 2010 23:44:10 +0000 (16:44 -0700)]
[SCSI] libfcoe: fix lenient aging of FCF advertisements
[This patch has several improvements to the code in
the fip timers. It hasn't been tested yet.
I'm sending it out for review. Vasu, perhaps you can
merge this with your patch and test it together.]
The current code allows an advertisement to be used
even if it has been 3 times the FCF keep-alive
advertisement period (FKA) since one was received from
that FCF. The spec. calls for 2.5 times FKA.
Fix this and make sure we detect missed keep-alives promptly.
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:44:04 +0000 (16:44 -0700)]
[SCSI] libfc: Handle unsolicited PRLO request
Resubmitting after incorporating Joe's review comment.
Unsolicited PRLO request is now handled by sending LS_ACC,
and then relogin to the remote port if an N-port login
session exists for that remote port.
Note that this patch should be applied on top of Joe Eykholt's
"Fix remote port restart problem" patch.
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Joe Eykholt [Fri, 11 Jun 2010 23:43:59 +0000 (16:43 -0700)]
[SCSI] fcoe: clean up TBD comments in FCoE prototype header
Some old comments in fc_fcoe.h say TBD long after the
standard has been passed by T11. Clean them up.
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:43:54 +0000 (16:43 -0700)]
[SCSI] libfc: Honor LS_ACC response codes for PRLI
As per FC-LS Rev 1.62 table 46, response codes are handled as follows:
1. If the Req executed is true, PRLI is accepted.
2. If Req executed is not set, if resp code is 5,
PRLI is not retried and port is logged out.
3. If resp code is anything apart from 1 or 5, PRLI is retired
upto max retry count.
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:43:49 +0000 (16:43 -0700)]
[SCSI] libfc: Retry a rejected PRLI request
Retry upto max_rport_retry_count when a target responds with
LS_RJT for a PRLI request.
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:43:44 +0000 (16:43 -0700)]
[SCSI] libfcoe: No solicitation if adv is dropped
Host does not send discovery solicitation messages if Disc. Adv
from FCF are dropped. It restarts sending solicitation only
after receiving a Discovery Adv. from FCF. Fix is to restart
solicitation immediately after CVL processing.
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Bhanu Prakash Gollapudi [Fri, 11 Jun 2010 23:43:38 +0000 (16:43 -0700)]
[SCSI] libfcoe: Avoid hang when receiving non-critical descriptors
Avoid infinite loop while processing FIP ELS or discovery
advertisement with non-critical descriptors.
Signed-off-by: Bhanu Prakash Gollapudi <bprakash@broadcom.com>
Acked-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Joe Eykholt [Fri, 11 Jun 2010 23:43:33 +0000 (16:43 -0700)]
[SCSI] libfcoe: FIP link keep-alive should continue while logged off
A check in fcoe_ctlr_send_keep_alive() returns if there's no
port_id for the local port. This could miss a keep alive if
we just did a host reset and have logged off and will log back in.
Return only if we are doing the port keep alive, in which case
we need to be logged in.
Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Wayne Boyer [Thu, 10 Jun 2010 21:46:34 +0000 (14:46 -0700)]
[SCSI] ipr: move setting of the allow_restart flag for vsets and disks
A problem was found where the call to scsi_add_device() fails intermittently
for an adapter. This is caused when __scsi_add_device() returns -ENODEV as
a result of not calling scsi_probe_and_add_lun() since the call to
scsi_host_scan_allowed() fails. scsi_host_scan_allowed() fails because the
adapter state is set to SHOST_RECOVERY instead of SHOST_RUNNING. The state of
the adapter is being set to SHOST_RECOVERY by scsi_eh_scmd_add() during
error handling.
This problem is avoided by moving the setting of the allow_restart flag to
later in the device initialization sequence. This prevents further error
handling if we get a NOT_READY response from a TUR command by causing
scsi_check_sense() to return SUCCESS. Therefore, scsi_eh_scmd_add() will
not run and the adapter state will remain as SHOST_RUNNING.
Signed-off-by: Wayne Boyer <wayneb@linux.vnet.ibm.com>
Acked-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Dan Carpenter [Thu, 10 Jun 2010 07:53:05 +0000 (09:53 +0200)]
[SCSI] be2iscsi: fix null dereference on error path
"phba" is always null here so we can't dereference it.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Dan Carpenter [Thu, 10 Jun 2010 07:52:21 +0000 (09:52 +0200)]
[SCSI] be2iscsi: fix memory leak on error path
I added a kfree(pwrb_arr) in front of the return.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Wayne Boyer [Wed, 9 Jun 2010 15:24:55 +0000 (08:24 -0700)]
[SCSI] ipr: add writeq definition if needed
Compiling the driver will fail on 32 bit powerpc and other
architectures where writeq is not defined. This patch adds a
definition for writeq.
Signed-off-by: Wayne Boyer <wayneb@linux.vnet.ibm.com>
Acked-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Mike Christie [Wed, 9 Jun 2010 08:30:08 +0000 (03:30 -0500)]
[SCSI] be2iscsi: fix disconnection cleanup
This patch fixes 4 bugs in the connection connect/disconnect
cleanup path.
1. If beiscsi_open_conn fails beiscsi_free_ep was always being
called, and if beiscsi_open_conn failed because beiscsi_get_cid
failed then we would free an unallocated cid.
2. If beiscsi_ep_connect failed due to a beiscsi_open_conn failure
it was leaking iscsi_endpoints.
3. beiscsi_ep_disconnect was leaking iscsi_endpoints.
beiscsi_ep_disconnect should free the iscsi_endpoint. We cannot
do it in beiscsi_conn_stop because that is only called for
iscsi connection cleanup. If beiscsi_ep_connect returns
success, but then the poll function fails or the connect
times out then beiscsi_ep_disconnect will be called to clean
up the ep. The conn_stop callout will not be called in that path.
4. beiscsi_conn_stop was freeing the iscsi_endpoint then accessing
it a couple lines later.
Signed-off-by: Mike Christie <michaelc@cs.wisc.edu>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Tue, 8 Jun 2010 22:32:13 +0000 (18:32 -0400)]
[SCSI] lpfc 8.3.14: Update Driver version to 8.3.14
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Tue, 8 Jun 2010 22:31:54 +0000 (18:31 -0400)]
[SCSI] lpfc 8.3.14: SCSI and SLI API fixes
- Fixed accounting of allocated SCSI buffers when post sgl fails.
- Restrict scsi buffer allocation based on LUN count (sdev_cnt).
- Create __lpfc_sli_free_rpi that doesn't take out the hbalock.
- Modify lpfc_sli_free_rpi to call __lpfc_sli_free_rpi.
- Call __lpfc_sli_free_rpi in lpfc_cleanup_pending_mbox.
- Do not swap the strings returned in mailbox commands and do
not swap byte aligned data in VPD.
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Tue, 8 Jun 2010 22:31:37 +0000 (18:31 -0400)]
[SCSI] lpfc 8.3.14: FCoE Discovery Fixes
- Prevent unregistring of unused FCF when FLOGI is pending.
- Prevent point to point discovery on a FCoE HBA.
- Fixed FCF discovery failure after swapping FCoE port by
switching over to fast failover method when no FCF matches in-use FCF.
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Tue, 8 Jun 2010 22:31:21 +0000 (18:31 -0400)]
[SCSI] lpfc 8.3.14: PCI fixes and enhancements
- Allow enabling MSI-X intterupts with fewer vectors than requested
by looking at the return value from pci_enable_msix.
- Implemented driver PCI AER error handling routines for supporting
AER error recovering on SLI4 devices.
- Remove redundant SLI_ACTIVE checks
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Anil Ravindranath [Tue, 8 Jun 2010 17:56:34 +0000 (10:56 -0700)]
[SCSI] pmcraid: MSI-X support and other changes
1. MSI-X interrupt support
2. Driver changes to support new maxRAID controller FW version. The
changes are mainly done to handle async notification changes done in
newer controller FW version.
3. Added state change notifications to notify applications of controller
states.
Signed-off-by: Anil Ravindranath <anil_ravindranath@pmc-sierra.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Mon, 7 Jun 2010 19:24:54 +0000 (15:24 -0400)]
[SCSI] lpfc 8.3.13: Update Driver Version to 8.3.13
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Mon, 7 Jun 2010 19:24:45 +0000 (15:24 -0400)]
[SCSI] lpfc 8.3.13: Add TX Queue Support for SLI4 ELS commands.
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Mon, 7 Jun 2010 19:24:29 +0000 (15:24 -0400)]
[SCSI] lpfc 8.3.13: Misc fixes
- Change the Max receive size on CIN FCFs to 0x800
- (From linux community) Check boundary before checking for NULL.
- Update last completion time for completed I/O to prevent heartbeat.
- Add Balius PCI Device IDs
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Mon, 7 Jun 2010 19:24:12 +0000 (15:24 -0400)]
[SCSI] lpfc 8.3.13: SCSI specific changes
- Fix hba_queue_depth to reflect actual available XRIs
- Add support for new SLER specific firmware status codes.
- Free SCSI buffer when iotag allocation fails.
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Mon, 7 Jun 2010 19:23:35 +0000 (15:23 -0400)]
[SCSI] lpfc 8.3.13: Initialization code clean up and fixes.
- Add poll or wait flag parameter to hba_init_link and hba_down_link.
- (From Linux Community) Make return with ENXIO negative.
- Remove unused INB code from driver.
- Prevent block_magmt_io from returning until mailbox is inactive.
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
James Smart [Mon, 7 Jun 2010 19:23:17 +0000 (15:23 -0400)]
[SCSI] lpfc 8.3.13: FC Discovery Fixes and enhancements.
- Retry PLOGI up to 48 times when LS_RJT reason is
"Unable to supply requested data."
- When dev loss timeout occures do not change state if there
is an outstanding REG_LOGIN.
- Add logic to ignore REG_LOGIN completion if discovery is
restarted while waiting for REG_LOGIN.
- Only change state on REG_LOGIN completion if still in
state waiting for REG_LOGIN completion.
- Only send ADISCs to FCP-2 Targets (not Initiators).
Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com>
Signed-off-by: James Smart <james.smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Wayne Boyer [Fri, 4 Jun 2010 17:26:50 +0000 (10:26 -0700)]
[SCSI] ipr: add endian swap enablement for 64 bit adapters
A change in the hardware design of the chip for the new adapters changes the
default endianness of MMIO operations. This patch adds a register definition
which when written to with a predefined value will change the endianness
back to what the driver expects.
This patch also fixes two problems found during testing.
First, the first reserved field in the ipr_hostrcb64_fabirc_desc structure only
reserved one byte. The correct amount to reserve is 2 bytes.
Second, the reserved field of the ipr_hostrcb64_error structure only reserved
2 bytes. The correct amount to reserve is 16 bytes.
Signed-off-by: Wayne Boyer <wayneb@linux.vnet.ibm.com>
Acked-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Julia Lawall [Sun, 30 May 2010 13:49:22 +0000 (15:49 +0200)]
[SCSI] dpt_i2o: Use GFP_ATOMIC when a lock is held
The function adpt_i2o_post_wait is called from several places, in some of
which, such as adpt_abort, a lock may be held.
The functions adpt_i2o_reparse_lct and adpt_i2o_lct_get are called from
several places, including adpt_rescan where a lock may be held.
The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)
// <smpl>
@gfp exists@
identifier fn;
position p;
@@
fn(...) {
... when != spin_unlock_irqrestore
when any
GFP_KERNEL@p
... when any
}
@locked@
identifier gfp.fn;
@@
spin_lock_irqsave(...)
... when != spin_unlock_irqrestore
fn(...)
@depends on locked@
position gfp.p;
@@
- GFP_KERNEL@p
+ GFP_ATOMIC
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Giridhar Malavali [Fri, 28 May 2010 22:08:31 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Updated version number to 8.03.03-k0.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Andrew Vasquez [Fri, 28 May 2010 22:08:30 +0000 (15:08 -0700)]
[SCSI] qla2xxx: For ISP 23xx, select user specified login timeout value if greater than minuimum value(4 secs).
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Giridhar Malavali [Fri, 28 May 2010 22:08:29 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Removed redundant check for ISP 84xx.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Giridhar Malavali [Fri, 28 May 2010 22:08:28 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Enable CRB based doorbell posting for request queue as default for ISP 82xx.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Arun Easi [Fri, 28 May 2010 22:08:27 +0000 (15:08 -0700)]
[SCSI] qla2xxx: T10 DIF enablement for 81XX
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Lalit Chandivade [Fri, 28 May 2010 22:08:26 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Fix flash write failure on ISP82xx.
Driver was not unprotecting correctly, use correct bits
to unprotect the flash on ISP 82xx.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Santosh Vernekar [Fri, 28 May 2010 22:08:25 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Handle outstanding mbx cmds on hung f/w scenarios.
Outstanding mailbox commands, have no way to recover on f/w hung, and we
timeout on waiting for mbx response. This in turn affects the recovery process
as follows:
- We might already be in dpc while waiting for mbx to complete, so recovery for
that pci function will never get invoked. Reset Timeout (10 sec) is far less
than mbx timeout (30 sec).
- Other mbx cmds will get stuck due to serial mbx access.
Solution is to identify fw-hung scenario and handle outstanding mbx commands to
have an early-exit instead of waiting for response.
Other mbx commands waiting for access will also do an early-exit if fw-hung is
still applicable.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Lalit Chandivade [Fri, 28 May 2010 22:08:24 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Do not enable VP in non fabric topology.
After topology change ISP is reset and VPs are re-enabled.
If the topology is not fabric, VPs could falsely get enabled.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Harish Zunjarrao [Fri, 28 May 2010 22:08:23 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Support for loading Unified ROM Image (URI) format firmware file.
Used bootloder address from FLT while loading FW from flash as well.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Andrew Vasquez [Fri, 28 May 2010 22:08:22 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Make the FC port capability mutual exclusive.
In case of both target and initiator capabilities reported by fc port,
the fc port port capability is made mutualy exclusive with priority given
for target capabilities.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Sarang Radke [Fri, 28 May 2010 22:08:21 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Add internal loopback support for ISP81xx.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Giridhar Malavali [Fri, 28 May 2010 22:08:20 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Limit rport-flaps during link-disruptions.
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Andrew Vasquez [Fri, 28 May 2010 22:08:19 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Correct async-srb issues.
* hold the hardware_lock throughout the duration of ctx-sp
timeout handling -- could result in use-after-free oops.
* retry a timed-out login-request.
* done() routines are called with the hardware-lock held, issue
qla2x00_mark_device_lost() with proper 'defer' flag.
* FCP2 capabilities are only relevant to target devices.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Giridhar Malavali [Fri, 28 May 2010 22:08:18 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Correct use-after-free oops seen during EH-abort.
Hold a reference to the srb (sp) while aborting an I/O -- as the
I/O can/will complete from within the interrupt-context.
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Giridhar Malavali [Fri, 28 May 2010 22:08:17 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Fix cpu-affinity usage for non-capable ISPs.
The TMFs used for pre-24xx ISPs incorrectly assumed 'cpu' tag
data could be valid. These chips have no multi-q/cpu-affinity
support. This corrects an oops seen on ISP23xx parts.
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Andrew Vasquez [Fri, 28 May 2010 22:08:16 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Add portid to async-request messages.
This helps to correlate submission/completion messages during
triaging.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Giridhar Malavali [Fri, 28 May 2010 22:08:15 +0000 (15:08 -0700)]
[SCSI] qla2xxx: Clear drive active CRB register when not in use.
The CRB drive active register is cleared when driver is unloaded
or when driver enters failed state.
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:44 +0000 (15:14 -0500)]
[SCSI] hpsa: add entry to MAINTAINERS
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:39 +0000 (15:14 -0500)]
[SCSI] hpsa: fix block fetch table problem.
We have 32 (MAXSGENTRIES) scatter gather elements embedded
in the command. With all these, the total command size is
about 576 bytes. However, the last entry in the block fetch table
is 35. (the block fetch table contains the number of 16-byte chunks
the firmware needs to fetch for a given number of scatter gather
elements.) 35 * 16 = 560 bytes, which isn't enough. It needs to be
36. (36 * 16 == 576) or, MAXSGENTRIES + 4. (plus 4 because there's a
bunch of stuff at the front of the command before the first scatter
gather element that takes up 4 * 16 bytes.) Without this fix, the
controller may have to perform two DMA operations to fetch the
command since the first one may not get the whole thing.
Signed-off-by: Don Brace <brace@beardog.cce.hp.com>
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:34 +0000 (15:14 -0500)]
[SCSI] hpsa: expose controller firmware revision via /sys.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:29 +0000 (15:14 -0500)]
[SCSI] hpsa: Add hpsa.txt to Documentation/scsi
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:24 +0000 (15:14 -0500)]
[SCSI] hpsa: remove unused firm_ver member of the per-hba structure
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:19 +0000 (15:14 -0500)]
[SCSI] hpsa: factor out hpsa_enter_performant_mode
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:13 +0000 (15:14 -0500)]
[SCSI] hpsa: remove unused variable trans_offset
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:08 +0000 (15:14 -0500)]
[SCSI] hpsa: factor out hpsa_wait_for_mode_change_ack
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:14:03 +0000 (15:14 -0500)]
[SCSI] hpsa: mark hpsa_mark_hpsa_put_ctlr_into_performant_mode as __devinit
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:58 +0000 (15:13 -0500)]
[SCSI] hpsa: clean up debug ifdefs
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:53 +0000 (15:13 -0500)]
[SCSI] hpsa: check that simple mode is supported
before trying to enter simple mode transport method.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:48 +0000 (15:13 -0500)]
[SCSI] hpsa: factor out hpsa_enter_simple_mode
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:43 +0000 (15:13 -0500)]
[SCSI] hpsa: factor out hpsa_p600_dma_prefetch_quirk
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:38 +0000 (15:13 -0500)]
[SCSI] hpsa: factor out hpsa_enable_scsi_prefetch
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:32 +0000 (15:13 -0500)]
[SCSI] hpsa: factor out hpsa-CISS-signature-present
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:27 +0000 (15:13 -0500)]
[SCSI] hpsa: hpsa factor out hpsa_find_board_params
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:22 +0000 (15:13 -0500)]
[SCSI] hpsa: fix leak of ioremapped memory in hpsa_pci_init error path.
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:17 +0000 (15:13 -0500)]
[SCSI] hpsa: factor out hpsa_find_cfgtables
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:12 +0000 (15:13 -0500)]
[SCSI] hpsa: factor out hpsa_wait_for_board_ready
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:07 +0000 (15:13 -0500)]
[SCSI] hpsa: factor out hpsa_find_memory_BAR
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:13:02 +0000 (15:13 -0500)]
[SCSI] hpsa: remove redundant board_id parameter from hpsa_interrupt_mode
and delete duplicated comment
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Stephen M. Cameron [Thu, 27 May 2010 20:12:57 +0000 (15:12 -0500)]
[SCSI] hpsa: factor out hpsa_board_disabled
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>