summaryrefslogtreecommitdiff
path: root/drivers/scsi
AgeCommit message (Collapse)Author
2008-05-15SCSI: aha152x: fix init suspiciously returned 1, it should follow 0/-E ↵James Bottomley
convention commit ad2fa42d044b98469449880474a9662fb689f7f9 upstream Reported-by: Frank de Jong <frapex@xs4all.nl> > [1.] One line summary of the problem: > linux-2.6.25.3, aha152x'->init suspiciously returned 1, it should > follow 0/-E convention. The module / driver works okay. Unloading the > module is impossible. The driver is apparently returning 0 on failure and 1 on success. That's a bit unfortunate. Fix it by altering to -ENODEV and 0. Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-05-15SCSI: aha152x: Fix oops on module removalJames Bottomley
commit 64976a0387835a7ac61bbe2a99b27ccae34eac5d upstream Reported-by: Frank de Jong <frapex@xs4all.nl> > after trying to unload the module: > BUG: unable to handle kernel paging request at 00100100 > IP: [<fb9ff667>] :aha152x:aha152x_exit+0x47/0x6a > *pde = 00000000 > Oops: 0000 [#1] PREEMPT SMP > Modules linked in: aha152x(-) w83781d hwmon_vid tun ne 8390 bonding > usb_storage snd_usb_audio snd_usb_lib snd_rawmidi pwc snd_seq_device > compat_ioctl32 snd_hwdep videodev v4l1_compat 3c59x mii intel_agp > agpgart snd_pcm_oss snd_pcm snd_timer snd_page_alloc snd_mixer_oss snd > > Pid: 2837, comm: rmmod Not tainted (2.6.25.3 #1) > EIP: 0060:[<fb9ff667>] EFLAGS: 00210212 CPU: 0 > EIP is at aha152x_exit+0x47/0x6a [aha152x] > EAX: 00000001 EBX: 000ffdc4 ECX: f7c517a8 EDX: 00000001 > ESI: 00000000 EDI: 00000003 EBP: e7880000 ESP: e7881f58 > DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068 > Process rmmod (pid: 2837, ti=e7880000 task=f27eb580 task.ti=e7880000) > Stack: fba03700 c01419d2 31616861 00783235 e795ee70 c0157709 b7f24000 e79ae000 > c0158271 ffffffff b7f25000 e79ae004 e795e370 b7f25000 e795e37c e795e370 > 009ae000 fba03700 00000880 e7881fa8 00000000 bf93ec20 bf93ec20 c0102faa > Call Trace: > [<c01419d2>] sys_delete_module+0x112/0x1a0 > [<c0157709>] remove_vma+0x39/0x50 > [<c0158271>] do_munmap+0x181/0x1f0 > [<c0102faa>] sysenter_past_esp+0x5f/0x85 > [<c0490000>] rsc_parse+0x0/0x3c0 The problem is that the driver calls aha152x_release() under a list_for_each_entry(). Unfortunately, aha152x_release() deletes from the list in question. Fix this by using list_for_each_entry_safe(). Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-05-15SCSI: libiscsi regression in 2.6.25: fix setting of recv timerMike Christie
commit c8611f975403dd20e6503aff8aded5dcb718f75b upstream If the ping tmo is longer than the recv tmo then we could miss a window where we were supposed to check the recv tmo. This happens because the ping code will set the next timeout for the ping timeout, and if the ping executes quickly there will be a long chunk of time before the timer wakes up again. This patch has the ping processing code kick off a recv tmo check when getting a nop in response to our ping. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-05-15SCSI: libiscsi regression in 2.6.25: fix nop timer handlingMike Christie
commit 4cf1043593db6a337f10e006c23c69e5fc93e722 upstream The following patch fixes a bug in the iscsi nop processing. The target sends iscsi nops to ping the initiator and the initiator has to send nops to reply and can send nops to ping the target. In 2.6.25 we moved the nop processing to the kernel to handle problems when the userspace daemon is not up, but the target is pinging us, and to handle when scsi commands timeout, but the transport may be the cause (we can send a nop to check the transport). When we added this code we added a bug where if the transport timer wakes at the exact same time we are supposed to check for a nop timeout we drop the session instead of checking the transport. This patch checks if a iscsi ping is outstanding and if the ping has timed out, to determine if we need to signal a connection problem. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-05-15SCSI: qla1280: Fix queue depth problemJeremy Higdon
commit af5741c6de4f4a1d8608b0f00867c77cb7123635 upstream The qla1280 driver was ANDing the output value of mailbox register 0 with (1 << target-number) to determine whether to enable queueing on the target in question. But mailbox register 0 has the status code for the mailbox command (in this case, Set Target Parameters). Potential values are: /* * ISP mailbox command complete status codes */ So clearly that is in error. I can't think what the author of that line was looking for in a mailbox register, so I just eliminated the AND. flag is used later in the function, and I think that the later usage was also wrong, though it was used to set values that aren't used. Oh well, an overhaul of this driver is not what I want to do now -- just a bugfix. After the fix, I found that my disks were getting a queue depth of 255, which is far too many. Most SCSI disks are limited to 32 or 64. In any case, there's no point, queueing up a bunch of commands to the adapter that will just result in queue full or starve other targets from being issued commands due to running out of internal memory. So I dropped default queue depth to 32 (from which 1 is subtracted elsewhere, giving net of 31). I tested with a Seagate ST336753LC, and results look good, so I'm satisfied with this patch. Signed-off-by: Jeremy Higdon <jeremy@sgi.com> Acked-by: Jes Sorensen <jes@sgi.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-05-01SCSI: qla2xxx: Correct regression in relogin code.Andrew Vasquez
commit: 666301e673e192c87a40e07a8357d6996b57b70f upstream Commit 63a8651f2548c6bb5132c0b4e7dad4f57a9274db ([SCSI] qla2xxx: Correct infinite-login-retry issue.) introduced a small regression where a successful relogin would result in an fcport's loop_id to be incorrectly reset to FC_NO_LOOP_ID. Only clear-out loopid, if retries have been 'truly' exhausted. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-04-06scsi: fix sense_slab/bio swapping livelockHugh Dickins
Since 2.6.25-rc7, I've been seeing an occasional livelock on one x86_64 machine, copying kernel trees to tmpfs, paging out to swap. Signature: 6000 pages under writeback but never getting written; most tasks of interest trying to reclaim, but each get_swap_bio waiting for a bio in mempool_alloc's io_schedule_timeout(5*HZ); every five seconds an atomic page allocation failure report from kblockd failing to allocate a sense_buffer in __scsi_get_command. __scsi_get_command has a (one item) free_list to protect against this, but rc1's [SCSI] use dynamically allocated sense buffer de25deb18016f66dcdede165d07654559bb332bc upset that slightly. When it fails to allocate from the separate sense_slab, instead of giving up, it must fall back to the command free_list, which is sure to have a sense_buffer attached. Either my earlier -rc testing missed this, or there's some recent contributory factor. One very significant factor is SLUB, which merges slab caches when it can, and on 64-bit happens to merge both bio cache and sense_slab cache into kmalloc's 128-byte cache: so that under this swapping load, bios above are liable to gobble up all the slots needed for scsi_cmnd sense_buffers below. That's disturbing behaviour, and I tried a few things to fix it. Adding a no-op constructor to the sense_slab inhibits SLUB from merging it, and stops all the allocation failures I was seeing; but it's rather a hack, and perhaps in different configurations we have other caches on the swapout path which are ill-merged. Another alternative is to revert the separate sense_slab, using cache-line-aligned sense_buffer allocated beyond scsi_cmnd from the one kmem_cache; but that might waste more memory, and is only a way of diverting around the known problem. While I don't like seeing the allocation failures, and hate the idea of all those bios piled up above a scsi host working one by one, it does seem to emerge fairly soon with the livelock fix. So lacking better ideas, stick with that one clear fix for now. Signed-off-by: Hugh Dickins <hugh@veritas.com> Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Cc: Jens Axboe <jens.axboe@oracle.com> Cc: Christoph Lameter <clameter@sgi.com> Cc: Pekka Enberg <penberg@cs.helsinki.fi> Cc: Peter Zijlstra <a.p.ziljstra@chello.nl> Cc: Rafael J. Wysocki <rjw@sisk.pl> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-03-28[SCSI] mvsas: check subsystem idKe Wei
add support for mv6480 chip which subsystem id is 6480 in spite of device id is 6440. Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-28[SCSI] mvsas: get phy info.Ke Wei
removed unused code and attached SATA address makes use of port id. enable HBA interrupt after calling sas_register_ha(); Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-28[SCSI] mvsas: fix the buffer of rx DMA overflow bugKe Wei
fix the buffer of rx DMA overflow bug. fix default queue depth. Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-28[SCSI] mvsas: retry aborting task.Ke Wei
Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-28[SCSI] mvsas: check hd whether unpluggedKe Wei
if unplugged, driver's queuecommand function will return SAS_PHY_DOWN. task->lldd_task is used for saving its slot info. Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-28[SCSI] mvsas : interrupt handlingKe Wei
When a slot is busy, we will not free this slot until slot reset is completed. When unplugged the disk, we should release all command tasks with unplugged port that have been sent. If MVS_USE_TASKLET is defined, we can enable tasklet. Default is off. Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-28[SCSI] mvsas: a tag handler implementationKe Wei
add a new tag handler to create slot num. When a slot num is busy, new task can't hit this bit which was already used. plumb in phy speeds. Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-28[SCSI] mvsas: fill in error info record and phy mode6 bits.Ke Wei
and remove some unused members from struct. Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-27[SCSI] libsas: Warn if ATA device detected but CONFIG_SCSI_SAS_ATA not setJames Bottomley
We give a very cryptic error if an ATA device is seen on a SAS port but libsas isn't compiled to include libata to handle them. Add an extra warning to explain specifically what the problem is. Acked-by: Darrick J. Wong <djwong@us.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-27[SCSI] hosts.c: fixes for "no error" reported after error scenariosJames Smart
This patch corrects some cases in scsi_add_host() that fail, but the "error" return code was not reset after a prior use which set it to a non-error value. Patch cut against scsi-rc-fixes-2.6 Signed-off-by: James Smart <james.smart@emulex.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-26Revert "[SCSI] fix bsg queue oops with iscsi logout"James Bottomley
This reverts commit 4b6f5b3a993cbe34b4280f252bccc76967c185c8. bsg takes a reference to the underlying generic device, so it's impossible to unregister bsg in the device release routine. Acked-by: FUJITA Tomonori <tomof@acm.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-20[SCSI] a100u2w: fix bitmap lookup routineAkinobu Mita
This patch is only compile tested. It seems that bitmap lookup routine for allocation_map in a100u2w driver is simply wrong. It cannot lookup more than first 32 bits. If all first 32 bits are set, it just returns 33-th orc_scb even though the 33-th bit is not set. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Tested-by: Alan Cox <alan@redhat.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-19[SCSI] fix media change events for polled devicesKay Sievers
Commit: a341cd0f (SCSI: add asynchronous event notification API) breaks: 285e9670 (sr,sd: send media state change modification events) by introducing an event filter, which is removed here, to make events, we are depending on, happen again. Fix this by removing the event filter. It's pretty much broken at the moment, since a user can't set it (the attribute being read only). A proper fix will be to make the event discriminator distinguish between AN and Polled media change events. Cc: David Zeuthen <david@fubar.dk> Cc: kristen accardi <kaccardi@gmail.com> Cc: Jeff Garzik <jeff@garzik.org> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-19[SCSI] sd, sr: do not emit change event at device addKay Sievers
Initialize the "state changed" flag, so we do not send a change event immediately after registering a new device. Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-14[SCSI] gdth: Allocate sense_buffer to prevent NULL pointer dereferenceSven Schnelle
Fix NULL pointer dereference during execution of Internal commands, where gdth only allocates scp, but not scp->sense_buffer. The rest of the code assumes that sense_buffer is allocated, which leads to a kernel oops e.g. on reboot (during cache flush). Signed-off-by: Sven Schnelle <svens@stackframe.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-14[SCSI] arcmsr: fix iounmap error for Type B adapternickcheng
The Type B Adapter teardown does iounmap on pointers subtracted by a constant offset. Since the offset is in bytes, we need the pointers to be of type void * not uint32_t * so the subtraction is done in the correct units and we iounmap the correct area. Signed-off-by: Nick Cheng <nick.cheng@areca.com.tw> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-13[SCSI] fix bsg queue oops with iscsi logoutMike Christie
Delay bsg unregistration, because we want to wait until all the request/cmds have released their reference. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Acked-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-08[SCSI] Fix dependency problems in SCSI driversJames Bottomley
We have several drivers that don't list SCSI as a dependency in Kconfig. That leads to them potentially being selected as Y even if SCSI is M (which will produce a build failure). Fix this by making the if SCSI_LOWLEVEL that goes around all the drivers a tristate forcing them all automatically to inherit the value of SCSI. Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-07[SCSI] advansys: Fix bug in AdvLoadMicrocodeMatthew Wilcox
buf[i] can be up to 0xfd, so doubling it and assigning the result to an unsigned char truncates the value. Just use an unsigned int instead; it's only a temporary. Signed-off-by: Matthew Wilcox <willy@linux.intel.com> Cc: Stable Tree <stable@kernel.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-05Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6: (27 commits) [SCSI] mpt fusion: don't oops if NumPhys==0 [SCSI] iscsi class: regression - fix races with state manipulation and blocking/unblocking [SCSI] qla4xxx: regression - add start scan callout [SCSI] qla4xxx: fix host reset dpc race [SCSI] tgt: fix build errors when dprintk is defined [SCSI] tgt: set the data length properly [SCSI] tgt: stop zero'ing scsi_cmnd [SCSI] ibmvstgt: set up scsi_host properly before __scsi_alloc_queue [SCSI] docbook: fix fusion source files [SCSI] docbook: fix scsi source file [SCSI] qla2xxx: Update version number to 8.02.00-k9. [SCSI] qla2xxx: Correct usage of inconsistent timeout values while issuing ELS commands. [SCSI] qla2xxx: Correct discrepancies during OVERRUN handling on FWI2-capable cards. [SCSI] qla2xxx: Correct needless clean-up resets during shutdown. [SCSI] arcmsr: update version and changelog [SCSI] ps3rom: disable clustering [SCSI] ps3rom: fix wrong resid calculation bug [SCSI] mvsas: fix phy sas address [SCSI] gdth: fix to internal commands execution [SCSI] gdth: bugfix for the at-exit problems ...
2008-03-05[SCSI] iscsi class: regression - fix races with state manipulation and ↵Mike Christie
blocking/unblocking For qla4xxx, we could be starting a session, but some error (network, target, IO from a device that got started, etc) could cause the session to fail and curring the block/unblock and state manipulation could race with each other. This patch just has those operations done in the single threaded iscsi eh work queue, so that way they are serialized. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-05[SCSI] qla4xxx: regression - add start scan calloutMike Christie
We are seeing EXIST errors from sysfs during device addition. We need a start scan callout so we do not start scanning sessions found during hba setup, before the async scsi scan code is ready. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Acked-by: David C Somayajulu <david.somayajulu@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-05[SCSI] qla4xxx: fix host reset dpc raceMike Christie
The host reset callout could be starting to reset the hba at the same time the dpc thread is. This creates lots of problems because they both want to do wierd things with the firmware and interrupts, etc. This patch just has the host reset function fully shutdown the dpc thread before resetting the hba. This patch also moves the setting of the session online bit to fix a potential race with the dpc thread and iscsi recovery thread. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Acked-by: David C Somayajulu <david.somayajulu@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-04scsi: missing add of padded bytes to io completion byte countJens Axboe
Original patch from Tejun Heo <htejun@gmail.com> but should use ->extra_len and not ->data_len, as we would then overshoot the original request size. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
2008-03-03[SCSI] tgt: fix build errors when dprintk is definedFUJITA Tomonori
drivers/scsi/ibmvscsi/ibmvstgt.c: In function 'ibmvstgt_cmd_done': drivers/scsi/ibmvscsi/ibmvstgt.c:292: error: 'cmd' undeclared (first use in this function) drivers/scsi/ibmvscsi/ibmvstgt.c:292: error: (Each undeclared identifier is reported only once drivers/scsi/ibmvscsi/ibmvstgt.c:292: error: for each function it appears in.) Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] tgt: set the data length properlyFUJITA Tomonori
scsi_tgt uses REQ_TYPE_BLOCK_PC so scsi_init_io doesn't set the length for us. scsi_tgt needs to do it by itself. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] tgt: stop zero'ing scsi_cmndFUJITA Tomonori
The scsi midlayer allocates scsi_cmnd->sense_buffer dynamically so we can't initialize scsi_cmnd (the midlyaer does for us). Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] ibmvstgt: set up scsi_host properly before __scsi_alloc_queueFUJITA Tomonori
Before calling __scsi_alloc_queue, scsi_host->shost_gendev.parent must be initialized properly. This patch moves __scsi_alloc_queue after scsi_add_host (like initiator drivers do). Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] docbook: fix scsi source fileRandy Dunlap
Fix docbook problem in SCSI source files. These cause the generated docbook to be incorrect. Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] qla2xxx: Update version number to 8.02.00-k9.Andrew Vasquez
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] qla2xxx: Correct usage of inconsistent timeout values while issuing ↵Andrew Vasquez
ELS commands. The original code would incorrectly hardcode ELS timeout values rather than using the traditional '2 * r_a_tov' value. In some cases, the hardcoded values would be larger than the mailbox-command-timeout and result in a needless BIG_HAMMER (ISP reset), the typical recovery mechanism employed in such cases. The second defect in the original code was in the assignment of the default 'ha->r_a_tov' to twice the traditional value. Correct this by setting the value to 10 seconds. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] qla2xxx: Correct discrepancies during OVERRUN handling on ↵Andrew Vasquez
FWI2-capable cards. For recent ISPs, software must detect OVERRUN conditions by checking the SS_RESIDUAL_OVER bit during CS_COMPLETE handling. Update the driver to perform this check, which is consistent with what earlier firmwares did by explicitly cracking open the FCP_RSP statuses and returning an CS_DATA_OVERRUN. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] qla2xxx: Correct needless clean-up resets during shutdown.Andrew Vasquez
There's no point in hitting the RISC with what will most assuredly be an unsucessful reset of the RISC hardware if the initial stop-firmware mailbox command fails with a time-out status. Instead, to avoid what could amount to a lengthy stop-firmware/detect-failure/reset-risc loop, continue with driver unloading and discard the stop-firmware requirement. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] arcmsr: update version and changelogNick Cheng
The fix up from Daniel Drake for replacing GFP_DMA with something more sensible has gone in here: commit 69e562c234440fb7410877b5b24f4b29ef8521d1 Author: Daniel Drake <dsd@gentoo.org> Date: Wed Feb 20 13:29:05 2008 +0000 [SCSI] arcmsr: fix message allocation add a change log and update the version for this. Signed-off-by: Nick Cheng <nick.cheng@areca.com.tw> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] ps3rom: disable clusteringFUJITA Tomonori
ps3rom does: scsi_for_each_sg(cmd, sgpnt, scsi_sg_count(cmd), k) { kaddr = kmap_atomic(sg_page(sgpnt), KM_IRQ0); We cannot do something like that with the clustering enabled (or we can use scsi_kmap_atomic_sg). Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Cc: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03[SCSI] ps3rom: fix wrong resid calculation bugFUJITA Tomonori
sg driver rounds up the length in struct scatterlist to be a multiple of 512 in some conditions. So LLDs can't use the data length in a sg list to calculate residual. Instead, the length in struct scsi_cmnd should be used. [Geert: the variable buflen already contains scsi_bufflen(cmd)] Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-03-03docbook: fix scsi source fileRandy Dunlap
Fix docbook problem in SCSI source files. These cause the generated docbook to be incorrect. Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-29[SCSI] mvsas: fix phy sas addressKe Wei
The phy sas address is showing wrongly (wrong endianness). Fix up the endian transforms to make this correct. Signed-off-by: Ke Wei <kewei@marvell.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-02-27[SCSI] gdth: fix to internal commands executionBoaz Harrosh
The recent patch named: [SCSI] gdth: !use_sg cleanup and use of scsi accessors has done a bad job in handling internal commands issued by gdth_execute(). Internal commands are issued with device gdth_cmd_str ready made directly to the card, without any mapping or translations of scsi commands. So here I added a gdth_cmd_str pointer to the gdth_cmndinfo private structure which is then copied directly to host. following this patch is a cleanup that removes the home cooked accessors and reverts them to regular scsi_cmnd accessors. Since they are not used anymore. After review maybe the 2 patches should be squashed together. FIXME: There is still a problem with gdth_get_info(). as reported there is a WARN_ON trigerd in dma_free_coherent() when doing: $ cat /proc/sys/gdth/0 Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Tested-by: Joerg Dorchain: <joerg@dorchain.net> Tested-by: Stefan Priebe <s.priebe@allied-internet.ag> Tested-by: Jon Chelton <jchelton@ffpglobal.com> Cc: Stable Tree <stable@kernel.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-02-27[SCSI] gdth: bugfix for the at-exit problemsBoaz Harrosh
gdth_exit would first remove all cards then stop the timer and would not sync with the timer function. This caused a crash in gdth_timer() when module was unloaded. So del_timer_sync the timer before we delete the cards. also the reboot notifier function would crash. So clean that up and fix the crashes. Signed-off-by: Boaz Harrosh <bharrosh@panasas.com> Tested-by: Joerg Dorchain: <joerg@dorchain.net> Tested-by: Stefan Priebe <s.priebe@allied-internet.ag> Tested-by: Jon Chelton <jchelton@ffpglobal.com> Cc: Stable Tree <stable@kernel.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-02-27[SCSI] iscsi regression: check for zero max session cmdsMike Christie
The old tools did not set max session cmds. This is a regression. I removed the check when merging the power of 2 patch. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-02-24[SCSI] aic94xx: fix TMF ascb handling to prevent sequencer panicJames Bottomley
This is a particularly nasty bug. The problem is that if any internal ascb times out, currently we free it even though it's pending at the sequencer. This results in the sequencer getting terminally confused and the error message: BUG:sequencer:dl:no ascb Being returned when it comes back. The way to fix this is to manage freeing the ascb from the tasklet completion routine, so that we only free it when the sequencer actually returns it. The code is also altered to use on stack completions and transfer variables. Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
2008-02-23[SCSI] libsas: misc fixes to the eh pathJames Bottomley
- Correct one use after free of the sas task - update the reset required path to move straight to LUN reset - make the bigger hammer actually reset something instead of just trying to clear all the tasks. Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>