diff options
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 beaa3a9d8b6d..f46eb6f6dc9f 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 [] = { | |||
4190 | /* Devices which report 1 sector over size HPA */ | 4190 | /* Devices which report 1 sector over size HPA */ |
4191 | { "ST340823A", NULL, ATA_HORKAGE_HPA_SIZE, }, | 4191 | { "ST340823A", NULL, ATA_HORKAGE_HPA_SIZE, }, |
4192 | { "ST320413A", NULL, ATA_HORKAGE_HPA_SIZE, }, | 4192 | { "ST320413A", NULL, ATA_HORKAGE_HPA_SIZE, }, |
4193 | { "ST310211A", NULL, ATA_HORKAGE_HPA_SIZE, }, | ||
4193 | 4194 | ||
4194 | /* Devices which get the IVB wrong */ | 4195 | /* Devices which get the IVB wrong */ |
4195 | { "QUANTUM FIREBALLlct10 05", "A03.0900", ATA_HORKAGE_IVB, }, | 4196 | { "QUANTUM FIREBALLlct10 05", "A03.0900", ATA_HORKAGE_IVB, }, |
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c index 354c91d06a6d..310e497b5838 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) | |||
1207 | end_request: | 1207 | end_request: |
1208 | if (blk_pc_request(rq)) { | 1208 | if (blk_pc_request(rq)) { |
1209 | unsigned long flags; | 1209 | unsigned long flags; |
1210 | unsigned int dlen = rq->data_len; | ||
1211 | |||
1212 | if (dma) | ||
1213 | rq->data_len = 0; | ||
1210 | 1214 | ||
1211 | spin_lock_irqsave(&ide_lock, flags); | 1215 | spin_lock_irqsave(&ide_lock, flags); |
1212 | if (__blk_end_request(rq, 0, rq->data_len)) | 1216 | if (__blk_end_request(rq, 0, dlen)) |
1213 | BUG(); | 1217 | BUG(); |
1214 | HWGROUP(drive)->rq = NULL; | 1218 | HWGROUP(drive)->rq = NULL; |
1215 | spin_unlock_irqrestore(&ide_lock, flags); | 1219 | spin_unlock_irqrestore(&ide_lock, flags); |
diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c index aed8b31ca561..8f5bed471050 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) | |||
397 | static const struct drive_list_entry hpa_list[] = { | 397 | static const struct drive_list_entry hpa_list[] = { |
398 | { "ST340823A", NULL }, | 398 | { "ST340823A", NULL }, |
399 | { "ST320413A", NULL }, | 399 | { "ST320413A", NULL }, |
400 | { "ST310211A", NULL }, | ||
400 | { NULL, NULL } | 401 | { NULL, NULL } |
401 | }; | 402 | }; |
402 | 403 | ||
diff --git a/drivers/ide/ide-generic.c b/drivers/ide/ide-generic.c index 709b9e4d2871..9ebec08eefd9 100644 --- a/drivers/ide/ide-generic.c +++ b/drivers/ide/ide-generic.c | |||
@@ -17,9 +17,6 @@ static int __init ide_generic_init(void) | |||
17 | u8 idx[MAX_HWIFS]; | 17 | u8 idx[MAX_HWIFS]; |
18 | int i; | 18 | int i; |
19 | 19 | ||
20 | if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) | ||
21 | ide_get_lock(NULL, NULL); /* for atari only */ | ||
22 | |||
23 | for (i = 0; i < MAX_HWIFS; i++) { | 20 | for (i = 0; i < MAX_HWIFS; i++) { |
24 | ide_hwif_t *hwif = &ide_hwifs[i]; | 21 | ide_hwif_t *hwif = &ide_hwifs[i]; |
25 | 22 | ||
@@ -31,9 +28,6 @@ static int __init ide_generic_init(void) | |||
31 | 28 | ||
32 | ide_device_add_all(idx, NULL); | 29 | ide_device_add_all(idx, NULL); |
33 | 30 | ||
34 | if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) | ||
35 | ide_release_lock(); /* for atari only */ | ||
36 | |||
37 | return 0; | 31 | return 0; |
38 | } | 32 | } |
39 | 33 | ||
diff --git a/drivers/ide/legacy/falconide.c b/drivers/ide/legacy/falconide.c index f044048903b3..8949ce71bddc 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) | |||
54 | for (i = 1; i < 8; i++) | 54 | for (i = 1; i < 8; i++) |
55 | hw->io_ports[i] = ATA_HD_BASE + 1 + i * 4; | 55 | hw->io_ports[i] = ATA_HD_BASE + 1 + i * 4; |
56 | 56 | ||
57 | hw->io_ports[IDE_CONTROL_OFFSET] = ATA_HD_CONTROL; | 57 | hw->io_ports[IDE_CONTROL_OFFSET] = ATA_HD_BASE + ATA_HD_CONTROL; |
58 | 58 | ||
59 | hw->irq = IRQ_MFP_IDE; | 59 | hw->irq = IRQ_MFP_IDE; |
60 | hw->ack_intr = NULL; | 60 | hw->ack_intr = NULL; |
@@ -84,7 +84,9 @@ static int __init falconide_init(void) | |||
84 | ide_init_port_data(hwif, index); | 84 | ide_init_port_data(hwif, index); |
85 | ide_init_port_hw(hwif, &hw); | 85 | ide_init_port_hw(hwif, &hw); |
86 | 86 | ||
87 | ide_get_lock(NULL, NULL); | ||
87 | ide_device_add(idx, NULL); | 88 | ide_device_add(idx, NULL); |
89 | ide_release_lock(); | ||
88 | } | 90 | } |
89 | 91 | ||
90 | return 0; | 92 | return 0; |
diff --git a/drivers/ide/legacy/ht6560b.c b/drivers/ide/legacy/ht6560b.c index 02d12c74764a..78ca68e60f97 100644 --- a/drivers/ide/legacy/ht6560b.c +++ b/drivers/ide/legacy/ht6560b.c | |||
@@ -21,18 +21,21 @@ | |||
21 | * "Prefetch" mode bit OFF for ide disks and | 21 | * "Prefetch" mode bit OFF for ide disks and |
22 | * ON for anything else. | 22 | * ON for anything else. |
23 | * | 23 | * |
24 | * Version 0.08 Need to force prefetch for CDs and other non-disk | ||
25 | * devices. (not sure which devices exactly need | ||
26 | * prefetch) | ||
24 | * | 27 | * |
25 | * HT-6560B EIDE-controller support | 28 | * HT-6560B EIDE-controller support |
26 | * To activate controller support use kernel parameter "ide0=ht6560b". | 29 | * To activate controller support use kernel parameter "ide0=ht6560b". |
27 | * Use hdparm utility to enable PIO mode support. | 30 | * Use hdparm utility to enable PIO mode support. |
28 | * | 31 | * |
29 | * Author: Mikko Ala-Fossi <maf@iki.fi> | 32 | * Author: Mikko Ala-Fossi <maf@iki.fi> |
30 | * Jan Evert van Grootheest <janevert@iae.nl> | 33 | * Jan Evert van Grootheest <janevert@caiway.nl> |
31 | * | 34 | * |
32 | * Try: http://www.maf.iki.fi/~maf/ht6560b/ | 35 | * Try: http://www.maf.iki.fi/~maf/ht6560b/ |
33 | */ | 36 | */ |
34 | 37 | ||
35 | #define HT6560B_VERSION "v0.07" | 38 | #define HT6560B_VERSION "v0.08" |
36 | 39 | ||
37 | #include <linux/module.h> | 40 | #include <linux/module.h> |
38 | #include <linux/types.h> | 41 | #include <linux/types.h> |
@@ -130,15 +133,20 @@ static void ht6560b_selectproc (ide_drive_t *drive) | |||
130 | u8 select, timing; | 133 | u8 select, timing; |
131 | 134 | ||
132 | local_irq_save(flags); | 135 | local_irq_save(flags); |
133 | 136 | ||
134 | select = HT_CONFIG(drive); | 137 | select = HT_CONFIG(drive); |
135 | timing = HT_TIMING(drive); | 138 | timing = HT_TIMING(drive); |
136 | 139 | ||
140 | /* | ||
141 | * Need to enforce prefetch sometimes because otherwise | ||
142 | * it'll hang (hard). | ||
143 | */ | ||
144 | if (drive->media != ide_disk || !drive->present) | ||
145 | select |= HT_PREFETCH_MODE; | ||
146 | |||
137 | if (select != current_select || timing != current_timing) { | 147 | if (select != current_select || timing != current_timing) { |
138 | current_select = select; | 148 | current_select = select; |
139 | current_timing = timing; | 149 | current_timing = timing; |
140 | if (drive->media != ide_disk || !drive->present) | ||
141 | select |= HT_PREFETCH_MODE; | ||
142 | (void)inb(HT_CONFIG_PORT); | 150 | (void)inb(HT_CONFIG_PORT); |
143 | (void)inb(HT_CONFIG_PORT); | 151 | (void)inb(HT_CONFIG_PORT); |
144 | (void)inb(HT_CONFIG_PORT); | 152 | (void)inb(HT_CONFIG_PORT); |
@@ -188,11 +196,12 @@ static int __init try_to_init_ht6560b(void) | |||
188 | outb(HT_TIMING_DEFAULT, 0x1f6); /* IDE_SELECT_REG */ | 196 | outb(HT_TIMING_DEFAULT, 0x1f6); /* IDE_SELECT_REG */ |
189 | (void) inb(0x1f7); /* IDE_STATUS_REG */ | 197 | (void) inb(0x1f7); /* IDE_STATUS_REG */ |
190 | 198 | ||
191 | printk("\nht6560b " HT6560B_VERSION | 199 | printk("ht6560b " HT6560B_VERSION |
192 | ": chipset detected and initialized" | 200 | ": chipset detected and initialized" |
193 | #ifdef DEBUG | 201 | #ifdef DEBUG |
194 | " with debug enabled" | 202 | " with debug enabled" |
195 | #endif | 203 | #endif |
204 | "\n" | ||
196 | ); | 205 | ); |
197 | return 1; | 206 | return 1; |
198 | } | 207 | } |
@@ -323,7 +332,7 @@ static const struct ide_port_info ht6560b_port_info __initdata = { | |||
323 | IDE_HFLAG_NO_DMA | | 332 | IDE_HFLAG_NO_DMA | |
324 | IDE_HFLAG_NO_AUTOTUNE | | 333 | IDE_HFLAG_NO_AUTOTUNE | |
325 | IDE_HFLAG_ABUSE_PREFETCH, | 334 | IDE_HFLAG_ABUSE_PREFETCH, |
326 | .pio_mask = ATA_PIO5, | 335 | .pio_mask = ATA_PIO4, |
327 | }; | 336 | }; |
328 | 337 | ||
329 | static int __init ht6560b_init(void) | 338 | static int __init ht6560b_init(void) |
diff --git a/drivers/ide/legacy/macide.c b/drivers/ide/legacy/macide.c index a61e60737dc7..9a79098d9eb4 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, | |||
74 | for (i = 0; i < 8; i++) | 74 | for (i = 0; i < 8; i++) |
75 | hw->io_ports[i] = base + i * 4; | 75 | hw->io_ports[i] = base + i * 4; |
76 | 76 | ||
77 | hw->io_ports[IDE_CONTROL_OFFSET] = IDE_CONTROL; | 77 | hw->io_ports[IDE_CONTROL_OFFSET] = base + IDE_CONTROL; |
78 | 78 | ||
79 | hw->irq = irq; | 79 | hw->irq = irq; |
80 | hw->ack_intr = ack_intr; | 80 | hw->ack_intr = ack_intr; |
diff --git a/drivers/ide/pci/via82cxxx.c b/drivers/ide/pci/via82cxxx.c index f3f79f805813..9004e7521889 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 | |||
479 | static const struct pci_device_id via_pci_tbl[] = { | 479 | static const struct pci_device_id via_pci_tbl[] = { |
480 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C576_1), 0 }, | 480 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C576_1), 0 }, |
481 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C586_1), 0 }, | 481 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_82C586_1), 0 }, |
482 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_CX700_IDE), 0 }, | ||
482 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_6410), 1 }, | 483 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_6410), 1 }, |
483 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_SATA_EIDE), 1 }, | 484 | { PCI_VDEVICE(VIA, PCI_DEVICE_ID_VIA_SATA_EIDE), 1 }, |
484 | { 0, }, | 485 | { 0, }, |