Fix http://bugzilla.kernel.org/show_bug.cgi?id=5923
When a scsi command failed, an oops would result.
Back-to-back SMART queries would make the Seagate drives unhappy. The
second SMART query would timeout, and the command would be aborted.
Acked-by: Markus Lidel <Markus.Lidel@shadowconnect.com>
Cc: Kenny Simpson <theonetruekenny@yahoo.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Fix's firmware download ioctl to work with SAS.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Moving the toolbox call from mptbase.c, over to
mptctl.c, and using the mptctl infastructure to issue
the call. The existing code is hanging on certain HP platforms
when this ioctl is issued, and this patch fix's that.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Bug fix for correctly setting sense width
for the MPTCOMMAND ioctl.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Use the hard coded value MPTCTL_EVENT_LOG_SIZE to fix
bug where in certain cases, the ioc->eventLogSize was
initialized.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Change from using wait_event_interruptible_timeout to
wait_event_timeout. Also delete white space and duplicate
line of code.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Add bus_type recognization in ioctl path for SAS.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This adds support for new function types in
the existing MPTCOMMAND ioctl.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
- This controller violates the I2O spec for the I/O registers. The patch
contains a workaround which moves the registers to the proper location.
(originally author: Matthew Starzewski)
- If a message frame is beyond the mapped address range a error is
returned.
Signed-off-by: Markus Lidel <Markus.Lidel@shadowconnect.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
If PCI device is enabled before probing, it will not be disabled at exit.
Signed-off-by: Markus Lidel <Markus.Lidel@shadowconnect.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This adds a sanity check in the interrupt routine
insures incoming message frames are a valid
message frames.
The code for setting 0xdeadbeaf in the freed message
frames, apparently was already submitted by Christoph
in previous patch submission.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This patch inhibits sending spi negotiation parameters
for non-configured devices from the slave_destroy function.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
The ioc->alt_ioc->alt_ioc pointer is not getting cleared
during driver unload time. This dangling pointer
can result in panic in certain circumstances, such
as error recovery, or firmware download in flashless
environments. This only impacts dual functions controllers,
such as 1030. Please apply.
This patch also includes a small cosmetic name change
for mpt_spi_log_info.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
When people use the userspace scanning facilities on SAS hardware the
LLDD gets bogus slave_alloc calls. Just fail those gracefully instead
of printing a warning in mptsas and another one in the midlayer.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Adding verbose message returned from firmware
when a task mangment request fails.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
On Mon, Jan 16, 2006 at 06:53:24PM -0700, Moore, Eric wrote:
> Adding MSI support, and command line for enabling
> it. By default, the command line option has MSI disabled.
mpt_msi_enable is initialized to 0 implicitly, no need to do that. Also
replace if (mpt_msi_enable == 1) tests with just if (mpt_msi_enable).
Updated patch below:
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
A customer request to send raid asyn actions
from firmware to the event syslog. This shows
when raid volumes go degraded, or complete resync,
or volumes created/deleted, etc.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Increasing the reply frame size by 16 bytes, to
be in sync with the other fusion drivers.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
On Mon, Jan 16, 2006 at 06:53:13PM -0700, Moore, Eric wrote:
> The task managment request timeout in the eh threads was set
> for U320 timing, which is between 2-5 seconds.
> This is too small for FC and SAS.
> According to the firmware engineers, Fibre needs to be 40 seconds
> and SAS needs to be 10 seconds.
The timeout selection should probably be done in a little helper instead
of duplicated in a few places. Updated patch below.
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Increase the port enable timeout only for SAS from 30 to 300 seconds.
A customer request for the handling large topologies.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This patch is for spi. This issues bus reset when driver
loads. Handling cases when initator has negotiated for packetized,
and target negotiated for non-packetized; effectly this bus reset
is getting both target and initiator on the same sheet of music.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
The prior fusion patches moved an invocation of a function,
mptscsih_TMHandler(), static to mptscsih.c into mptsas.c
Make the function unstatic, move the header to mptscsih.h and export it.
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This fix's problems with recent fc submission regarding
i/o being redirected to the wrong target.
Signed-off-by: Michael Reed <mdr@sgi.com>
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This moves code intented for SAS from
the generic mptscsih module over to the
mptsas module.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
The issuing of the target reset
used in device hot removal case so the
firmware queue is flushed out off outstanding
commands.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
RAID event support.
This will hot add and remove raid volumes
when managment application creates and
deletes the volumes. The driver is basically
responding to firmware asyn events, and reporting
the changes to the above layers.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Remove the "inline" keyword from a bunch of big functions in the kernel with
the goal of shrinking it by 30kb to 40kb
Signed-off-by: Arjan van de Ven <arjan@infradead.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The fix is to write 'MPI_HIM_DIM' to the Host Interrupt Mask
register, when enabling interrupts. Instead of the
tilde of MPI_HIM_RIM.
Apparently writing '1's to some of the reserved bits was causing
all the bits to go to `1`, which effectly disabled all interrupts.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
This updates mpi headers in fusion drivers to version 1.5.12.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
The SAS RAID volumes are reported beyond the expected number of phys.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Add software recognition for the new LSI Logic Fibre Channel controller.
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Signed-off-by: Michael Reed <mdr@sgi.com>
Signed-off-by: Eric Moore <Eric.Moore@lsil.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Convert kmalloc + memset to kzalloc or kcalloc in fusion.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Adds hotplug support for SAS end devices. Unfortunately the fusion
firmware doesn't generate similar events for expanders addition/removal
so we can't support them yet. Eric has an idea about a clever scheme to
find out about expander changes so that'll be added later on.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
The problem in dpt_i2o could be the pci config space accesses it
triggers as it loads, dangerous to do if there is any I/O activity going
on in the other driver (probable if a boot driver I guess).
I approve this patch to dpt_i2o.c, and am applying it to the Adaptec
branch of the driver.
Thanks for the investigation Ryoji.
---
In linux 2.6.15, data transfer does hang when both dpt_i2o
and i2o_block drivers are loaded.
It seems that location of pci_request_regions() are wrong.
I moved it just behind pci_enable_device() like other drivers,
and it becomes fine.
Signed-off-by: Ryoji Kamei <kamei@miraclelinux.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
These days ioctl32.h is only used for communication of fs/compat.c and
fs/compat_ioctl.c and doesn't contain anything of interest to drivers.
Remove inclusion in various drivers.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
HDIO_GETGEO is implemented in most block drivers, and all of them have to
duplicate the code to copy the structure to userspace, as well as getting
the start sector. This patch moves that to common code [1] and adds a
->getgeo method to fill out the raw kernel hd_geometry structure. For many
drivers this means ->ioctl can go away now.
[1] the s390 block drivers are odd in this respect. xpram sets ->start
to 4 always which seems more than odd, and the dasd driver shifts
the start offset around, probably because of it's non-standard
sector size.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: Jens Axboe <axboe@suse.de>
Cc: <mike.miller@hp.com>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: Paolo Giarrusso <blaisorblade@yahoo.it>
Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
Cc: Neil Brown <neilb@cse.unsw.edu.au>
Cc: Markus Lidel <Markus.Lidel@shadowconnect.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: James Bottomley <James.Bottomley@steeleye.com>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Fix some typos and minor code beautifying.
Signed-off-by: Markus Lidel <Markus.Lidel@shadowconnect.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
- Removed some kmalloc's with __GFP_ZERO and replace it with memset()
because it didn't work properly.
- Fixed returned message frame in i2o_cfg_passthru() which caused raidutils
to display wrong error message in case a disk was missing.
- Fixed size of printk() in i2o_scsi.c.
- Fixed get_device() and put_device() in probing of the I2O controller.
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>