diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-19 02:46:56 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-19 02:46:56 (GMT) |
commit | 9a4c8546f3e7c893888bccc2b3416d6214f2664a (patch) | |
tree | d97faff06ed816b82040dac8a01fc2454725b9c7 /drivers | |
parent | b0abcfc14605b2a8c686bd8e193ab05b01a7980b (diff) | |
parent | 14e04c3f6e64bac468f0aa38c6d47aa95b60c074 (diff) | |
download | linux-9a4c8546f3e7c893888bccc2b3416d6214f2664a.tar.xz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6:
ide-cd: fix missing residual count setting in DMA mode
ht6560b: force prefetch for some devices
ht6560b can only do up to PIO mode 4
linux/hdsmart.h: fix goofups (take 2)
via82cxxx: add new PCI id for cx700
falconide: locking bugfix
MAINTAINERS: update ide-cd maintainer's email address
ide/libata: ST310211A has buggy HPA too
ide: Add missing base addresses for falconide and macide
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/ata/libata-core.c | 1 | ||||
-rw-r--r-- | drivers/ide/ide-cd.c | 6 | ||||
-rw-r--r-- | drivers/ide/ide-disk.c | 1 | ||||
-rw-r--r-- | drivers/ide/ide-generic.c | 6 | ||||
-rw-r--r-- | drivers/ide/legacy/falconide.c | 4 | ||||
-rw-r--r-- | drivers/ide/legacy/ht6560b.c | 25 | ||||
-rw-r--r-- | drivers/ide/legacy/macide.c | 2 | ||||
-rw-r--r-- | drivers/ide/pci/via82cxxx.c | 1 |
8 files changed, 29 insertions, 17 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index beaa3a9..f46eb6f 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c @@ -4190,6 +4190,7 @@ static const struct ata_blacklist_entry ata_device_blacklist [] = { /* Devices which report 1 sector over size HPA */ { "ST340823A", NULL, ATA_HORKAGE_HPA_SIZE, }, { "ST320413A", NULL, ATA_HORKAGE_HPA_SIZE, }, + { "ST310211A", NULL, ATA_HORKAGE_HPA_SIZE, }, /* Devices which get the IVB wrong */ { "QUANTUM FIREBALLlct10 05", "A03.0900", ATA_HORKAGE_IVB, }, diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c index 354c91d..310e497 100644 --- a/drivers/ide/ide-cd.c +++ b/drivers/ide/ide-cd.c @@ -1207,9 +1207,13 @@ static ide_startstop_t cdrom_newpc_intr(ide_drive_t *drive) end_request: if (blk_pc_request(rq)) { unsigned long flags; + unsigned int dlen = rq->data_len; + + if (dma) + rq->data_len = 0; spin_lock_irqsave(&ide_lock, flags); - if (__blk_end_request(rq, 0, rq->data_len)) + if (__blk_end_request(rq, 0, dlen)) BUG(); HWGROUP(drive)->rq = NULL; spin_unlock_irqrestore(&ide_lock, flags); diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c index aed8b31..8f5bed47 100644 --- a/drivers/ide/ide-disk.c +++ b/drivers/ide/ide-disk.c @@ -397,6 +397,7 @@ static inline int idedisk_supports_lba48(const struct hd_driveid *id) static const struct drive_list_entry hpa_list[] = { { "ST340823A", NULL }, { "ST320413A", NULL }, + { "ST310211A", NULL }, { NULL, NULL } }; diff --git a/drivers/ide/ide-generic.c b/drivers/ide/ide-generic.c index 709b9e4..9ebec08 100644 --- a/drivers/ide/ide-generic.c +++ b/drivers/ide/ide-generic.c @@ -17,9 +17,6 @@ static int __init ide_generic_init(void) u8 idx[MAX_HWIFS]; int i; - if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) - ide_get_lock(NULL, NULL); /* for atari only */ - for (i = 0; i < MAX_HWIFS; i++) { ide_hwif_t *hwif = &ide_hwifs[i]; @@ -31,9 +28,6 @@ static int __init ide_generic_init(void) ide_device_add_all(idx, NULL); - if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) - ide_release_lock(); /* for atari only */ - return 0; } diff --git a/drivers/ide/legacy/falconide.c b/drivers/ide/legacy/falconide.c index f044048..8949ce7 100644 --- a/drivers/ide/legacy/falconide.c +++ b/drivers/ide/legacy/falconide.c @@ -54,7 +54,7 @@ static void __init falconide_setup_ports(hw_regs_t *hw) for (i = 1; i < 8; i++) hw->io_ports[i] = ATA_HD_BASE + 1 + i * 4; - hw->io_ports[IDE_CONTROL_OFFSET] = ATA_HD_CONTROL; + hw->io_ports[IDE_CONTROL_OFFSET] = ATA_HD_BASE + ATA_HD_CONTROL; hw->irq = IRQ_MFP_IDE; hw->ack_intr = NULL; @@ -84,7 +84,9 @@ static int __init falconide_init(void) ide_init_port_data(hwif, index); ide_init_port_hw(hwif, &hw); + ide_get_lock(NULL, NULL); ide_device_add(idx, NULL); + ide_release_lock(); } return 0; diff --git a/drivers/ide/legacy/ht6560b.c b/drivers/ide/legacy/ht6560b.c index 02d12c7..78ca68e 100644 --- a/drivers/ide/legacy/ht6560b.c +++ b/drivers/ide/legacy/ht6560b.c @@ -21,18 +21,21 @@ * "Prefetch" mode bit OFF for ide disks and * ON for anything else. * + * Version 0.08 Need to force prefetch for CDs and other non-disk + * devices. (not sure which devices exactly need + * prefetch) * * HT-6560B EIDE-controller support * To activate controller support use kernel parameter "ide0=ht6560b". * Use hdparm utility to enable PIO mode support. * * Author: Mikko Ala-Fossi <maf@iki.fi> - * Jan Evert van Grootheest <janevert@iae.nl> + * Jan Evert van Grootheest <janevert@caiway.nl> * * Try: http://www.maf.iki.fi/~maf/ht6560b/ */ -#define HT6560B_VERSION "v0.07" +#define HT6560B_VERSION "v0.08" #include <linux/module.h> #include <linux/types.h> @@ -130,15 +133,20 @@ static void ht6560b_selectproc (ide_drive_t *drive) u8 select, timing; local_irq_save(flags); - + select = HT_CONFIG(drive); timing = HT_TIMING(drive); - + + /* + * Need to enforce prefetch sometimes because otherwise + * it'll hang (hard). + */ + if (drive->media != ide_disk || !drive->present) + select |= HT_PREFETCH_MODE; + if (select != current_select || timing != current_timing) { current_select = select; current_timing = timing; - if (drive->media != ide_disk || !drive->present) - select |= HT_PREFETCH_MODE; (void)inb(HT_CONFIG_PORT); (void)inb(HT_CONFIG_PORT); (void)inb(HT_CONFIG_PORT); @@ -188,11 +196,12 @@ static int __init try_to_init_ht6560b(void) outb(HT_TIMING_DEFAULT, 0x1f6); /* IDE_SELECT_REG */ (void) inb(0x1f7); /* IDE_STATUS_REG */ - printk("\nht6560b " HT6560B_VERSION + printk("ht6560b " HT6560B_VERSION ": chipset detected and initialized" #ifdef DEBUG " with debug enabled" #endif + "\n" ); return 1; } @@ -323,7 +332,7 @@ static const struct ide_port_info ht6560b_port_info __initdata = { IDE_HFLAG_NO_DMA | IDE_HFLAG_NO_AUTOTUNE | IDE_HFLAG_ABUSE_PREFETCH, - .pio_mask = ATA_PIO5, + .pio_mask = ATA_PIO4, }; static int __init ht6560b_init(void) diff --git a/drivers/ide/legacy/macide.c b/drivers/ide/legacy/macide.c index a61e607..9a79098 100644 --- a/drivers/ide/legacy/macide.c +++ b/drivers/ide/legacy/macide.c @@ -74,7 +74,7 @@ static void __init macide_setup_ports(hw_regs_t *hw, unsigned long base, for (i = 0; i < 8; i++) hw->io_ports[i] = base + i * 4; - hw->io_ports[IDE_CONTROL_OFFSET] = IDE_CONTROL; + hw->io_ports[IDE_CONTROL_OFFSET] = base + IDE_CONTROL; hw->irq = irq; hw->ack_intr = ack_intr; diff --git a/drivers/ide/pci/via82cxxx.c b/drivers/ide/pci/via82cxxx.c index f3f79f8..9004e75 100644 --- a/drivers/ide/pci/via82cxxx.c +++ b/drivers/ide/pci/via82cxxx.c @@ -479,6 +479,7 @@ static int __devinit via_init_one(struct pci_dev *dev, const struct pci_device_i static const struct pci_device_id via_pci_tbl[] = { { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C576_1), 0 }, { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C586_1), 0 }, + { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_CX700_IDE), 0 }, { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_6410), 1 }, { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_SATA_EIDE), 1 }, { 0, }, |