summaryrefslogtreecommitdiffstats
path: root/drivers/scsi (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'master'Jeff Garzik2006-03-111-1/+1
|\
| * Allocate 96 bytes for SCSI sense data replyLinus Torvalds2006-03-071-1/+1
| | | | | | | | | | | | | | | | | | The SCSI layer uses SCSI_SENSE_BUFFERSIZE (96) for the sense buffer size, even though some other code uses "sizeof(struct request_sense)" (which is 64 bytes). Allocate the buffer using the bigger of the two for safety. Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* | [PATCH] sata_sil24: fix mwdma_mask settingTejun Heo2006-03-051-0/+1
| | | | | | | | | | | | | | mwdma_mask was not copied from port_info to probe_ent. Fix it. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: revalidate after transfer mode configurationTejun Heo2006-03-051-0/+6
| | | | | | | | | | | | | | | | Revalidate device after transfer mode configuration. This also makes dev->id up-to-date. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: implement ata_dev_revalidate()Tejun Heo2006-03-051-0/+115
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ata_dev_revalidate() re-reads IDENTIFY PAGE of the given device and makes sure it's the same device as the configured one. Once it's verified that it's the same device, @dev is configured according to newly read IDENTIFY PAGE. Note that revalidation currently doesn't invoke transfer mode reconfiguration. Criteria for 'same device' * same class (of course) * same model string * same serial string * if ATA, same n_sectors (to catch geometry parameter changes) Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: add @print_info argument to ata_dev_configure()Tejun Heo2006-03-051-22/+32
| | | | | | | | | | | | | | | | | | | | Add @print_info argument to ata_dev_configure(). Details of configured device is printed only when @pinfo_info is non-zero. This patch also reorganizes device info printing for LBA case to simplify code (necessary as @print_info adds extra nesting around it). Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: re-initialize parameters before configuringTejun Heo2006-03-051-0/+9
| | | | | | | | | | | | | | | | | | In ata_dev_configure(), reinitialize parameters before configuring. This change is for revalidation and hotplug. As ata_dev_configure() can be entered multiple times, parameters need to be reinitialized. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] sata_sil: cosmetic flag/constant changesTejun Heo2006-03-051-8/+24
| | | | | | | | | | | | | | | | Collect common host flags into SIL_DFL_HOST_FLAGS and add comments to constants. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] sata_sil: replace register address constants with sil_port[] entryTejun Heo2006-03-051-28/+11
| | | | | | | | | | | | | | | | Kill SIL_FIFO_* and SIL_IDE2_BMDMA and replace them with proper sil_port[] entry. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] sata_sil: use kzallocTejun Heo2006-03-051-2/+1
| | | | | | | | | | | | | | Use kzalloc instead of kmalloc/memset. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] sata_sil: replace sil_3112_m15w board id with sil_3112Tejun Heo2006-03-051-18/+7
| | | | | | | | | | | | | | | | | | All 3112's have m15w. Replace sil_3112_m15w with sil_3112 and flag sil_3112 with SIL_FLAG_MOD15WRITE. Signed-off-by: Tejun Heo <htejun@gmail.com> Cc: Carlos Pardo <Carlos.Pardo@siliconimage.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] ata_piix: rename PIIX_FLAG_IGN_PRESENT to PIIX_FLAG_IGNORE_PCSTejun Heo2006-03-051-3/+3
| | | | | | | | | | | | | | | | | | Rename PIIX_FLAG_IGN_PRESENT to PIIX_FLAG_IGNORE_PCS as Jeff requested. Signed-off-by: Tejun Heo <htejun@gmail.com> Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] sata_promise: Support FastTrak TX4300/TX4310Daniel Drake2006-03-041-0/+2
| | | | | | | | | | | | | | | | This patch adds support for the Promise FastTrak TX4300/TX4310 4-port PCI SATA controllers based on the PDC40719 chip. Signed-off-by: Daniel Drake <dsd@gentoo.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: reorganize ata_bus_probe()Tejun Heo2006-03-031-21/+25
| | | | | | | | | | | | | | | | | | Now that reset and configure are converted such that they don't modify or disable libata core data structures, reorganize ata_bus_probe() to reflect this change. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: fold ata_dev_config() into ata_dev_configure()Tejun Heo2006-03-031-31/+17
| | | | | | | | | | | | | | | | ata_dev_config() needs to be done everytime a device is configured. Fold it into ata_dev_configure(). Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: separate out ata_dev_configure()Tejun Heo2006-03-031-40/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Separate out ata_dev_configure() from ata_dev_identify() such that ata_dev_configure() only configures @dev according to passed in @id. The function now does not disable device on failure, it just returns appropirate error code. As this change leaves ata_dev_identify() with only reading ID, calling configure and disabling devices according to the results, this patch also kills ata_dev_identify() and inlines the logic into ata_bus_probe(). Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: convert dev->id to pointerTejun Heo2006-03-031-3/+17
| | | | | | | | | | | | | | | | | | Convert dev->id from array to pointer. This is to accomodate revalidation. During revalidation, both old and new IDENTIFY pages should be accessible and single ->id array doesn't cut it. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] ata_piix: reimplement piix_sata_probe()Tejun Heo2006-03-031-23/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reimplement piix_sata_probe() such that it turns on PCS enable bits on all avaliable ports and check present bits after a while to determine device presence. This should help broken BIOSes. After device presence detection is complete, PCS enable bits of unoccupied bits are turned off unless the controller supports AHCI (ICH6/7 docs mandate all enables bits are always set on AHCI capable controllers). Note that PCS present bits are ignored on 6300ESB as described in the datasheet. This should fix device detection problems reported with the controller. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] ata_piix: implement proper port mapTejun Heo2006-03-031-60/+122
| | | | | | | | | | | | | | | | | | | | Replace combined mode handling via PIIX_COMB/COMB_PATA_P0 with proper port map. PIIX now prints port configuration during initialization. ATA_FLAG_SLAVE_POSS is now turned on for SATA ports only when the slave device is actually avaliable. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] ata_piix: add a couple of flagsTejun Heo2006-03-031-4/+7
| | | | | | | | | | | | | | | | Add PIIX_FLAG_IGN_PRESENT and SCR flags. Thi patch doesn't cause any functional change. To be used by later init/scr updates. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] ata_piix: finer-grained port_infoTejun Heo2006-03-031-19/+58
| | | | | | | | | | | | | | | | Make port_info finer-grained. This patch doesn't cause any functional change. Later init reimplementation will make use of it. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] sata_sil: remove unneeded ATA_FLAG_SRST from 3512 port infoTejun Heo2006-03-011-1/+1
| | | | | | | | | | | | | | | | Now unneeded ATA_FLAG_SRST sneaked into sil_3512 port info while merging upstream-fixes. Kill it. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] libata: kill illegal kfree(id)Tejun Heo2006-03-011-1/+0
| | | | | | | | | | | | | | | | | | Kill kfree(id) in failure path of ata_dev_read_id(). id is not dynamically allocated yet. Signed-off-by: Tejun Heo <htejun@gmail.com> Cc: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | [PATCH] sata_sil24: add a new PCI ID for SiI 3124Tejun Heo2006-03-011-0/+1
| | | | | | | | | | | | | | | | Add a new PCI ID for SiI 3124. Reported by Silicon Image. Signed-off-by: Tejun Heo <htejun@gmail.com> Cc: Carlos Pardo <Carlos.Pardo@siliconimage.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
* | Merge branch 'master'Jeff Garzik2006-03-0114-80/+97
|\|
| * Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6Linus Torvalds2006-03-0111-80/+90
| |\
| | * [SCSI] aha152x: fix variable use before initialisation and other bugsJürgen E. Fischer2006-02-283-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>
| | * [SCSI] Fix uninitialised width and speed in sym2Matthew Wilcox2006-02-281-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>
| | * [SCSI] Delete duplicate driver template.Ralf Baechle2006-02-281-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>
| | * [SCSI] scsi: scsi command retries off by one fixBrian King2006-02-282-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>
| | * [SCSI] megaraid_sas: fix physical disk handlingChristoph Hellwig2006-02-281-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>
| | * [SCSI] scsi: handle ->slave_configure return valueChristoph Hellwig2006-02-281-2/+14
| | | | | | | | | | | | | | | | | | When ­>slave_configure fails the scsi midlayer should handle it. Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
| | * [SCSI] fc_transport: stop creating duplicate rport entries.Andrew Vasquez2006-02-281-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>
| | * [SCSI] sg: Remove aha1542 hackBrian King2006-02-281-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>
| * | [libata] Disable FUAJeff Garzik2006-02-283-0/+7
| | | | | | | | | | | | Until problems are sorted.
* | | Merge branch 'master'Jeff Garzik2006-02-273-15/+61
|\| |
| * | Merge branch 'upstream-fixes' of ā†µLinus Torvalds2006-02-271-9/+43
| |\ \ | | |/ | |/| | | | master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev
| | * [PATCH] sata_sil: implement R_ERR on DMA activate FIS errata fixTejun Heo2006-02-251-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>
| | * [PATCH] sata_sil: add board ID for 3512Tejun Heo2006-02-251-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>
| * | [PATCH] sd: fix memory corruption with broken mode page headersAl Viro2006-02-261-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>
| * [SCSI] esp: fix eh lockingChristoph Hellwig2006-02-221-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>
* | [PATCH] libata: kill ata_dev_reread_id()Tejun Heo2006-02-211-42/+0
| | | | | | | | | | | | | | Kill now-unused ata_dev_reread_id(). Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
* | [PATCH] libata: separate out ata_dev_read_id()Tejun Heo2006-02-211-82/+128
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Separate out ata_dev_read_id() from ata_dev_identify(). This is the first half of splitting ata_dev_identify(). ata_dev_read_id() will also be used for revalidation. This patch does not make any behavior change. ata_dev_read_id() doesn't modify any of libata-internal data structures. It simply reads IDENTIFY page and returns error code on failure. INIT_DEV_PARAMS and EDD wrong class code are also handled by this function. Re-reading IDENTIFY after INIT_DEV_PARAMS is performed by jumping to retry: instead of calling ata_dev_reread_id(). This is done because 1. there's retry label anyway 2. ata_dev_reread_id() cannot be used anywhere else so there's no reason to keep it. This function is probably the place to set transfer mode to PIO0 before IDENTIFY. However, reset -> identify -> init_dev_params order should be kept for pre-ATA4 devices so we cannot set transfer mode before IDENTIFY for them. How do we know if a device is post-ATA4 before IDENTIFY? Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
* | Merge branch 'upstream-fixes'Jeff Garzik2006-02-202-7/+10
|\|
| * [PATCH] libata: make ata_sg_setup_one() trim zero length sgTejun Heo2006-02-201-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>
| * [PATCH] libata: fix WARN_ON() condition in *_fill_sg()Tejun Heo2006-02-202-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>
* | [PATCH] ata_piix: convert sata to new reset mechanismTejun Heo2006-02-201-20/+15
| | | | | | | | | | | | | | Convert ata_piix sata ->phy_reset to new reset mechanism. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
* | [PATCH] ata_piix: convert pata to new reset mechanismTejun Heo2006-02-201-16/+27
| | | | | | | | | | | | | | Convert ata_piix pata ->phy_reset to new reset mechanism. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
* | [PATCH] libata: fix comment regarding setting cable typeTejun Heo2006-02-201-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | The comment above ata_std_postreset() specified that setting cable type is the responsibility of postreset(), which isn't possible / optimal depending on controller / driver. This patch kills the comment. Setting cable type is responsibility of ->probe_reset. libata doesn't care whether it's done in probeinit, reset or postreset. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
* | [PATCH] libata: update ata_dev_init_params()Tejun Heo2006-02-201-10/+19
| | | | | | | | | | | | | | | | | | | | | | | | Update ata_dev_init_params() such that it doesn't disable port directly but return with appropriate error mask on failure. This is preparation for splitting ata_dev_identify(). Note that this patch changes behavior of dev_init_params failure such that only failing devices are taken offline not the whole port. This change is intended. Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>