aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi (follow)
AgeCommit message (Collapse)AuthorFilesLines
2009-08-14[SCSI] mpt2sas: fix config request and diag reset deadlockKashyap, Desai1-65/+20
Moving the setting and clearing of the mutex's to _config_request. There was a mutex deadlock when diag reset is called from inside _config_request, so diag reset was moved to outside the mutexs. Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: Bump driver version 01.100.04.00Kashyap, Desai1-2/+2
Bump version to 01.100.04.00 Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: fix oops because drv data points to NULL on resume from hibernateKashyap, Desai1-3/+3
Fix another ocurring when the system resumes. This oops was due to driver setting the pci drvdata to NULL on the prior hibernation. Becuase it was set to NULL, upon resmume we assume the pci drvdata is non-zero, and we oops. To fix the ooops, we don't set pci drvdata to NULL at hibernation time. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: fix crash due to Watchdog is active while OS in standby modeKashyap, Desai3-28/+64
Fix oops ocurring at hibernation time. This oops was due to the firmware fault watchdog timer still running after we freed resources. To fix the issue we need to terminate the watchdog timer at hibernation time. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: fix infinite loop inside config requestKashyap, Desai1-0/+6
This restriction is introduced just to avoid loop of config_request. Retry must be limited so we have restricted config request to maximum 2 times. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: Excessive log info causes sas iounit page time outKashyap, Desai2-0/+8
Inhibit 0x3117 loginfos - during cable pull, there are too many printks going to the syslog, this is have impact on how fast the interrupt routine can handle keeping up with command completions; this was the root cause to the config pages timeouts. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: Raid 10 Value is showing as Raid 1E in /va/log/messagesKashyap, Desai1-26/+64
When a volume is activated, the driver will recieve a pair of ir config change events to remove the foreign volume, then add the native. In the process of the removal event, the hidden raid componet is removed from the parent.When the disks is added back, the adding of the port fails becuase there is no instance of the device in its parent. To fix this issue, the driver needs to call mpt2sas_transport_update_links() prior to calling _scsih_add_device. In addition, we added sanity checks on volume add and removal to ignore events for foreign volumes. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: Expander fix oops saying "Already part of another port"Kashyap, Desai1-6/+15
Kernel panic is seen because driver did not tear down the port which should be dnoe using mpt2sas_transport_port_remove(). without this fix When expander is added back we would oops inside sas_port_add_phy. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-13[SCSI] mpt2sas: Introduced check for enclosure_handle to avoid crashKashyap, Desai1-4/+3
Kernel panic is seen because of enclosure_handle received from FW is zero. Check is introduced before calling mpt2sas_config_get_enclosure_pg0. Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
2009-08-04Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6Linus Torvalds1-2/+2
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (47 commits) ehea: Fix napi list corruption on ifconfig down igbvf: Allow VF driver to correctly recognize failure to set mac 3c59x: Fix build failure with gcc 3.2 sky2: Avoid transmits during sky2_down() iwlagn: do not send key clear commands when rfkill enabled libertas: Read buffer overflow drivers/net/wireless: introduce missing kfree drivers/net/wireless/iwlwifi: introduce missing kfree zd1211rw: fix unaligned access in zd_mac_rx cfg80211: fix regression on beacon world roaming feature cfg80211: add two missing NULL pointer checks ixgbe: Patch to modify 82598 PCIe completion timeout values bluetooth: rfcomm_init bug fix mlx4_en: Fix double pci unmapping. mISDN: Fix handling of receive buffer size in L1oIP pcnet32: VLB support fixes pcnet32: remove superfluous NULL pointer check in pcnet32_probe1() net: restore the original spinlock to protect unicast list netxen: fix coherent dma mask setting mISDN: Read buffer overflow ...
2009-07-30iscsi: Use GFP_ATOMIC in iscsi_offload_mesg().Michael Chan1-2/+2
Changing to GFP_ATOMIC because the only caller in cnic/bnx2i may be calling this function while holding spin_lock. This problem was discovered by Mike Christie. Signed-off-by: Michael Chan <mchan@broadcom.com> Acked-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-07-30[SCSI] sd: Avoid sending extended inquiry to legacy devicesMartin K. Petersen1-2/+18
Some USB devices crash when we send them an inquiry with the EVPD bit set, regardless of page requested (i.e. including page 0). We only need the extended inquiry to gain access to VPD pages 0xB0 and 0xB1. These appeared in SBC2 and SBC3 respectively, so we can restrict sending the extended inquiry to devices reporting SPC3 or higher. This fixes bugzilla.kernel.org #13657. Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> [jejb: added comment] Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] libsas: fix wide port hotplug issuesTom Peng1-40/+107
Hotplug of phys which form wide ports simply does not work at the moment. Fix this by adding checks at the hotplug points to see if the attached sas address of the phy already exists (in which case it's part of a wide port) and act accordingly. Signed-off-by: Tom Peng <tom_peng@usish.com> Signed-off-by: Jack Wang <jack_wang@usish.com> Signed-off-by: Lindar Liu <lindar_liu@usish.com> Signed-off-by: Kevin Ao <aoqingyun@usish.com> [jejb: tidied up coding, fixed an error case and made TRUE/FALSE lower case to fix a ppc64 compile error in linux-next] Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] libfc: fix a circular locking warning during sending RRQVasu Dev1-8/+15
Currently the fc_exch_rrq is called with fc_exch's ex_lock held. The fc_exch_rrq allocates new exch and that requires taking ex_lock again after EM lock. This locking order causes warning, see more details on this warning at :- http://www.open-fcoe.org/pipermail/devel/2009-July/003251.html This patch fixes this by dropping the ex_lock before calling fc_exch_rrq(). The fc_exch_rrq needs to grab ex_lock lock again to schedule RRQ retry and in the meanwhile fc_exch_reset could occur before ex_lock is grabbed inside fc_exch_rrq. So to handle this case, this patch adds additional check to detect fc_exch_reset after ex_lock acquired and in case the fc_exch_reset occurred then abandons the RRQ retry and releases the exch. Signed-off-by: Vasu Dev <vasu.dev@intel.com> Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] qla4xxx: Remove hiwat code so scsi eh does not get escalated when we can make progressKaren Higgins3-85/+60
Removed unnecessary hiwat code to free up the number available IOCBs. Eliminates unnecessary eh_ escalations due to inability to obtain IOCB pkt for marker. v2. - Remove define not used anymore and fix req_q_coun accounting. Signed-off-by: Karen Higgins <karen.higgins@qlogic.com> [michaelc: ported patch from qlogic.com driver to upstream] Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] qla4xxx: Fix srb lookup in qla4xxx_eh_device_resetKaren Higgins1-3/+1
eh_device_reset may be called from scsi error handler or sg_reset, etc. When called from sg_reset, there will not be an associated srb. The driver should lookup the corresponding device handle given information from the supplied cmd structure and should not assume that there exists an srb. Signed-off-by: Karen Higgins <karen.higgins@qlogic.com> Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] qla4xxx: Fix Driver Fault Recovery CompletionKaren Higgins1-10/+9
Fixed driver bug where adapter recovery did not complete if there were outstanding commands detected on that host adapter. Signed-off-by: Karen Higgins <karen.higgins@qlogic.com> Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] qla4xxx: add timeout handlerMike Christie1-0/+17
Recently dm-multipath began calling blk_abort_queue. This causes all the commands/request running on the path to have the timeout function called. If a path does go down, and the LLD returns DID_*, dm-multpiath will eventually get this error and begin to call the cmd timeout handler. qla4xxx currently does not set a timed out handler and so the default one could return BLK_EH_NOT_HANDLED and end up firing the scsi eh and stopping IO to all paths on the host when only one path is affected. For software and offload iscsi we have a timed out handler already. This patch adds a driver specific one to qla4xxx because there are some ddb->state and session->state and command completion races that are better handled in the LLD. This also handles the problem where if the session is down, we do not need the scsi eh to run until the transport code has tried to reconnect us. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] qla4xxx: Correct Extended Sense Data ErrorsKaren Higgins5-54/+122
Fixed sense data errors occurring above the first 32 bytes, as required by some third party applications. Sense data in the first 32 bytes has always been correct. Patch updated to use srb data variables instead of scsi command scratchpad data area, as scratchpad area is already used. Also, corrected debug print alignment bug in dump_buffer routine. Changed KERN_DEBUG to KERN_INFO in printk statements in this routine. Changed version number to 5.01.00-k9 Signed-off-by: Karen Higgins <karen.higgins@qlogic.com> [michaelc: fixed checkpath.pl errors] Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-30[SCSI] libiscsi: disable bh in and abort handler.Mike Christie1-2/+2
The session lock can be held in the scsi eh thread or the completion paths run from the net softirq. This disables bhs in iscsi_eh_abort when taking the session lock. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-16[SCSI] libsas: reuse the original port when hotplugging phys in wide portsTom Peng1-4/+15
There's a hotplug problem in the way libsas allocates ports: it loops over the available ports first trying to add to an existing for a wide port and otherwise allocating the next free port. This scheme only works if the port array is packed from zero, which fails if a port gets hot unplugged and the array becomes sparse. In that case, a new port is formed even if there's a wide port it should be part of. Fix this by creating two loops over all the ports: the first to see if the phy should be part of a wide port and the second to form a new port in an empty port slot. Signed-off-by: Tom Peng <tom_peng@usish.com> Signed-off-by: Jack Wang <jack_wang@usish.com> Signed-off-by: Lindar Liu <lindar_liu@usish.com> Cc: Stable Tree <stable@kernel.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-07-12headers: smp_lock.h reduxAlexey Dobriyan1-1/+0
* Remove smp_lock.h from files which don't need it (including some headers!) * Add smp_lock.h to files which do need it * Make smp_lock.h include conditional in hardirq.h It's needed only for one kernel_locked() usage which is under CONFIG_PREEMPT This will make hardirq.h inclusion cheaper for every PREEMPT=n config (which includes allmodconfig/allyesconfig, BTW) Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-07-10block: fix sg SG_DXFER_TO_FROM_DEV regressionFUJITA Tomonori1-0/+4
I overlooked SG_DXFER_TO_FROM_DEV support when I converted sg to use the block layer mapping API (2.6.28). Douglas Gilbert explained SG_DXFER_TO_FROM_DEV: http://www.spinics.net/lists/linux-scsi/msg37135.html = The semantics of SG_DXFER_TO_FROM_DEV were: - copy user space buffer to kernel (LLD) buffer - do SCSI command which is assumed to be of the DATA_IN (data from device) variety. This would overwrite some or all of the kernel buffer - copy kernel (LLD) buffer back to the user space. The idea was to detect short reads by filling the original user space buffer with some marker bytes ("0xec" it would seem in this report). The "resid" value is a better way of detecting short reads but that was only added this century and requires co-operation from the LLD. = This patch changes the block layer mapping API to support this semantics. This simply adds another field to struct rq_map_data and enables __bio_copy_iov() to copy data from user space even with READ requests. It's better to add the flags field and kills null_mapped and the new from_user fields in struct rq_map_data but that approach makes it difficult to send this patch to stable trees because st and osst drivers use struct rq_map_data (they were converted to use the block layer in 2.6.29 and 2.6.30). Well, I should clean up the block layer mapping API. zhou sf reported this regiression and tested this patch: http://www.spinics.net/lists/linux-scsi/msg37128.html http://www.spinics.net/lists/linux-scsi/msg37168.html Reported-by: zhou sf <sxzzsf@gmail.com> Tested-by: zhou sf <sxzzsf@gmail.com> Cc: stable@kernel.org Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
2009-07-08Remove multiple KERN_ prefixes from printk formatsJoe Perches4-7/+6
Commit 5fd29d6ccbc98884569d6f3105aeca70858b3e0f ("printk: clean up handling of log-levels and newlines") changed printk semantics. printk lines with multiple KERN_<level> prefixes are no longer emitted as before the patch. <level> is now included in the output on each additional use. Remove all uses of multiple KERN_<level>s in formats. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-07-04Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-fixesLinus Torvalds1-1/+1
* git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-fixes: kbuild: finally remove the obsolete variable $TOPDIR gitignore: ignore scripts/ihex2fw Kbuild: Disable the -Wformat-security gcc flag gitignore: ignore gcov output files kbuild: deb-pkg ship changelog Add new __init_task_data macro to be used in arch init_task.c files. asm-generic/vmlinux.lds.h: shuffle INIT_TASK* macro names in vmlinux.lds.h Add new macros for page-aligned data and bss sections. asm-generic/vmlinux.lds.h: Fix up RW_DATA_SECTION definition.
2009-07-02Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6Linus Torvalds6-13/+20
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6: [SCSI] cxgb3i: fix connection error when vlan is enabled [SCSI] FC transport: Locking fix for common-code FC pass-through patch [SCSI] zalon: fix oops on attach failure [SCSI] fnic: use DMA_BIT_MASK(nn) instead of deprecated DMA_nnBIT_MASK [SCSI] fnic: remove redundant BUG_ONs and fix checks on unsigned [SCSI] ibmvscsi: Fix module load hang
2009-07-01block: get rid of queue-private command filterJens Axboe1-3/+1
The initial patches to support this through sysfs export were broken and have been if 0'ed out in any release. So lets just kill the code and reclaim some space in struct request_queue, if anyone would later like to fixup the sysfs bits, the git history can easily restore the removed bits. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
2009-06-27[SCSI] cxgb3i: fix connection error when vlan is enabledKaren Xie1-0/+4
There is a bug when VLAN is configured on the cxgb3 interface, the iscsi conn. would be denied with message "cxgb3i: NOT going through cxgbi device." This patch adds code to get the real egress net_device when vlan is configured. Signed-off-by: Karen Xie <kxie@chelsio.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-27kbuild: finally remove the obsolete variable $TOPDIRAmerigo Wang1-1/+1
TOPDIR is obsolete, it can be finally removed now. Signed-off-by: WANG Cong <amwang@redhat.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2009-06-26[SCSI] FC transport: Locking fix for common-code FC pass-through patchChristof Schmitt1-2/+3
Fix this: ------------[ cut here ]------------ Badness at block/blk-core.c:244 CPU: 0 Tainted: G W 2.6.31-rc1-00004-gd3a263a #3 Process zfcp_wq (pid: 901, task: 000000002fb7a038, ksp: 000000002f02bc78) Krnl PSW : 0704300180000000 00000000002141ba (blk_remove_plug+0xb2/0xb8) R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:0 CC:3 PM:0 EA:3 Krnl GPRS: 0000000000000001 0000000000000001 0000000022811440 0000000022811798 000000000027ff4e 0000000000000000 0000000000000000 000000002f00f000 070000000006a0f4 000000002af70000 000000002af2a800 00000000228d1c00 0000000022811440 000000000050c708 000000002f02bca8 000000002f02bc80 Krnl Code: 00000000002141b0: b9140022 lgfr %r2,%r2 00000000002141b4: 07fe bcr 15,%r14 00000000002141b6: a7f40001 brc 15,2141b8 >00000000002141ba: a7f4ffbe brc 15,214136 00000000002141be: 0707 bcr 0,%r7 00000000002141c0: ebaff0680024 stmg %r10,%r15,104(%r15) 00000000002141c6: c0d00017c2a9 larl %r13,50c718 00000000002141cc: a7f13fc0 tmll %r15,16320 Call Trace: ([<000000000050e7d8>] C.272.16122+0x88/0x110) [<00000000002141ec>] __blk_run_queue+0x2c/0x154 [<000000000028013a>] fc_remote_port_add+0x85e/0x95c [<000000000037596e>] zfcp_scsi_rport_work+0xe6/0x148 [<000000000006908c>] worker_thread+0x25c/0x318 [<000000000006f10c>] kthread+0x94/0x9c [<000000000001c2b2>] kernel_thread_starter+0x6/0xc [<000000000001c2ac>] kernel_thread_starter+0x0/0xc INFO: lockdep is turned off. Last Breaking-Event-Address: [<00000000002141b6>] blk_remove_plug+0xae/0xb8 The FC pass-through support triggers the WARN_ON(!irqs_disabled()) in blk_plug_device. Since blk_plug_device requires being called with disabled interrupts, use spin_lock_irqsave in fc_bsg_goose_queue to disable the interrupts before calling into the block layer. Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Acked-by: James Smart <james.smart@emulex.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-25[SCSI] zalon: fix oops on attach failureJames Bottomley1-1/+1
I recently discovered on my zalon that if the attachment fails because of a bus misconfiguration (I scrapped my HVD array, so the card is now unterminated) then the system oopses. The reason is that if ncr_attach() returns NULL (signalling failure) that NULL is passed by the goto failed straight into ncr_detach() which oopses. The fix is just to return -ENODEV in this case. Cc: Stable Tree <stable@kernel.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-25[SCSI] fnic: use DMA_BIT_MASK(nn) instead of deprecated DMA_nnBIT_MASKAbhijeet Joglekar1-4/+4
Robert Love reported warning while building fnic_main.c: drivers/scsi/fnic/fnic_main.c:478: warning: `DMA_nnBIT_MASK' is deprecated. Replaced use of DMA_nnBIT_MASK by DMA_BIT_MASK(nn) Signed-off-by: Abhijeet Joglekar <abjoglek@cisco.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-25[SCSI] fnic: remove redundant BUG_ONs and fix checks on unsignedRoel Kluin1-5/+2
The shost sg tablesize is set to FNIC_MAX_SG_DESC_CNT and fnic uses scsi_dma_map, so both BUG_ONs can be removed. scsi_dma_map may return -ENOMEM, sg_count should be int to catch that. Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-25[SCSI] ibmvscsi: Fix module load hangBrian King1-1/+6
Fixes a regression seen in the ibmvscsi driver when using the VSCSI server in SLES 9 and SLES 10. The VSCSI server in these releases has a bug in it in which it does not send responses to unknown MADs. Check the OS Type field in the adapter info response and do not send these unsupported commands when talking to an older server. Signed-off-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21[SCSI] scsi_transport_fc: replace BUS_ID_SIZE by fixed countJames Bottomley1-1/+1
BUS_ID_SIZE is being removed from the kernel. Cc: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21sd, sr: fix Driver 'sd' needs updating messageHannes Reinecke5-18/+3
If a SCSI ULD driver sets blk_queue_prep_rq(), it should clean it up itself on remove(), and not from the bus callbacks. This removes the need to hook into bus->remove(), which should not be used at the same time as driver->remove(). [jejb: fix sdkp initialisation problem due to mismerge] Signed-off-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21scsi_transport_iscsi: return -EOVERFLOW for Too many iscsi targetsJaswinder Singh Rajput1-0/+1
setting err as -EOVERFLOW for Too many iscsi targets. Also fixes a spurious compiler warning for gcc 4.3.3 and gcc 4.4 : CC drivers/scsi/scsi_transport_iscsi.o drivers/scsi/scsi_transport_iscsi.c: In function ‘iscsi_add_session’: drivers/scsi/scsi_transport_iscsi.c:678: warning: ‘err’ may be used uninitialized in this function Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com> Acked-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21fc_transport: Selective return value from BSG timeout functionGiridhar Malavali1-1/+4
The return value from BSG timout function should be based on the state of the BSG job. This helps block layer to take selective actions to clean up BSG job. Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Acked-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21fc_transport: The softirq_done function registration for BSG requestGiridhar Malavali1-18/+19
Registered the softirq_done function, since this is requried iby an request using block level request timeout functionality. This function will be called by the block layer as part of time out clean process to release the BSG request. Moved some of the BSG request completion activities to softirq_done routine to take care of both normal and timout completions. Signed-off-by: Giridhar Malavali <giridhar.malavali@qlogic.com> Acked-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21sym53c8xx: ratelimit parity errorsJohn Stoffel1-2/+3
This makes a huge difference when you have a serial console on bootup to limit these messages to a sane number. Signed-off-by: John Stoffel <john@stoffel.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21explain the hidden scsi_wait_scan Kconfig variableStefan Richter1-1/+12
People keep sending patches to expose CONFIG_SCSI_WAIT_SCAN as a tunable item. These patches aren't accepted upstream, so let's stop the ongoing irritation of people due to the unconditionally installed module and its Kconfig symbol. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21ibmvfc: Fix endless PRLI loop in discoveryBrian King2-4/+13
Fixes a problem seen where sending a PRLI to a target resulted in it sending a LOGO. This caused the ibmvfc driver to go back through discovery again, which caused another PRLI attempt, which caused another LOGO. Fix this behavior by ignoring LOGO if we haven't even logged into the target yet. Signed-off-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21ibmvfc: Process async events before command responsesBrian King1-10/+10
Since async events could indicate changes to link status, or events which could affect decisions made during discovery, we should process async events prior to command completion responses. Signed-off-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21libfc: Add runtime debugging with debug_logging module parameterRobert Love5-279/+235
This patch adds the /sys/module/libfc/parameters/debug_logging file to sysfs as a module parameter. It accepts an integer bitmask for logging. Currently it supports: bit LSB 0 = general libfc debugging 1 = lport debugging 2 = disc debugging 3 = rport debugging 4 = fcp debugging 5 = EM debugging 6 = exch/seq debugging 7 = scsi logging (mostly error handling) the other bits are not used at this time. The patch converts all of the libfc source files to use these new macros and removes the old FC_DBG macro. Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21libfcoe: Add runtime debugging with module param debug_loggingRobert Love1-40/+54
This patch adds a 'debug_logging' module parameter to libfcoe.ko. It is an unsigned int that represents a bitmask of available debug logging levels, each of which can be tuned at runtime. Currently there are only two logging levels for this module- bit LSB 0 = libfcoe general logging 1 = FIP logging Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21fcoe: Add runtime debug logging with module parameter debug_loggingRobert Love2-55/+77
This patch converts all FC_DBG statements to use new runtime tunable debug macros. The fcoe.ko module now has a debug_logging module parameter. fcoe_debug_logging is an unsigned integer representing a bitmask of all available logging levels. Currently only two logging levels are supported- bit LSB 0 = general fcoe logging 1 = netdevice related logging This patch also attempts to clean up some debug statement formatting so it's more readable. Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21scsi_debug: Add support for physical block exponent and alignmentMartin K. Petersen1-1/+29
This patch adds support for setting the physical block exponent and lowest aligned LBA in the READ CAPACITY(16) response. The B0 VPD page is adjusted accordingly. Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Acked-by: Douglas Gilbert <dgilbert@interlog.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21cnic: add NETDEV_1000 and NETDEVICES to Kconfig selectRandy Dunlap1-0/+2
NETDEVICES + NETDEV_1000 need to be enabled so that kconfig will check those branches for selects and enforce "select UIO" under CNIC. Otherwise the build fails with: ERROR: "uio_unregister_device" [drivers/net/cnic.ko] undefined! ERROR: "uio_event_notify" [drivers/net/cnic.ko] undefined! ERROR: "__uio_register_device" [drivers/net/cnic.ko] undefined! Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Acked-by: Michael Chan <mchan@broadcom.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2009-06-21ipr: differentiate pci-x and pci-e based adaptersWayne Boyer2-15/+21
MSI has only been tested on and known to work with PCI-E based adapters. This patch adds a field to struct ipr_chip_t to indicate which type of interrupt to use based on what is known about the chip. 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@HansenPartnership.com>
2009-06-21ipr: add test for MSI interrupt supportWayne Boyer2-9/+105
The return value from pci_enable_msi() can not always be trusted. This patch adds code to generate an interrupt after MSI has been enabled and tests whether or not we can receive and process it. If the tests fails, then fall back to LSI. 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@HansenPartnership.com>