aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aic94xx (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2009-09-05[SCSI] zfcp: Replace config semaphore with mutexChristof Schmitt5-33/+32
The config semaphore is only used as a mutex, so replace it with a simple mutex. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Defer resource allocation to first ccw_set_online callChristof Schmitt3-31/+54
So far, zfcp allocated all resources required for FCP adapters/subchannels when the device was discovered in the ccw_probe callback. If there are lots of unused FCP subchannels attached to a system, this is a waste of resources. To alleviate this, defer the resource allocation to the first call to ccw_set_online. To avoid disruptions during possible following calls to ccw_set_offline and then ccw_set_online, keep the adapter resources until the device is finally being removed via ccw_remove. While doing this, also manage the zfcp erp thread together with all other adapter resources in zfcp_adapter_enqueue/dequeue. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Simplify and update ct/gs and els timeout handlingChristof Schmitt3-17/+6
The recommendation for a timeout of 2 * R_A_TOV is the same for ct/gs and els requests, so set it in the common function used for initializing both request types. Besides, the timer inside zfcp should only run longer than the timeout set for the channel, so 10 seconds more should be enough (instead of 60 seconds). Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Use kthread API for zfcp erp threadChristof Schmitt3-45/+27
Switch the creation of the zfcp erp thread from the deprecated kernel_thread API to the kthread API. This allows also the removal of some flags in zfcp since the kthread API handles thread creation and shutdown internally. To allow the usage of the kthread_stop function, replace the erp ready semaphore with a waitqueue for waiting until erp actions arrive on the ready queue. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: resolve false usage of dd_data in fc_rportSwen Schillig3-23/+5
The fc_rport structure reserves a reference where a LLD can put information required in a situation where the fc transport class is triggering LLD callbacks. The zfcp driver was using this variable directly which is discouraged. This patch solves this issue by making this reference unnecessary. In addition the dev_loss_tmo callback is removed, it is not required: zfcp does not access the fc_rport after calling fc_remote_port_delete. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Apply common naming conventions to zfcp_fcSwen Schillig5-36/+35
Update the Fibre Channel related code to use the zfcp_fc prefix. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: introduce _setup, _destroy for qdio and FCSwen Schillig4-64/+89
Extract independent data structures and introduce common _setup and _destroy routines for QDIO and Fibre Channel related data structures Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Update dbf callsSwen Schillig9-380/+347
Change the dbf data and functions to use the zfcp_dbf prefix throughout the code. Also change the calls to dbf to use zfcp_dbf instead of zfcp_adapter. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Decouple gid_pn requests from erpChristof Schmitt6-56/+47
Don't let the erp wait for gid_pn requests to complete. Instead, queue the gid_pn work, exit erp and let the finished gid_pn work trigger a new port reopen. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Move qdio related data out of zfcp_adapterSwen Schillig9-296/+343
The zfcp_adapter structure was growing over time to a size of almost one memory page. To reduce the size of the data structure and to seperate different layers, put all qdio related data in the new zfcp_qdio data structure. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Separate qdio attributes from zfcp_fsf_reqSwen Schillig5-115/+160
Split all qdio related attributes out of zfcp_fsf_req and put it in new structure. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Move workqueue to adapter structSwen Schillig6-8/+34
Remove the global driver work queue and replace it with a workqueue local to the adapter. The usage of this workqueue makes this the correct place for the structure. In addition multiple adapters won't block each other due to the serialization of the queued work. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Remove the useless ZFCP_REQ_AUTO_CLEANUP flagSwen Schillig1-35/+45
The flag ZFCP_REQ_AUTO_CLEANUP was useless as the ZFCP_STATUS_FSFREQ_CLEANUP flag is there for exactly the same purpose. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Improve request allocation through mempoolsSwen Schillig4-113/+127
Remove the special case for NO_QTCB requests and optimize the mempool and cache processing for fsfreqs. Especially use seperate mempools for the zfcp_fsf_req and zfcp_qtcb structs. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Replace fsf_req wait_queue with completionSwen Schillig4-28/+10
The combination wait_queue/wakeup in conjunction with the flag ZFCP_STATUS_FSFREQ_COMPLETED to signal the completion of an fsfreq was not race-safe and can be better solved by a completion. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: fix layering oddities between zfcp_fsf and zfcp_qdioSwen Schillig3-74/+73
There is no need for the QDIO layer to have knowledge or do things wich are done better by the FSF layer and vice versa. Straighten a few things to improve vividness. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Implicitly close all wka portsChristof Schmitt4-5/+13
An adapter shutdown implicitly closes all open ports. Make sure to mark all WKA ports as offline, not only the directory server. Also make sure that no pending wka port work is running when the adapter is being removed. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Only issue one test link command per portChristof Schmitt2-0/+10
When the FCP channel returns a series of commands with the error status "test link", zfcp will send a series of ELS ADISC commands. This is technically no problem, but it is enough to only issue one test command per remote port. So, track whether a ELS ADISC command is already pending, and do not send a new one if there is already a pending command. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Remove useless assignmentChristof Schmitt1-1/+0
Using a bitwise OR to not set anything at all is pointless so remove the useless statement. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Only collect FSF/HBA debug data for matching trace levelsChristof Schmitt3-39/+67
The default trace level is to only trace failed FSF commands. Thus it is not necessary to collect trace data for most FSF commands, since it will be thrown away later. Restructure the FSF/HBA trace infrastructure to first check the trace level in a inline function and only do the expensive data collection for matching trace levels. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Only collect SCSI debug data for matching trace levelsChristof Schmitt5-63/+73
The default trace level is to only trace failed SCSI commands. Thus it is not necessary to collect trace data for most SCSI commands since it will be thrown away later. Restructure the SCSI trace infrastructure to first check the trace level in a inline function and only do the expensive data collection for matching trace levels. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: Move debug data from zfcp_data to own data structureChristof Schmitt5-113/+143
The struct zfcp_adapter includes everything related to the debug traces. This introduces dependences between the definitions in zfcp_def.h and zfcp_dbf.h. Move all debug related data structures to a new data structure to break those dependencies and manage the debug data in zfcp_dbf.[hc]. Reviewed-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] zfcp: invalid usage after free of port resourcesSwen Schillig2-4/+9
In certain error scenarios ports, rports are getting attached, validated and removed from the systems environment. Depending on the layer this occurs asynchronously. This patch fixes the few races which existed and ensures all references and cross references are cleared at the time they're invalid. In addition fc transports actions are only scheduled when required. Signed-off-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-09-05[SCSI] scsi_dh_rdac: add support for next generation of Dell PV arrayYanqing_Liu@Dell.com1-0/+2
This patch is to add DM support for next generation of Dell PowerVault storage array. Signed-off-by: Yanqing Liu <Yanqing_Liu@Dell.com> Acked-by: Chandra Seetharaman <sekharan@us.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] update MAINTAINERS with new emailJames Bottomley1-1/+1
Novell is now funding SCSI work, so the MAINTAINERS file should reflect this. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] mptsas : Bump version to 3.04.11Kashyap, Desai1-2/+2
Bump version to 3.04.11 Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] mptsas : Code cleanup of host page alloc and diag reset.Kashyap, Desai1-54/+30
Code cleanup of host page alloc and diag reset. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] mptsas : set max_id to infinite value.Kashyap, Desai2-4/+6
Do not set max_id value received from FW. Once SAS transport layer is introduced max_id value is missleading to SCSI mid layer. Use max_id to infinite value. logic of can queue of scsi host is changed. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] mptsas : Change config request timeout value to 30 seconds.Kashyap, Desai1-9/+10
Change config request timeout value to 30 seconds. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] mptsas : Handle INSUFFICIENT resources status as similar to IOC BUSY statusKashyap, Desai1-1/+1
Handle insufficient resources status as similar to busy status. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] mptsas : Removed mptscsih_timer_expired.Kashyap, Desai6-122/+0
Removed mptscsih_timer_expired. This timer is no more use. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] mptsas : Change DEFINED value of can queue for FC and SAS devices.Kashyap, Desai2-2/+3
Change DEFINED value of can queue for FC and SAS devices. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] scsi_dh: add two SUN devices to the list of devices supported by defaultChandra Seetharaman1-0/+2
Reported-by: Rice Brown <rick.brown@oit.gatech.edu> Signed-Off-by: Chandra Seetharaman <sekharan@us.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] fix bugs in scsi_vpd_inquiry()James Bottomley1-6/+7
Universally, SCSI functions assume the lengths fed in are those of the buffer to DMA data to, not the lengths of the data minus the header. scsi_vpd_inquiry() assumed the latter and got it wrong, so fix up all the functions to use the correct assumption (and fix a bug where INQUIRY in SCSI-2 dcannot go over 255). [jejb: Matthew posted an identical version of this at the same time I did] Signed-off-by: Matthew Wilcox <matthew@wil.cx> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] reservation conflict after timeout causes device to be taken offlineMichael Reed1-1/+5
An IBM tape drive failed to complete a PERSISTENT RESERVE IN within the scsi cmd timeout. Error recovery was initiated and it sequenced from abort through taking the tape drive offline. The device was taken offline because it repeatedly responded to the TUR command issued by error recovery with a RESERVATION CONFLICT status. The tape drive was reserved to another system. This is perfectly legitimate response to TUR, and is one that an escalation of recovery is unlikely to clear. Further, escalation of recovery can have undesirable side effects on the operation of tape drives shared with other initiators. Instead of escalating recovery, error recovery should treat the RESERVATION CONFLICT response to the TUR as a good status, giving the issuer of the command the opportunity to handle the timeout and reservation conflict. Signed-off-by: Michael reed <mdr@sgi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] nsp_cs: fix buf overflowJiri Slaby1-1/+1
In nsp_cs_config there is a wrong struct nsp_cs_configdata allocation. It allocates only sizeof(pointer to nsp_cs_configdata) for a whole structure. Add a dereference to the sizeof to allocate sizeof(nsp_cs_configdata). Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] ch: Check NULL for kmalloc() returnDavidlohr Bueso A1-0/+6
Verify that ch->dt is not NULL before using it. Signed-off-by: Davidlohr Bueso <dave@gnu.org> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] ibmvscsi: avoid unnecessary use of kzalloc_poolSage Weil1-1/+1
The allocated struct is manually zeroed after allocation, so avoid using the (broken) kzalloc mempool (which does not re-zero previously used items when they are returned to the pool). Acked-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: Sage Weil <sage@newdream.net> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Update version number to 8.03.01-k5Giridhar Malavali1-1/+1
Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Fix to ensure driver works in sinlge queue mode if multiqueue failsAnirban Chakraborty6-12/+27
When the multiqueue mode fails to work, the driver falls back on single queue mode. This ensures that the firmware is reinitialized with single queue options and all the resources are readjusted accordingly. Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Correct display of vp_count in debug printk.Andrew Vasquez1-1/+2
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@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Fix a bug that clears the interrupt status register for the base queueAnirban Chakraborty1-2/+4
The interrupt handler clears the interrupt status register for response updates in the base queue while working in the multique mode. This could lead to missing interrupt for async events, mail box completions etc. as these are also handled in the base queue. The fix ensures that the interrupt bit is not cleared for response updates in the ISR when the driver is working in multiqueue mode. Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: ISP21xx/22xx do not support FDMI registrations.Andrew Vasquez1-0/+4
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@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Pad IOCB structure for size requirements.Shyam Sundar1-1/+1
One byte added to make the IOCB structure satisfy size requirements. Signed-off-by: Shyam Sundar <shyam.sundar@qlogic.com> Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Handle RSCN's per master/slave vn-port basis.Santosh Vernekar1-1/+1
Signed-off-by: Santosh Vernekar <santosh.vernekar@qlogic.com> Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Process DPC requests within valid Fabric topologies.Lalit Chandivade1-0/+3
If vports are created and topology is changed to Loop only, the driver continuously gets a LIP reset occurred and keeps trying to enable the vport. Only manage requests during F_Port. Signed-off-by: Lalit Chandivade <lalit.chandivade@qlogic.com> Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Mark all devices lost on loss of fc port.Santosh Vernekar1-0/+1
Signed-off-by: Santosh Vernekar <santosh.vernekar@qlogic.com> Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Skip RSCN processing on vha if event is global.Santosh Vernekar1-4/+20
The RSCN processing is skipped if the event received is global and vha is not recipient. Signed-off-by: Santosh Vernekar <santosh.vernekar@qlogic.com> Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Correctly handle 'global port-unavailable' AEN.Andrew Vasquez1-1/+29
Treat a global port-unavailable PORT_UPDATE (8014h) AEN as a loop-down event. For this case, within the FCoE domain, the 'logical' interface has been terminated, but the driver will not receive the classic LOOP_DOWN AEN. 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@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-22[SCSI] qla2xxx: Pass the command's data residual to upper-layer callers.Ravi Anand1-0/+1
Signed-off-by: Ravi Anand <ravi.anand@qlogic.com> Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>