aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi (follow)
AgeCommit message (Collapse)AuthorFilesLines
2006-03-01Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6Linus Torvalds11-80/+90
2006-02-28[SCSI] aha152x: fix variable use before initialisation and other bugsJürgen E. Fischer3-37/+54
- change interface of the reset functions from Scsi_Cmnd to Scsi_Host. - add functions with the original interface and rename the new functions to reflect the new interface. - call these from the pcmcia driver, thereby avoiding the need to construct a (broken) Scsi_Cmnd from a Scsi_Host. - just run the bh if the interrupt is from the controller and if so ensure that it's only called once per interrupt. Signed-off-by: Juergen E. Fischer <fischer@linux-buechse.de> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-28[SCSI] Fix uninitialised width and speed in sym2Matthew Wilcox1-0/+2
sym2 boards without NVRAM currently negotiate narrow due to this missed initialisation Signed-off-by: Matthew Wilcox <matthew@wil.cx> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-28[SCSI] Delete duplicate driver template.Ralf Baechle1-21/+0
Stuborn as compilers are they don't like duplicate definitions. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-27[SCSI] scsi: scsi command retries off by one fixBrian King2-3/+3
Fix up an off by one error in calculating retries for scsi commands. This bug was discovered when an SG_IO request was sent to scsi core with retries = 0, causing the overall timeout check to go off in scsi_softirq_done. Signed-off-by: Brian King <brking@us.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-27[SCSI] megaraid_sas: fix physical disk handlingChristoph Hellwig1-14/+15
This patch hides the devices completely from the midlayer instead. It requires the patch to handle the slave_configure failure I posted earlier. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-27[libata] Disable FUAJeff Garzik3-0/+7
Until problems are sorted.
2006-02-27[SCSI] scsi: handle ->slave_configure return valueChristoph Hellwig1-2/+14
When ­>slave_configure fails the scsi midlayer should handle it. Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-27[SCSI] fc_transport: stop creating duplicate rport entries.Andrew Vasquez1-2/+1
Current fc_transport consumers initially register rports with an UNKNOWN role-state and follow-up with a call to fc_remote_port_rolechg(). Modify code in fc_remote_port_add() to scan the fc_host_rport_bindings() array for consistent bindings regardless of role-type. Original code would only scan bindings array for targets, causing duplicate fc_remote_ports/rport-X:Y-Z entries to be created for the yet-to-be-role-changed rports. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-27[SCSI] sg: Remove aha1542 hackBrian King1-1/+1
Remove a hack in the sg driver that alters the total buffer length for SG_IO commands to ensure buffers are not odd byte lengths. This breaks on the ipr driver since it requires the request_bufflen to equal the length specified in the cdb. The block layer SG_IO code does not appear to have this hack. Signed-off-by: Douglas Gilbert <dougg@torque.net> Signed-off-by: Brian King <brking@us.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-27Merge branch 'upstream-fixes' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-devLinus Torvalds1-9/+43
2006-02-26[PATCH] sd: fix memory corruption with broken mode page headersAl Viro1-3/+17
There's a problem in sd where we blindly believe the length of the headers and block descriptors. Some devices return insane values for these and cause our length to end up greater than the actual buffer size, so check to make sure. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Also removed the buffer size magic number (512) and added DPOFUA of zero to the defaults Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-02-25[PATCH] sata_sil: implement R_ERR on DMA activate FIS errata fixTejun Heo1-6/+27
Silicon Image has disclosed a new sil3114/3152 errata and workaround which causes the controller to return R_ERR on DMA activate FIS if the FIS is received while the next PRD is being fetched. This patch implements the workaround. This errata results in lock up and doesn't trigger if m15w workaround is in effect. We stopped applying m15w to 3512 and 3114 in 2.6.14-rc1 which makes 3512/3114 lock up with some drives on all kernel versions since 2.6.14-rc1 upto now (2.6.16-rc4). This patch should fix the regression. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-02-25[PATCH] sata_sil: add board ID for 3512Tejun Heo1-4/+17
3512 is slightly different from 3112 errata-wise. Differentiate it. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-02-22[SCSI] esp: fix eh lockingChristoph Hellwig1-3/+1
esp_reset didn't get fixed when the EH locking changed. ->eh_bus_reset_handler is now called without the host lock held. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-02-20[PATCH] libata: make ata_sg_setup_one() trim zero length sgTejun Heo1-5/+8
This patch makes ata_sg_setup_one() trim sg entry (thus making qc->n_elem zero) if padding results in zero length sg entry. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
2006-02-20[PATCH] libata: fix WARN_ON() condition in *_fill_sg()Tejun Heo2-2/+2
For ATAPI commands, padding can reduce qc->n_elem by one and thus to zero making assert(qc->n_elem > 0)'s in ata_fill_sg() and qs_fill_sg() fail for legal commands. This patch fixes the assert()'s to take qc->pad_len into account. Although the condition check seems a bit excessive, as this part of code isn't still stable yet, I think it's worth to keep those. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
2006-02-17[PATCH] Add missing FUA write to sata_mv dma command listJens Axboe1-0/+1
Signed-off-by: Jens Axboe <axboe@suse.de> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
2006-02-17[PATCH] libata: minor fix for 2.6.16-rc3Albert Lee1-3/+4
- Fix the array index value in ata_rwcmd_protocol() for the added FUA commands. - Filter out ATAPI packet command error messages in ata_pio_error() Signed-off-by: Albert Lee <albertcc@tw.ibm.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
2006-02-17[PATCH] Necessary evil to get sata_vsc to initialize with Intel iq3124h hbaDan Williams1-1/+29
* libata does not care about error interrupts, so handle them locally * the interrupts that are ignored only appear to happen at init time Signed-off-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
2006-02-16Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6Linus Torvalds32-479/+2020
2006-02-14[SCSI] fix wrong context bugs in SCSIJames Bottomley2-23/+12
There's a bug in releasing scsi_device where the release function actually frees the block queue. However, the block queue release calls flush_work(), which requires process context (the scsi_device structure may release from irq context). Update the release function to invoke via the execute_in_process_context() API. Also clean up the scsi_target structure releasing via this API. Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-14[PATCH] add scsi_execute_in_process_context() APIJames Bottomley1-0/+59
We have several points in the SCSI stack (primarily for our device functions) where we need to guarantee process context, but (given the place where the last reference was released) we cannot guarantee this. This API gets around the issue by executing the function directly if the caller has process context, but scheduling a workqueue to execute in process context if the caller doesn't have it. Unfortunately, it requires memory allocation in interrupt context, but it's better than what we have previously. The true solution will require a bit of re-engineering, so isn't appropriate for 2.6.16. Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-12[SCSI] sym2: Mask off opcode from RBCMatthew Wilcox1-1/+1
pm->sg.size is set from the Residual Byte Count register. However, the upper byte of the RBC is the opcode of the instruction that was executing, so we need to mask it off. This fixes some spurious rejects of IGNORE WIDE RESIDUE messages. Signed-off-by: Matthew Wilcox <matthew@wil.cx> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-12[SCSI] megaraid_legacy: kobject_register failureJu, Seokmann2-2/+2
Attached patch fixes problem that cause kobject_register failure during loading. Kobject_register would fail when there are more than 1 module with same module name. This patch will change module name of megaraid_legacy from 'megaraid' to 'megaraid_legacy'. Signed-Off-by: Seokmann Ju <seokmann.ju@lsil.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-12[SCSI] ipr: Fix adapter initialization failureBrian King2-47/+7
Since scsi core is always sending scatterlists now, remove some code which was written with the bad assumption that a small transfer would not be sent down in a scatterlist. Without this fix, the ipr driver ends up sending garbage data to the adapter following a reset, causing it to fail the reset and take the adapter offline. Signed-off-by: Brian King <brking@us.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-09Merge branch 'upstream-fixes'Jeff Garzik44-1200/+1494
2006-02-09Merge branch 'master'Jeff Garzik5-6/+6
2006-02-07[PATCH] sg gfp_t annotationsAl Viro1-1/+1
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2006-02-07[PATCH] scsi_transport_iscsi gfp_t annotationsAl Viro1-1/+1
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2006-02-07[PATCH] drivers/scsi/mac53c94.c __iomem annotationsAl Viro1-2/+2
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2006-02-07[PATCH] bogus asm/delay.h includesAl Viro1-1/+1
asm/delay.h is non-portable; linux/delay.h should be used in generic code. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2006-02-07[PATCH] qla2xxx: Correct lun assignment during IOCB submission.andrew.vasquez@qlogic.com1-0/+1
4gb products require an IOCB's FCP-LUN to be formatted in wire-format prior to submission. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-07[PATCH] qla2xxx: Pass input-buffer length to Get-ID-List mailbox command.andrew.vasquez@qlogic.com1-1/+2
Recent ISP24xx firmwares require that mailbox register 8 be set to the maximum number of bytes to transfer during DMA copying of the list. We safely set this value to zero (infinite), since the call is *only* made in FCAL topologies. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-07[PATCH] qla2xxx: Remove bogus debug-code.andrew.vasquez@qlogic.com1-3/+0
Commit 854165f4245c4a3b4a8cc363ba2050033151e196 inadvertently added some code meant only for testing -- the driver was ignoring the non-zero function numbers of a multi-port HBA. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-07[PATCH] qla2xxx: Close window on race between rport removal and fcport transition.andrew.vasquez@qlogic.com1-0/+14
Fcport visibility is recognized during interrupt time, but, rport removal can only occur during a process (sleeping)-context. Return a DID_IMM_RETRY status for commands submitted within this window to insure I/Os do not prematurely run-out of retries. Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-05[SCSI] 3ware 9000 driver >4GB memory fixadam radford1-3/+4
The attached patch fixes a bug in the 3ware 9000 series driver: - Fix use_sg == 0 mapping on systems with 4GB or higher. This fixes REPORT_LUNS (0xa0) failing with 3ware 9000 controllers on systems with lots of ram, mentioned in bugzilla # 6009: http://bugzilla.kernel.org/show_bug.cgi?id=6009 Signed-off-by: Adam Radford <linuxraid@amcc.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-05[PATCH] percpu data: only iterate over possible CPUsEric Dumazet1-1/+1
percpu_data blindly allocates bootmem memory to store NR_CPUS instances of cpudata, instead of allocating memory only for possible cpus. As a preparation for changing that, we need to convert various 0 -> NR_CPUS loops to use for_each_cpu(). (The above only applies to users of asm-generic/percpu.h. powerpc has gone it alone and is presently only allocating memory for present CPUs, so it's currently corrupting memory). Signed-off-by: Eric Dumazet <dada1@cosmosbay.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: James Bottomley <James.Bottomley@steeleye.com> Acked-by: Ingo Molnar <mingo@elte.hu> Cc: Jens Axboe <axboe@suse.de> Cc: Anton Blanchard <anton@samba.org> Acked-by: William Irwin <wli@holomorphy.com> Cc: Andi Kleen <ak@muc.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-02-05[SCSI] gdth: don't map zero-length requestsJenx Axboe1-1/+1
Don't map zero-length requests in gdth, zome architectures don't like that in their dma mapping routines. [ I'm pretty sure Jens posted this before, but for some reason it got forgotten --hch ] Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] megaraid_sas: support for 1078 type controller addedSumant Patro2-18/+129
This patch adds support for 1078 type controller (device id : 0x60). Signed-off-by: Sumant Patro <Sumant.Patro@lsil.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] megaraid_sas: register 16 byte CDB capabilityJoshua Giles2-4/+5
This patch properly registers the 16 byte command length capability of the megaraid_sas controlled hardware with the scsi midlayer. All megaraid_sas hardware supports 16 byte CDB's. Signed-off-by: Joshua Giles <joshua_giles@dell.com> Signed-off-by: Sumant Patro <Sumant.Patro@lsil.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: rm unused sessions listMike Christie1-5/+0
rm unused sessions list. This patch is last becuase I was not sure if this patchset was going to be applied over the kmalloc2kzalloc one by JesS. If it is then this patch will not apply and can be dropped for now. I will resend later when things setttle down. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: use gfp_tMike Christie1-1/+1
Use gfp_t. I accidentally removed this in our last update. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: fix mgmt pool err path releaseMike Christie1-1/+1
>From ogerlitz@voltaire.com: mgmtpool shoild be frees in immdata_alloc_fail label. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: set correct state at creation timeMike Christie1-1/+1
>From erezz@voltaire.com: We are still in ISCSI_STATE_FREE state at create time. The addition of the first connection puts us in ISCSI_STATE_LOGGED_IN. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: rm conn lockMike Christie2-5/+0
>From erezz@voltaire.com: rm conn->lock since it is not used anymore. The dataqueue is protected by the session lock and xmitmutex. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: set deamon pid earlierMike Christie1-6/+10
>From michaelc@cs.wisc.edu: If the transport lookup fails we set the daemon pid too late. This can cause us deadlock since the netlink code will think we meant to call back into our iscsi_if_rx function. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: setup pool before usingMike Christie1-7/+6
>From andmike@us.ibm.com: Ensure that pool data is setup prior to calling mempool_create as it will call the the alloc function during create. Signed-off-by: Mike Anderson <andmike@us.ibm.com> Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: pass correct skb to skb_trimMike Christie1-4/+3
>From da-x@monatomic.org: Wrong skb is passed to skb_trim in iscsi_if_get_stats. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2006-02-04[SCSI] iscsi update: cleanup iscsi class interfaceMike Christie3-140/+154
From: michaelc@cs.wisc.edu fujita.tomonori@lab.ntt.co.jp da-x@monatomic.org and err path fixup from: ogerlitz@voltaire.com This patch cleans up that interface by having the lld and class pass a iscsi_cls_session or iscsi_cls_conn between each other when the function is used by HW and SW iscsi llds. This way the lld does not have to remember if it has to send a handle or pointer and a handle or pointer to connection, session or host. This also has the class verify the session handle that gets passed from userspace instead of using the pointer passed into the kernel directly. Signed-off-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: Alex Aizman <itn780@yahoo.com> Signed-off-by: Dmitry Yusupov <dmitry_yus@yahoo.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>