summaryrefslogtreecommitdiffstats
path: root/drivers/s390
Commit message (Collapse)AuthorAgeFilesLines
* [SCSI] zfcp: Keep ccw device and model id in zfcp_ccw.cChristof Schmitt2009-05-234-16/+20
| | | | | | | | | | | Keep the information about the device and model id in zfcp_ccw. This requires an additional helper function to check for the privileged cfdc subchannel, but it allows the removal of the redundant defines from the zfcp_def header file. 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@HansenPartnership.com>
* [SCSI] zfcp: Changed D_ID left port disabledSwen Schillig2009-05-232-2/+12
| | | | | | | | | | | If the destination ID (D_ID) of a remote storage port changed, e.g. re-plugged cable on the switch in a different switch port, the port was never (re-)attached within Linux. This patch fixes the broken mapping between the WWPN and the D_ID. 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@HansenPartnership.com>
* [SCSI] zfcp: Increase ref counter for port open requestsMartin Petermann2009-05-231-3/+9
| | | | | | | | | | | In rare cases, open port request might timeout, erp calls zfcp_port_put, port gets dequeued. Now, the late returning (or dismissed) fsf-port-open calls the fsf_port_open_handler that tries to reference the port data structure leading to a kernel oops. Signed-off-by: Martin Petermann <martin.petermann@de.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: Add comments to switch/case fallthroughsChristof Schmitt2009-05-232-0/+6
| | | | | | | | | | Add comments where there is a deliberate fall through in switch/case statements. This makes some code checkers happy and makes it clear that there is no missing break 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@HansenPartnership.com>
* [SCSI] zfcp: Remove unnecessary default case and assignmentsChristof Schmitt2009-05-231-8/+2Star
| | | | | | | | | | | | | | enum dma_data_direction only has the 4 values DMA_BIDIRECTIONAL, DMA_TO_DEVICE, DMA_FROM_DEVICE and DMA_NONE. No need to have the default case. While changing this, setup sbtype in one place to make sparse happy. The default value of retval is already -EIO, so remove the additional assignment for these two cases. 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@HansenPartnership.com>
* [SCSI] zfcp: Make queue_depth adjustableChristof Schmitt2009-05-231-1/+12
| | | | | | | | | | | zfcp did always set the queue_depth for SCSI devices to 32, not allowing to change this. Introduce a kernel parameter zfcp.queue_depth and the change_queue_depth callback to allow changing the queue_depth when it is required. 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@HansenPartnership.com>
* [SCSI] zfcp: Update message and add descriptionChristof Schmitt2009-05-231-2/+2
| | | | | | | | | Update the newly introduced message for the boxed status to conform to match the style of s390 and zfcp messages. 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@HansenPartnership.com>
* [SCSI] zfcp: Use correct req_id for tracesChristof Schmitt2009-05-231-5/+5
| | | | | | | | | The zfcp traces used the fsf_req address in place of the req_id. Change this to save the correct req_id. 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@HansenPartnership.com>
* [SCSI] zfcp: Fix oops when port disappearsChristof Schmitt2009-04-273-8/+24
| | | | | | | | | | | The zfcp_port might have been removed, while the FC fast_io_fail timer is still running and could trigger the terminate_rport_io callback. Set the pointer to the zfcp_port to NULL and check accordingly before using it. Reviewed-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: Reference counting for cfdc requestsChristof Schmitt2009-04-271-1/+2
| | | | | | | | | Before dropping the reference count with zfcp_adapter_put, increase it with zfcp_adapter_get when issuing cfdc requests. Reviewed-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: Fix port reference countingMartin Petermann2009-04-271-3/+4
| | | | | | | | | | | | If this problem appears zfcp ports cannot be de-queued since it is checked for a zero refcount. The port reference counting is wrong for existing zfcp ports when e.g. an adapter gets on-line again. During port scanning the reference counting for existing ports should not be changed. Signed-off-by: Martin Petermann <martin.petermann@de.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: revert previous patch for sbal countingMartin Petermann2009-04-271-14/+14
| | | | | | | | | | | The current sbal counting can be wrong if a fsf request is waiting for free sbals and at the same time qdio request queue is shutdown and re-opened. Revering a previous patch fixes this issue. Signed-off-by: Martin Petermann <martin.petermann@de.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: Fix abort handler for completions in progressChristof Schmitt2009-04-271-1/+1
| | | | | | | | | | | When the abort handler cannot find a pending FSF request, the request completion could just be running. This means we cannot return SUCCESS, since this would lead to call to scsi_done after exiting the SCSI error handler which is not allowed. Reviewed-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: no port recovery after ADISC request timeoutSwen Schillig2009-04-271-1/+2
| | | | | | | | | | | A remote port remains in error state even if we receive a RSCN stating that the connection is re-established. The port recovery is not started due to a flag which is not reset. The solution is to clear the flag in question before we trigger a ERP. 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@HansenPartnership.com>
* [SCSI] zfcp: Let actcli handle control file errorsChristof Schmitt2009-04-271-2/+0Star
| | | | | | | | | | Error codes specific to the control file requests are evaluated by the actcli tool, so don't report -ENXIO for those. Generic problems are still checked for outside the command specific handler. Reviewed-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: remove unit will fail if add unit is not finishedMartin Petermann2009-04-271-6/+15
| | | | | | | | | | On some hardware it can take some time to add a unit. If some remove this unit during this process the remove will fail. Signed-off-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: no port recovery after storage side error injectSwen Schillig2009-04-271-5/+0Star
| | | | | | | | | | | | The remote port remains in error state even if the connection is re-established. A wrong precondition check was performed on the port status leading to a cancellation of the port reopen. Remove the pre-req check because it's not required and better handled within the ERP. 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@HansenPartnership.com>
* [SCSI] zfcp: avoid false ERP complete due to sema raceSwen Schillig2009-04-271-4/+5
| | | | | | | | | | | | | | | | The ERP thread is performing a task before it is executing the corresponding down on the semaphore. The response handler of the just started exchange config should wait for the completion by performing a down on this semaphore. Since this semaphore is still positive from the ERP enqueue the handler won't wait and therefore the exchange config will always fail leaving the adapter in error. The problem can be solved by performing the down on the semaphore before starting an ERP task. This is the logically correct order. Only walk the ERP loop if there is a task to perform. 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@HansenPartnership.com>
* [SCSI] zfcp: Set WKA-port to offline on adapter deactivationSwen Schillig2009-04-275-9/+12
| | | | | | | | | | | | | | | The nameserver port might be in state online when the adapter is offlined. On adapter reactivation the nameserver port is not re-opened due to the PORT_ONLINE status. This results in an unsuccessful recovery. In forcing the nameserver port status to offline on all adapter offline events this issue is prevented. Waiting for the reference count to drop to zero in zfcp_wka_port_offline is not required, so remove it. 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@HansenPartnership.com>
* [SCSI] zfcp: Dont block zfcp_wq with scanSwen Schillig2009-04-275-50/+25Star
| | | | | | | | | | | When running the scsi_scan from the zfcp workqueue and the target device does not respond, the zfcp workqueue can block until the scsi_scan hits a timeout. Move the work to the scsi host workqueue, since this one is also used for the scan from the SCSI midlayer. 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@HansenPartnership.com>
* [SCSI] zfcp: Dont call zfcp_fsf_req_free on NULL pointerChristof Schmitt2009-04-271-6/+12
| | | | | | | | | | Fix problem that zfcp_fsf_exchange_config_data_sync and zfcp_fsf_exchange_config_data_sync could try to call zfcp_fsf_req_free with a NULL pointer. Reviewed-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [SCSI] zfcp: Enable auto-port discovery for NPIV.Swen Schillig2009-04-271-1/+2
| | | | | | | | | | Since we're setting the host port type now to FC_PORTTYPE_NPIV for adapters running in NPIV mode we should allow this port type for auto-port scanning as well. 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@HansenPartnership.com>
* [SCSI] zfcp: Avoid referencing freed memory in req sendMartin Petermann2009-04-271-3/+4
| | | | | | | | | Avoid referencing a fsf request after sending it in fcp_fsf_req_send, it might have already completed and deallocated. Signed-off-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
* [S390] Use tape_generic_offline directly.Frank Munzert2009-04-234-16/+7Star
| | | | | | | | tape_3590_offline and tape_34xx_offline are removed and tape_generic_offline is called directly instead. Signed-off-by: Frank Munzert <munzert@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* [S390] dasd: fix idaw boundary checking for track based ccwStefan Weinhuber2009-04-141-4/+12
| | | | | | | | | | | | | A ccw command that reads or writes several records at once will usually transfer more data then fits into one page and needs to address memory areas using a list of indirect data address words (idaw). All but the first of these areas must start on a 4KB or 2KB block boundary (depending on the idaw format). A check for this restriction was missing and has been added with this patch. Signed-off-by: Stefan Weinhuber <wein@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* [S390] dasd: Use the new async framework for autoonlining.Cornelia Huck2009-04-141-12/+25
| | | | | | | | | | | | | | The dasd driver can automatically online detected dasds, which especially important for finding the root device. Currently, it will wait for each online operation to finish individually, which may take long if many dasds need to be onlined. When using the new async framework, these onlining operations can run in parallel and presence of the root device is ensured by the fact that prepare_namespace() waits for all async threads to finish. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Stefan Haberland <stefan.haberland@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* [S390] qdio: remove dead timeout handlerJan Glauber2009-04-141-41/+2Star
| | | | | | | | | | | The QDIO ccw devices are started by ccw_device_start so no timeout can occur for the interrupt handler. Remove the dead code. In case of an I/O error set the device state to error and wake up a possibly running qdio_shutdown waiter. Signed-off-by: Jan Glauber <jang@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* workqueue: add to_delayed_work() helper functionJean Delvare2009-04-031-1/+1
| | | | | | | | | | | | | | | | | | | It is a fairly common operation to have a pointer to a work and to need a pointer to the delayed work it is contained in. In particular, all delayed works which want to rearm themselves will have to do that. So it would seem fair to offer a helper function for this operation. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Ingo Molnar <mingo@elte.hu> Cc: "David S. Miller" <davem@davemloft.net> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Greg KH <greg@kroah.com> Cc: Pekka Enberg <penberg@cs.helsinki.fi> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* qeth: properly delete empty files.Linus Torvalds2009-04-012-0/+0
| | | | | | | | | | | | | Commit 64ef8957986f6a04f61e7c95fa6ffeb3a86a6661 ("qeth: remove EDDP") removed the qeth_core_offl.[hc] files, but ended up doing so by just patching them to zero size, rather than removing them properly. Actually remove the files. Reported-by: Andrew Price <andy@andrewprice.me.uk> Cc: Frank Blaschka <frank.blaschka@de.ibm.com> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [S390] cio: online_store - trigger recognition for boxed devicesSebastian Ott2009-03-311-1/+1
| | | | | | | | | Start a new device recognition if someone writes to sysfs online attribute of a boxed ccw device. The current test will fail, since cu_type != 0 for devices which were recognized before. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* [S390] cio: disallow online setting of device in transient stateSebastian Ott2009-03-311-1/+5
| | | | | | | | Return -EAGAIN on writes to sysfs online attribute if the corresponding ccw device is in transient state. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* [S390] cio: introduce notifier for boxed stateSebastian Ott2009-03-314-13/+26
| | | | | | | | | | | | | If a ccw device did not respond in time during internal io, we set it into boxed state. With this patch we have the following behaviour: * the ccw driver will get a notification if the device was online and goes into the boxed state * if the device was disconnected and got boxed nothing special is to be done (it will be handled in reprobing later) * if the device got boxed while initial sensing it will be unregistered Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* [S390] cio: introduce ccw_device_schedule_sch_unregisterSebastian Ott2009-03-312-10/+12
| | | | | | | | | Introduce ccw_device_schedule_sch_unregister as a wrapper for queuing ccw_device_call_sch_unregister on the slow_path_wq. This wrapper will be used in the next patch. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* [S390] cio: wake up on failed recognitionSebastian Ott2009-03-312-4/+10
| | | | | | | | | | Wake up even on failed device recognition, since this may be triggered from a user trying to force a device online. With this patch a write to the online sysfs attribute will not block for ever but return with -EAGAIN in this case. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
* proc 2/2: remove struct proc_dir_entry::ownerAlexey Dobriyan2009-03-301-2/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Setting ->owner as done currently (pde->owner = THIS_MODULE) is racy as correctly noted at bug #12454. Someone can lookup entry with NULL ->owner, thus not pinning enything, and release it later resulting in module refcount underflow. We can keep ->owner and supply it at registration time like ->proc_fops and ->data. But this leaves ->owner as easy-manipulative field (just one C assignment) and somebody will forget to unpin previous/pin current module when switching ->owner. ->proc_fops is declared as "const" which should give some thoughts. ->read_proc/->write_proc were just fixed to not require ->owner for protection. rmmod'ed directories will be empty and return "." and ".." -- no harm. And directories with tricky enough readdir and lookup shouldn't be modular. We definitely don't want such modular code. Removing ->owner will also make PDE smaller. So, let's nuke it. Kudos to Jeff Layton for reminding about this, let's say, oversight. http://bugzilla.kernel.org/show_bug.cgi?id=12454 Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6Linus Torvalds2009-03-2813-676/+586Star
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (119 commits) [SCSI] scsi_dh_rdac: Retry for NOT_READY check condition [SCSI] mpt2sas: make global symbols unique [SCSI] sd: Make revalidate less chatty [SCSI] sd: Try READ CAPACITY 16 first for SBC-2 devices [SCSI] sd: Refactor sd_read_capacity() [SCSI] mpt2sas v00.100.11.15 [SCSI] mpt2sas: add MPT2SAS_MINOR(221) to miscdevice.h [SCSI] ch: Add scsi type modalias [SCSI] 3w-9xxx: add power management support [SCSI] bsg: add linux/types.h include to bsg.h [SCSI] cxgb3i: fix function descriptions [SCSI] libiscsi: fix possbile null ptr session command cleanup [SCSI] iscsi class: remove host no argument from session creation callout [SCSI] libiscsi: pass session failure a session struct [SCSI] iscsi lib: remove qdepth param from iscsi host allocation [SCSI] iscsi lib: have lib create work queue for transmitting IO [SCSI] iscsi class: fix lock dep warning on logout [SCSI] libiscsi: don't cap queue depth in iscsi modules [SCSI] iscsi_tcp: replace scsi_debug/tcp_debug logging with iscsi conn logging [SCSI] libiscsi_tcp: replace tcp_debug/scsi_debug logging with session/conn logging ...
| * [SCSI] zfcp: Report fc_host_port_type as NPIVChristof Schmitt2009-03-121-2/+3
| | | | | | | | | | | | | | | | | | | | Report the fc_host_port_type as FC_PORTTYPE_NPIV when the subchannel is running in NPIV mode. This allows to see the correct type with lsscsi -H -t --list Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
| * [SCSI] zfcp: Ensure all work is cancelled on adapter dequeueSwen Schillig2009-03-123-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | A scheduled work might still be pending, running while the adapter is in progress to get dequeued from the system. This can lead to an invalid pointer dereference (Oops). Once the adpater is set online again, ensure the nameserver environment is initialized to the appropriate values again. 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@HansenPartnership.com>
| * [SCSI] zfcp: fix queue, scheduled work processing.Swen Schillig2009-03-122-3/+8
| | | | | | | | | | | | | | | | | | | | | | Ensure the refcounting is correct even if we were not able to schedule a work. In addition we have to make sure no scheduled work is pending while we're dequeing the adapter from the systems environment. 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@HansenPartnership.com>
| * [SCSI] zfcp: erp failed status bit will not be setMartin Petermann2009-03-121-1/+0Star
| | | | | | | | | | | | | | | | | | | | | | It will not be necessary to set the erp failed status bit in case a SCSI device is removed by the SCSI mid layer. In the case a SCSI device is unavailable for a short time (15 to 20 seconds) a FCP unit will not get on-line again. Signed-off-by: Martin Petermann <martin@linux.vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
| * [SCSI] zfcp: Block FC transport rports early on errorsChristof Schmitt2009-03-127-56/+157
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use the I/O blocking mechanism in the FC transport class to allow faster failovers for multipathing: - Call fc_remote_port_delete early to set the rport to BLOCKED. - Check the rport status in queuecommand with fc_remote_portchkready to no longer accept new I/O for this port and fail the I/O with the appropriate scsi_cmnd result. - Implement the terminate_rport_io handler to abort all pending I/O requests - Return SCSI commands with DID_TRANSPORT_DISRUPTED while erp is running. - When updating the remote port status, check for late changes and update the remote ports status accordingly. Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
| * [SCSI] zfcp: incorrect reaction on incoming RSCNSwen Schillig2009-03-122-15/+7Star
| | | | | | | | | | | | | | | | | | | | After an error condition resolved a remote storage port was never re-opened. The incoming RSCN was not processed accordingly due to a misinterpreted status flag / return value combination. 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@HansenPartnership.com>
| * [SCSI] zfcp: Remove PCI flagChristof Schmitt2009-03-122-22/+3Star
| | | | | | | | | | | | | | | | | | | | | | The usage of the PCI flag to trigger interrupts is optional. Even without setting the flag, qdio still receives interrupts to continue working on the queue. Remove the PCI flag from zfcp, it is not necessary. Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
| * [SCSI] zfcp: replace current ERP logging with a more convenient versionSwen Schillig2009-03-1211-356/+215Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current number based id ERP logging is replaced by a string based tag version. The benefit is an easier location of the code in question and the removal of the lengthy array referencing the individual messages. The string (7 bytes) based version does not use more space since those bytes were "used" anyway due to the alignment of the structure. The encoding of the 7 byte string is as follows [0-1] = filename [2-5] = task/function [6] = section Due to the character of this string (fixed length) a string termination is not required here. 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@HansenPartnership.com>
| * [SCSI] zfcp: prevent adapter close on initial adapter openSwen Schillig2009-03-121-35/+34Star
| | | | | | | | | | | | | | | | | | | | | | An adapter close was always performed whether it was required, (e.g. in an error scenario) or not (e.g. initial open). This patch is changing the process in only doing an adapter close when it is 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@HansenPartnership.com>
| * [SCSI] zfcp: remove undefined subtype for status read responseSwen Schillig2009-03-123-13/+2Star
| | | | | | | | | | | | | | | | | | | | The status read response FSF_STATUS_READ_SUB_ERROR_PORT is not defined in the specs and therefore not valid. All occurrences are removed from the code. 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@HansenPartnership.com>
| * [SCSI] zfcp: Send ELS ADISC from workqueueChristof Schmitt2009-03-125-22/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | Issue ELS ADISC requests from workqueue. This allows the link test request to be sent when the request queue is full due to I/O load for other remote ports. It also simplifies request queue locking, zfcp_fsf_send_fcp_command_task is now the only function that has interrupts disabled from the caller. This is also a prereq for the FC passthrough support that issues ELS requests from userspace. Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
| * [SCSI] zfcp: Improve reliability of SCSI eh handlers in zfcpChristof Schmitt2009-03-124-99/+78Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When the SCSI midlayer is running error recovery, the low-level error recovery in zfcp could be running and preventing the SCSI midlayer to issue error recovery requests. To avoid unnecessary error recovery escalation, wait for the zfcp erp to finish and retry if necessary. While reworking the SCSI eh handlers, alsa cleanup the code and simplify the interface from zfcp_scsi to the fsf layer. Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
| * [SCSI] zfcp: Wait for free SBALs when possibleChristof Schmitt2009-03-121-9/+9
| | | | | | | | | | | | | | | | | | For calls from zfcp erp, scsi_eh and sysfs switch the calls issuing FSF requests to zfcp_fsf_req_sbal_get to wait for free SBALs. Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
| * [SCSI] zfcp: Only increment req_id for successfully issued requestsChristof Schmitt2009-03-121-1/+2
| | | | | | | | | | | | | | | | | | Only increment the req_id for successfully issued requests. This avoids some confusion when debugging issued fsf requests. Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>