diff options
62 files changed, 720 insertions, 519 deletions
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index b56ea860da21..a5c055066764 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt | |||
| @@ -1252,6 +1252,8 @@ and is between 256 and 4096 characters. It is defined in the file | |||
| 1252 | * nohrst, nosrst, norst: suppress hard, soft | 1252 | * nohrst, nosrst, norst: suppress hard, soft |
| 1253 | and both resets. | 1253 | and both resets. |
| 1254 | 1254 | ||
| 1255 | * dump_id: dump IDENTIFY data. | ||
| 1256 | |||
| 1255 | If there are multiple matching configurations changing | 1257 | If there are multiple matching configurations changing |
| 1256 | the same attribute, the last one is used. | 1258 | the same attribute, the last one is used. |
| 1257 | 1259 | ||
diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig index e68541f662b9..73f883333a0d 100644 --- a/drivers/ata/Kconfig +++ b/drivers/ata/Kconfig | |||
| @@ -57,6 +57,8 @@ config SATA_PMP | |||
| 57 | This option adds support for SATA Port Multipliers | 57 | This option adds support for SATA Port Multipliers |
| 58 | (the SATA version of an ethernet hub, or SAS expander). | 58 | (the SATA version of an ethernet hub, or SAS expander). |
| 59 | 59 | ||
| 60 | comment "Controllers with non-SFF native interface" | ||
| 61 | |||
| 60 | config SATA_AHCI | 62 | config SATA_AHCI |
| 61 | tristate "AHCI SATA support" | 63 | tristate "AHCI SATA support" |
| 62 | depends on PCI | 64 | depends on PCI |
| @@ -73,11 +75,12 @@ config SATA_AHCI_PLATFORM | |||
| 73 | 75 | ||
| 74 | If unsure, say N. | 76 | If unsure, say N. |
| 75 | 77 | ||
| 76 | config SATA_SIL24 | 78 | config SATA_FSL |
| 77 | tristate "Silicon Image 3124/3132 SATA support" | 79 | tristate "Freescale 3.0Gbps SATA support" |
| 78 | depends on PCI | 80 | depends on FSL_SOC |
| 79 | help | 81 | help |
| 80 | This option enables support for Silicon Image 3124/3132 Serial ATA. | 82 | This option enables support for Freescale 3.0Gbps SATA controller. |
| 83 | It can be found on MPC837x and MPC8315. | ||
| 81 | 84 | ||
| 82 | If unsure, say N. | 85 | If unsure, say N. |
| 83 | 86 | ||
| @@ -87,12 +90,11 @@ config SATA_INIC162X | |||
| 87 | help | 90 | help |
| 88 | This option enables support for Initio 162x Serial ATA. | 91 | This option enables support for Initio 162x Serial ATA. |
| 89 | 92 | ||
| 90 | config SATA_FSL | 93 | config SATA_SIL24 |
| 91 | tristate "Freescale 3.0Gbps SATA support" | 94 | tristate "Silicon Image 3124/3132 SATA support" |
| 92 | depends on FSL_SOC | 95 | depends on PCI |
| 93 | help | 96 | help |
| 94 | This option enables support for Freescale 3.0Gbps SATA controller. | 97 | This option enables support for Silicon Image 3124/3132 Serial ATA. |
| 95 | It can be found on MPC837x and MPC8315. | ||
| 96 | 98 | ||
| 97 | If unsure, say N. | 99 | If unsure, say N. |
| 98 | 100 | ||
| @@ -116,15 +118,65 @@ config ATA_SFF | |||
| 116 | 118 | ||
| 117 | if ATA_SFF | 119 | if ATA_SFF |
| 118 | 120 | ||
| 119 | config SATA_SVW | 121 | comment "SFF controllers with custom DMA interface" |
| 120 | tristate "ServerWorks Frodo / Apple K2 SATA support" | 122 | |
| 123 | config PDC_ADMA | ||
| 124 | tristate "Pacific Digital ADMA support" | ||
| 121 | depends on PCI | 125 | depends on PCI |
| 122 | help | 126 | help |
| 123 | This option enables support for Broadcom/Serverworks/Apple K2 | 127 | This option enables support for Pacific Digital ADMA controllers |
| 124 | SATA support. | 128 | |
| 129 | If unsure, say N. | ||
| 130 | |||
| 131 | config PATA_MPC52xx | ||
| 132 | tristate "Freescale MPC52xx SoC internal IDE" | ||
| 133 | depends on PPC_MPC52xx && PPC_BESTCOMM | ||
| 134 | select PPC_BESTCOMM_ATA | ||
| 135 | help | ||
| 136 | This option enables support for integrated IDE controller | ||
| 137 | of the Freescale MPC52xx SoC. | ||
| 138 | |||
| 139 | If unsure, say N. | ||
| 140 | |||
| 141 | config PATA_OCTEON_CF | ||
| 142 | tristate "OCTEON Boot Bus Compact Flash support" | ||
| 143 | depends on CPU_CAVIUM_OCTEON | ||
| 144 | help | ||
| 145 | This option enables a polled compact flash driver for use with | ||
| 146 | compact flash cards attached to the OCTEON boot bus. | ||
| 147 | |||
| 148 | If unsure, say N. | ||
| 149 | |||
| 150 | config SATA_QSTOR | ||
| 151 | tristate "Pacific Digital SATA QStor support" | ||
| 152 | depends on PCI | ||
| 153 | help | ||
| 154 | This option enables support for Pacific Digital Serial ATA QStor. | ||
| 155 | |||
| 156 | If unsure, say N. | ||
| 157 | |||
| 158 | config SATA_SX4 | ||
| 159 | tristate "Promise SATA SX4 support (Experimental)" | ||
| 160 | depends on PCI && EXPERIMENTAL | ||
| 161 | help | ||
| 162 | This option enables support for Promise Serial ATA SX4. | ||
| 125 | 163 | ||
| 126 | If unsure, say N. | 164 | If unsure, say N. |
| 127 | 165 | ||
| 166 | config ATA_BMDMA | ||
| 167 | bool "ATA BMDMA support" | ||
| 168 | default y | ||
| 169 | help | ||
| 170 | This option adds support for SFF ATA controllers with BMDMA | ||
| 171 | capability. BMDMA stands for bus-master DMA and the | ||
| 172 | de-facto DMA interface for SFF controllers. | ||
| 173 | |||
| 174 | If unuser, say Y. | ||
| 175 | |||
| 176 | if ATA_BMDMA | ||
| 177 | |||
| 178 | comment "SATA SFF controllers with BMDMA" | ||
| 179 | |||
| 128 | config ATA_PIIX | 180 | config ATA_PIIX |
| 129 | tristate "Intel ESB, ICH, PIIX3, PIIX4 PATA/SATA support" | 181 | tristate "Intel ESB, ICH, PIIX3, PIIX4 PATA/SATA support" |
| 130 | depends on PCI | 182 | depends on PCI |
| @@ -152,22 +204,6 @@ config SATA_NV | |||
| 152 | 204 | ||
| 153 | If unsure, say N. | 205 | If unsure, say N. |
| 154 | 206 | ||
| 155 | config PDC_ADMA | ||
| 156 | tristate "Pacific Digital ADMA support" | ||
| 157 | depends on PCI | ||
| 158 | help | ||
| 159 | This option enables support for Pacific Digital ADMA controllers | ||
| 160 | |||
| 161 | If unsure, say N. | ||
| 162 | |||
| 163 | config SATA_QSTOR | ||
| 164 | tristate "Pacific Digital SATA QStor support" | ||
| 165 | depends on PCI | ||
| 166 | help | ||
| 167 | This option enables support for Pacific Digital Serial ATA QStor. | ||
| 168 | |||
| 169 | If unsure, say N. | ||
| 170 | |||
| 171 | config SATA_PROMISE | 207 | config SATA_PROMISE |
| 172 | tristate "Promise SATA TX2/TX4 support" | 208 | tristate "Promise SATA TX2/TX4 support" |
| 173 | depends on PCI | 209 | depends on PCI |
| @@ -176,14 +212,6 @@ config SATA_PROMISE | |||
| 176 | 212 | ||
| 177 | If unsure, say N. | 213 | If unsure, say N. |
| 178 | 214 | ||
| 179 | config SATA_SX4 | ||
| 180 | tristate "Promise SATA SX4 support (Experimental)" | ||
| 181 | depends on PCI && EXPERIMENTAL | ||
| 182 | help | ||
| 183 | This option enables support for Promise Serial ATA SX4. | ||
| 184 | |||
| 185 | If unsure, say N. | ||
| 186 | |||
| 187 | config SATA_SIL | 215 | config SATA_SIL |
| 188 | tristate "Silicon Image SATA support" | 216 | tristate "Silicon Image SATA support" |
| 189 | depends on PCI | 217 | depends on PCI |
| @@ -203,6 +231,15 @@ config SATA_SIS | |||
| 203 | enable the PATA_SIS driver in the config. | 231 | enable the PATA_SIS driver in the config. |
| 204 | If unsure, say N. | 232 | If unsure, say N. |
| 205 | 233 | ||
| 234 | config SATA_SVW | ||
| 235 | tristate "ServerWorks Frodo / Apple K2 SATA support" | ||
| 236 | depends on PCI | ||
| 237 | help | ||
| 238 | This option enables support for Broadcom/Serverworks/Apple K2 | ||
| 239 | SATA support. | ||
| 240 | |||
| 241 | If unsure, say N. | ||
| 242 | |||
| 206 | config SATA_ULI | 243 | config SATA_ULI |
| 207 | tristate "ULi Electronics SATA support" | 244 | tristate "ULi Electronics SATA support" |
| 208 | depends on PCI | 245 | depends on PCI |
| @@ -227,14 +264,7 @@ config SATA_VITESSE | |||
| 227 | 264 | ||
| 228 | If unsure, say N. | 265 | If unsure, say N. |
| 229 | 266 | ||
| 230 | config PATA_ACPI | 267 | comment "PATA SFF controllers with BMDMA" |
| 231 | tristate "ACPI firmware driver for PATA" | ||
| 232 | depends on ATA_ACPI | ||
| 233 | help | ||
| 234 | This option enables an ACPI method driver which drives | ||
| 235 | motherboard PATA controller interfaces through the ACPI | ||
| 236 | firmware in the BIOS. This driver can sometimes handle | ||
| 237 | otherwise unsupported hardware. | ||
| 238 | 268 | ||
| 239 | config PATA_ALI | 269 | config PATA_ALI |
| 240 | tristate "ALi PATA support" | 270 | tristate "ALi PATA support" |
| @@ -262,40 +292,30 @@ config PATA_ARTOP | |||
| 262 | 292 | ||
| 263 | If unsure, say N. | 293 | If unsure, say N. |
| 264 | 294 | ||
| 265 | config PATA_ATP867X | 295 | config PATA_ATIIXP |
| 266 | tristate "ARTOP/Acard ATP867X PATA support" | 296 | tristate "ATI PATA support" |
| 267 | depends on PCI | 297 | depends on PCI |
| 268 | help | 298 | help |
| 269 | This option enables support for ARTOP/Acard ATP867X PATA | 299 | This option enables support for the ATI ATA interfaces |
| 270 | controllers. | 300 | found on the many ATI chipsets. |
| 271 | |||
| 272 | If unsure, say N. | ||
| 273 | |||
| 274 | config PATA_AT32 | ||
| 275 | tristate "Atmel AVR32 PATA support (Experimental)" | ||
| 276 | depends on AVR32 && PLATFORM_AT32AP && EXPERIMENTAL | ||
| 277 | help | ||
| 278 | This option enables support for the IDE devices on the | ||
| 279 | Atmel AT32AP platform. | ||
| 280 | 301 | ||
| 281 | If unsure, say N. | 302 | If unsure, say N. |
| 282 | 303 | ||
| 283 | config PATA_ATIIXP | 304 | config PATA_ATP867X |
| 284 | tristate "ATI PATA support" | 305 | tristate "ARTOP/Acard ATP867X PATA support" |
| 285 | depends on PCI | 306 | depends on PCI |
| 286 | help | 307 | help |
| 287 | This option enables support for the ATI ATA interfaces | 308 | This option enables support for ARTOP/Acard ATP867X PATA |
| 288 | found on the many ATI chipsets. | 309 | controllers. |
| 289 | 310 | ||
| 290 | If unsure, say N. | 311 | If unsure, say N. |
| 291 | 312 | ||
| 292 | config PATA_CMD640_PCI | 313 | config PATA_BF54X |
| 293 | tristate "CMD640 PCI PATA support (Experimental)" | 314 | tristate "Blackfin 54x ATAPI support" |
| 294 | depends on PCI && EXPERIMENTAL | 315 | depends on BF542 || BF548 || BF549 |
| 295 | help | 316 | help |
| 296 | This option enables support for the CMD640 PCI IDE | 317 | This option enables support for the built-in ATAPI controller on |
| 297 | interface chip. Only the primary channel is currently | 318 | Blackfin 54x family chips. |
| 298 | supported. | ||
| 299 | 319 | ||
| 300 | If unsure, say N. | 320 | If unsure, say N. |
| 301 | 321 | ||
| @@ -362,15 +382,6 @@ config PATA_EFAR | |||
| 362 | 382 | ||
| 363 | If unsure, say N. | 383 | If unsure, say N. |
| 364 | 384 | ||
| 365 | config ATA_GENERIC | ||
| 366 | tristate "Generic ATA support" | ||
| 367 | depends on PCI | ||
| 368 | help | ||
| 369 | This option enables support for generic BIOS configured | ||
| 370 | ATA controllers via the new ATA layer | ||
| 371 | |||
| 372 | If unsure, say N. | ||
| 373 | |||
| 374 | config PATA_HPT366 | 385 | config PATA_HPT366 |
| 375 | tristate "HPT 366/368 PATA support" | 386 | tristate "HPT 366/368 PATA support" |
| 376 | depends on PCI | 387 | depends on PCI |
| @@ -415,12 +426,20 @@ config PATA_HPT3X3_DMA | |||
| 415 | controllers. Enable with care as there are still some | 426 | controllers. Enable with care as there are still some |
| 416 | problems with DMA on this chipset. | 427 | problems with DMA on this chipset. |
| 417 | 428 | ||
| 418 | config PATA_ISAPNP | 429 | config PATA_ICSIDE |
| 419 | tristate "ISA Plug and Play PATA support" | 430 | tristate "Acorn ICS PATA support" |
| 420 | depends on ISAPNP | 431 | depends on ARM && ARCH_ACORN |
| 421 | help | 432 | help |
| 422 | This option enables support for ISA plug & play ATA | 433 | On Acorn systems, say Y here if you wish to use the ICS PATA |
| 423 | controllers such as those found on old soundcards. | 434 | interface card. This is not required for ICS partition support. |
| 435 | If you are unsure, say N to this. | ||
| 436 | |||
| 437 | config PATA_IT8213 | ||
| 438 | tristate "IT8213 PATA support (Experimental)" | ||
| 439 | depends on PCI && EXPERIMENTAL | ||
| 440 | help | ||
| 441 | This option enables support for the ITE 821 PATA | ||
| 442 | controllers via the new ATA layer. | ||
| 424 | 443 | ||
| 425 | If unsure, say N. | 444 | If unsure, say N. |
| 426 | 445 | ||
| @@ -434,15 +453,6 @@ config PATA_IT821X | |||
| 434 | 453 | ||
| 435 | If unsure, say N. | 454 | If unsure, say N. |
| 436 | 455 | ||
| 437 | config PATA_IT8213 | ||
| 438 | tristate "IT8213 PATA support (Experimental)" | ||
| 439 | depends on PCI && EXPERIMENTAL | ||
| 440 | help | ||
| 441 | This option enables support for the ITE 821 PATA | ||
| 442 | controllers via the new ATA layer. | ||
| 443 | |||
| 444 | If unsure, say N. | ||
| 445 | |||
| 446 | config PATA_JMICRON | 456 | config PATA_JMICRON |
| 447 | tristate "JMicron PATA support" | 457 | tristate "JMicron PATA support" |
| 448 | depends on PCI | 458 | depends on PCI |
| @@ -452,23 +462,14 @@ config PATA_JMICRON | |||
| 452 | 462 | ||
| 453 | If unsure, say N. | 463 | If unsure, say N. |
| 454 | 464 | ||
| 455 | config PATA_LEGACY | 465 | config PATA_MACIO |
| 456 | tristate "Legacy ISA PATA support (Experimental)" | 466 | tristate "Apple PowerMac/PowerBook internal 'MacIO' IDE" |
| 457 | depends on (ISA || PCI) && EXPERIMENTAL | 467 | depends on PPC_PMAC |
| 458 | help | ||
| 459 | This option enables support for ISA/VLB/PCI bus legacy PATA | ||
| 460 | ports and allows them to be accessed via the new ATA layer. | ||
| 461 | |||
| 462 | If unsure, say N. | ||
| 463 | |||
| 464 | config PATA_TRIFLEX | ||
| 465 | tristate "Compaq Triflex PATA support" | ||
| 466 | depends on PCI | ||
| 467 | help | 468 | help |
| 468 | Enable support for the Compaq 'Triflex' IDE controller as found | 469 | Most IDE capable PowerMacs have IDE busses driven by a variant |
| 469 | on many Compaq Pentium-Pro systems, via the new ATA layer. | 470 | of this controller which is part of the Apple chipset used on |
| 470 | 471 | most PowerMac models. Some models have multiple busses using | |
| 471 | If unsure, say N. | 472 | different chipsets, though generally, MacIO is one of them. |
| 472 | 473 | ||
| 473 | config PATA_MARVELL | 474 | config PATA_MARVELL |
| 474 | tristate "Marvell PATA support via legacy mode" | 475 | tristate "Marvell PATA support via legacy mode" |
| @@ -481,32 +482,6 @@ config PATA_MARVELL | |||
| 481 | 482 | ||
| 482 | If unsure, say N. | 483 | If unsure, say N. |
| 483 | 484 | ||
| 484 | config PATA_MPC52xx | ||
| 485 | tristate "Freescale MPC52xx SoC internal IDE" | ||
| 486 | depends on PPC_MPC52xx && PPC_BESTCOMM | ||
| 487 | select PPC_BESTCOMM_ATA | ||
| 488 | help | ||
| 489 | This option enables support for integrated IDE controller | ||
| 490 | of the Freescale MPC52xx SoC. | ||
| 491 | |||
| 492 | If unsure, say N. | ||
| 493 | |||
| 494 | config PATA_MPIIX | ||
| 495 | tristate "Intel PATA MPIIX support" | ||
| 496 | depends on PCI | ||
| 497 | help | ||
| 498 | This option enables support for MPIIX PATA support. | ||
| 499 | |||
| 500 | If unsure, say N. | ||
| 501 | |||
| 502 | config PATA_OLDPIIX | ||
| 503 | tristate "Intel PATA old PIIX support" | ||
| 504 | depends on PCI | ||
| 505 | help | ||
| 506 | This option enables support for early PIIX PATA support. | ||
| 507 | |||
| 508 | If unsure, say N. | ||
| 509 | |||
| 510 | config PATA_NETCELL | 485 | config PATA_NETCELL |
| 511 | tristate "NETCELL Revolution RAID support" | 486 | tristate "NETCELL Revolution RAID support" |
| 512 | depends on PCI | 487 | depends on PCI |
| @@ -525,15 +500,6 @@ config PATA_NINJA32 | |||
| 525 | 500 | ||
| 526 | If unsure, say N. | 501 | If unsure, say N. |
| 527 | 502 | ||
| 528 | config PATA_NS87410 | ||
| 529 | tristate "Nat Semi NS87410 PATA support" | ||
| 530 | depends on PCI | ||
| 531 | help | ||
| 532 | This option enables support for the National Semiconductor | ||
| 533 | NS87410 PCI-IDE controller. | ||
| 534 | |||
| 535 | If unsure, say N. | ||
| 536 | |||
| 537 | config PATA_NS87415 | 503 | config PATA_NS87415 |
| 538 | tristate "Nat Semi NS87415 PATA support" | 504 | tristate "Nat Semi NS87415 PATA support" |
| 539 | depends on PCI | 505 | depends on PCI |
| @@ -543,12 +509,11 @@ config PATA_NS87415 | |||
| 543 | 509 | ||
| 544 | If unsure, say N. | 510 | If unsure, say N. |
| 545 | 511 | ||
| 546 | config PATA_OPTI | 512 | config PATA_OLDPIIX |
| 547 | tristate "OPTI621/6215 PATA support (Very Experimental)" | 513 | tristate "Intel PATA old PIIX support" |
| 548 | depends on PCI && EXPERIMENTAL | 514 | depends on PCI |
| 549 | help | 515 | help |
| 550 | This option enables full PIO support for the early Opti ATA | 516 | This option enables support for early PIIX PATA support. |
| 551 | controllers found on some old motherboards. | ||
| 552 | 517 | ||
| 553 | If unsure, say N. | 518 | If unsure, say N. |
| 554 | 519 | ||
| @@ -562,24 +527,6 @@ config PATA_OPTIDMA | |||
| 562 | 527 | ||
| 563 | If unsure, say N. | 528 | If unsure, say N. |
| 564 | 529 | ||
| 565 | config PATA_PALMLD | ||
| 566 | tristate "Palm LifeDrive PATA support" | ||
| 567 | depends on MACH_PALMLD | ||
| 568 | help | ||
| 569 | This option enables support for Palm LifeDrive's internal ATA | ||
| 570 | port via the new ATA layer. | ||
| 571 | |||
| 572 | If unsure, say N. | ||
| 573 | |||
| 574 | config PATA_PCMCIA | ||
| 575 | tristate "PCMCIA PATA support" | ||
| 576 | depends on PCMCIA | ||
| 577 | help | ||
| 578 | This option enables support for PCMCIA ATA interfaces, including | ||
| 579 | compact flash card adapters via the new ATA layer. | ||
| 580 | |||
| 581 | If unsure, say N. | ||
| 582 | |||
| 583 | config PATA_PDC2027X | 530 | config PATA_PDC2027X |
| 584 | tristate "Promise PATA 2027x support" | 531 | tristate "Promise PATA 2027x support" |
| 585 | depends on PCI | 532 | depends on PCI |
| @@ -597,12 +544,6 @@ config PATA_PDC_OLD | |||
| 597 | 544 | ||
| 598 | If unsure, say N. | 545 | If unsure, say N. |
| 599 | 546 | ||
| 600 | config PATA_QDI | ||
| 601 | tristate "QDI VLB PATA support" | ||
| 602 | depends on ISA | ||
| 603 | help | ||
| 604 | Support for QDI 6500 and 6580 PATA controllers on VESA local bus. | ||
| 605 | |||
| 606 | config PATA_RADISYS | 547 | config PATA_RADISYS |
| 607 | tristate "RADISYS 82600 PATA support (Experimental)" | 548 | tristate "RADISYS 82600 PATA support (Experimental)" |
| 608 | depends on PCI && EXPERIMENTAL | 549 | depends on PCI && EXPERIMENTAL |
| @@ -612,15 +553,6 @@ config PATA_RADISYS | |||
| 612 | 553 | ||
| 613 | If unsure, say N. | 554 | If unsure, say N. |
| 614 | 555 | ||
| 615 | config PATA_RB532 | ||
| 616 | tristate "RouterBoard 532 PATA CompactFlash support" | ||
| 617 | depends on MIKROTIK_RB532 | ||
| 618 | help | ||
| 619 | This option enables support for the RouterBoard 532 | ||
| 620 | PATA CompactFlash controller. | ||
| 621 | |||
| 622 | If unsure, say N. | ||
| 623 | |||
| 624 | config PATA_RDC | 556 | config PATA_RDC |
| 625 | tristate "RDC PATA support" | 557 | tristate "RDC PATA support" |
| 626 | depends on PCI | 558 | depends on PCI |
| @@ -631,21 +563,30 @@ config PATA_RDC | |||
| 631 | 563 | ||
| 632 | If unsure, say N. | 564 | If unsure, say N. |
| 633 | 565 | ||
| 634 | config PATA_RZ1000 | 566 | config PATA_SC1200 |
| 635 | tristate "PC Tech RZ1000 PATA support" | 567 | tristate "SC1200 PATA support" |
| 636 | depends on PCI | 568 | depends on PCI |
| 637 | help | 569 | help |
| 638 | This option enables basic support for the PC Tech RZ1000/1 | 570 | This option enables support for the NatSemi/AMD SC1200 SoC |
| 639 | PATA controllers via the new ATA layer | 571 | companion chip used with the Geode processor family. |
| 640 | 572 | ||
| 641 | If unsure, say N. | 573 | If unsure, say N. |
| 642 | 574 | ||
| 643 | config PATA_SC1200 | 575 | config PATA_SCC |
| 644 | tristate "SC1200 PATA support" | 576 | tristate "Toshiba's Cell Reference Set IDE support" |
| 577 | depends on PCI && PPC_CELLEB | ||
| 578 | help | ||
| 579 | This option enables support for the built-in IDE controller on | ||
| 580 | Toshiba Cell Reference Board. | ||
| 581 | |||
| 582 | If unsure, say N. | ||
| 583 | |||
| 584 | config PATA_SCH | ||
| 585 | tristate "Intel SCH PATA support" | ||
| 645 | depends on PCI | 586 | depends on PCI |
| 646 | help | 587 | help |
| 647 | This option enables support for the NatSemi/AMD SC1200 SoC | 588 | This option enables support for Intel SCH PATA on the Intel |
| 648 | companion chip used with the Geode processor family. | 589 | SCH (US15W, US15L, UL11L) series host controllers. |
| 649 | 590 | ||
| 650 | If unsure, say N. | 591 | If unsure, say N. |
| 651 | 592 | ||
| @@ -683,6 +624,15 @@ config PATA_TOSHIBA | |||
| 683 | 624 | ||
| 684 | If unsure, say N. | 625 | If unsure, say N. |
| 685 | 626 | ||
| 627 | config PATA_TRIFLEX | ||
| 628 | tristate "Compaq Triflex PATA support" | ||
| 629 | depends on PCI | ||
| 630 | help | ||
| 631 | Enable support for the Compaq 'Triflex' IDE controller as found | ||
| 632 | on many Compaq Pentium-Pro systems, via the new ATA layer. | ||
| 633 | |||
| 634 | If unsure, say N. | ||
| 635 | |||
| 686 | config PATA_VIA | 636 | config PATA_VIA |
| 687 | tristate "VIA PATA support" | 637 | tristate "VIA PATA support" |
| 688 | depends on PCI | 638 | depends on PCI |
| @@ -701,12 +651,99 @@ config PATA_WINBOND | |||
| 701 | 651 | ||
| 702 | If unsure, say N. | 652 | If unsure, say N. |
| 703 | 653 | ||
| 704 | config PATA_WINBOND_VLB | 654 | endif # ATA_BMDMA |
| 705 | tristate "Winbond W83759A VLB PATA support (Experimental)" | 655 | |
| 706 | depends on ISA && EXPERIMENTAL | 656 | comment "PIO-only SFF controllers" |
| 657 | |||
| 658 | config PATA_AT32 | ||
| 659 | tristate "Atmel AVR32 PATA support (Experimental)" | ||
| 660 | depends on AVR32 && PLATFORM_AT32AP && EXPERIMENTAL | ||
| 707 | help | 661 | help |
| 708 | Support for the Winbond W83759A controller on Vesa Local Bus | 662 | This option enables support for the IDE devices on the |
| 709 | systems. | 663 | Atmel AT32AP platform. |
| 664 | |||
| 665 | If unsure, say N. | ||
| 666 | |||
| 667 | config PATA_AT91 | ||
| 668 | tristate "PATA support for AT91SAM9260" | ||
| 669 | depends on ARM && ARCH_AT91 | ||
| 670 | help | ||
| 671 | This option enables support for IDE devices on the Atmel AT91SAM9260 SoC. | ||
| 672 | |||
| 673 | If unsure, say N. | ||
| 674 | |||
| 675 | config PATA_CMD640_PCI | ||
| 676 | tristate "CMD640 PCI PATA support (Experimental)" | ||
| 677 | depends on PCI && EXPERIMENTAL | ||
| 678 | help | ||
| 679 | This option enables support for the CMD640 PCI IDE | ||
| 680 | interface chip. Only the primary channel is currently | ||
| 681 | supported. | ||
| 682 | |||
| 683 | If unsure, say N. | ||
| 684 | |||
| 685 | config PATA_ISAPNP | ||
| 686 | tristate "ISA Plug and Play PATA support" | ||
| 687 | depends on ISAPNP | ||
| 688 | help | ||
| 689 | This option enables support for ISA plug & play ATA | ||
| 690 | controllers such as those found on old soundcards. | ||
| 691 | |||
| 692 | If unsure, say N. | ||
| 693 | |||
| 694 | config PATA_IXP4XX_CF | ||
| 695 | tristate "IXP4XX Compact Flash support" | ||
| 696 | depends on ARCH_IXP4XX | ||
| 697 | help | ||
| 698 | This option enables support for a Compact Flash connected on | ||
| 699 | the ixp4xx expansion bus. This driver had been written for | ||
| 700 | Loft/Avila boards in mind but can work with others. | ||
| 701 | |||
| 702 | If unsure, say N. | ||
| 703 | |||
| 704 | config PATA_MPIIX | ||
| 705 | tristate "Intel PATA MPIIX support" | ||
| 706 | depends on PCI | ||
| 707 | help | ||
| 708 | This option enables support for MPIIX PATA support. | ||
| 709 | |||
| 710 | If unsure, say N. | ||
| 711 | |||
| 712 | config PATA_NS87410 | ||
| 713 | tristate "Nat Semi NS87410 PATA support" | ||
| 714 | depends on PCI | ||
| 715 | help | ||
| 716 | This option enables support for the National Semiconductor | ||
| 717 | NS87410 PCI-IDE controller. | ||
| 718 | |||
| 719 | If unsure, say N. | ||
| 720 | |||
| 721 | config PATA_OPTI | ||
| 722 | tristate "OPTI621/6215 PATA support (Very Experimental)" | ||
| 723 | depends on PCI && EXPERIMENTAL | ||
| 724 | help | ||
| 725 | This option enables full PIO support for the early Opti ATA | ||
| 726 | controllers found on some old motherboards. | ||
| 727 | |||
| 728 | If unsure, say N. | ||
| 729 | |||
| 730 | config PATA_PALMLD | ||
| 731 | tristate "Palm LifeDrive PATA support" | ||
| 732 | depends on MACH_PALMLD | ||
| 733 | help | ||
| 734 | This option enables support for Palm LifeDrive's internal ATA | ||
| 735 | port via the new ATA layer. | ||
| 736 | |||
| 737 | If unsure, say N. | ||
| 738 | |||
| 739 | config PATA_PCMCIA | ||
| 740 | tristate "PCMCIA PATA support" | ||
| 741 | depends on PCMCIA | ||
| 742 | help | ||
| 743 | This option enables support for PCMCIA ATA interfaces, including | ||
| 744 | compact flash card adapters via the new ATA layer. | ||
| 745 | |||
| 746 | If unsure, say N. | ||
| 710 | 747 | ||
| 711 | config HAVE_PATA_PLATFORM | 748 | config HAVE_PATA_PLATFORM |
| 712 | bool | 749 | bool |
| @@ -725,14 +762,6 @@ config PATA_PLATFORM | |||
| 725 | 762 | ||
| 726 | If unsure, say N. | 763 | If unsure, say N. |
| 727 | 764 | ||
| 728 | config PATA_AT91 | ||
| 729 | tristate "PATA support for AT91SAM9260" | ||
| 730 | depends on ARM && ARCH_AT91 | ||
| 731 | help | ||
| 732 | This option enables support for IDE devices on the Atmel AT91SAM9260 SoC. | ||
| 733 | |||
| 734 | If unsure, say N. | ||
| 735 | |||
| 736 | config PATA_OF_PLATFORM | 765 | config PATA_OF_PLATFORM |
| 737 | tristate "OpenFirmware platform device PATA support" | 766 | tristate "OpenFirmware platform device PATA support" |
| 738 | depends on PATA_PLATFORM && PPC_OF | 767 | depends on PATA_PLATFORM && PPC_OF |
| @@ -743,69 +772,65 @@ config PATA_OF_PLATFORM | |||
| 743 | 772 | ||
| 744 | If unsure, say N. | 773 | If unsure, say N. |
| 745 | 774 | ||
| 746 | config PATA_ICSIDE | 775 | config PATA_QDI |
| 747 | tristate "Acorn ICS PATA support" | 776 | tristate "QDI VLB PATA support" |
| 748 | depends on ARM && ARCH_ACORN | 777 | depends on ISA |
| 749 | help | 778 | help |
| 750 | On Acorn systems, say Y here if you wish to use the ICS PATA | 779 | Support for QDI 6500 and 6580 PATA controllers on VESA local bus. |
| 751 | interface card. This is not required for ICS partition support. | ||
| 752 | If you are unsure, say N to this. | ||
| 753 | 780 | ||
| 754 | config PATA_IXP4XX_CF | 781 | config PATA_RB532 |
| 755 | tristate "IXP4XX Compact Flash support" | 782 | tristate "RouterBoard 532 PATA CompactFlash support" |
| 756 | depends on ARCH_IXP4XX | 783 | depends on MIKROTIK_RB532 |
| 757 | help | 784 | help |
| 758 | This option enables support for a Compact Flash connected on | 785 | This option enables support for the RouterBoard 532 |
| 759 | the ixp4xx expansion bus. This driver had been written for | 786 | PATA CompactFlash controller. |
| 760 | Loft/Avila boards in mind but can work with others. | ||
| 761 | 787 | ||
| 762 | If unsure, say N. | 788 | If unsure, say N. |
| 763 | 789 | ||
| 764 | config PATA_OCTEON_CF | 790 | config PATA_RZ1000 |
| 765 | tristate "OCTEON Boot Bus Compact Flash support" | 791 | tristate "PC Tech RZ1000 PATA support" |
| 766 | depends on CPU_CAVIUM_OCTEON | 792 | depends on PCI |
| 767 | help | 793 | help |
| 768 | This option enables a polled compact flash driver for use with | 794 | This option enables basic support for the PC Tech RZ1000/1 |
| 769 | compact flash cards attached to the OCTEON boot bus. | 795 | PATA controllers via the new ATA layer |
| 770 | 796 | ||
| 771 | If unsure, say N. | 797 | If unsure, say N. |
| 772 | 798 | ||
| 773 | config PATA_SCC | 799 | config PATA_WINBOND_VLB |
| 774 | tristate "Toshiba's Cell Reference Set IDE support" | 800 | tristate "Winbond W83759A VLB PATA support (Experimental)" |
| 775 | depends on PCI && PPC_CELLEB | 801 | depends on ISA && EXPERIMENTAL |
| 776 | help | 802 | help |
| 777 | This option enables support for the built-in IDE controller on | 803 | Support for the Winbond W83759A controller on Vesa Local Bus |
| 778 | Toshiba Cell Reference Board. | 804 | systems. |
| 779 | 805 | ||
| 780 | If unsure, say N. | 806 | comment "Generic fallback / legacy drivers" |
| 781 | 807 | ||
| 782 | config PATA_SCH | 808 | config PATA_ACPI |
| 783 | tristate "Intel SCH PATA support" | 809 | tristate "ACPI firmware driver for PATA" |
| 784 | depends on PCI | 810 | depends on ATA_ACPI && ATA_BMDMA |
| 785 | help | 811 | help |
| 786 | This option enables support for Intel SCH PATA on the Intel | 812 | This option enables an ACPI method driver which drives |
| 787 | SCH (US15W, US15L, UL11L) series host controllers. | 813 | motherboard PATA controller interfaces through the ACPI |
| 788 | 814 | firmware in the BIOS. This driver can sometimes handle | |
| 789 | If unsure, say N. | 815 | otherwise unsupported hardware. |
| 790 | 816 | ||
| 791 | config PATA_BF54X | 817 | config ATA_GENERIC |
| 792 | tristate "Blackfin 54x ATAPI support" | 818 | tristate "Generic ATA support" |
| 793 | depends on BF542 || BF548 || BF549 | 819 | depends on PCI && ATA_BMDMA |
| 794 | help | 820 | help |
| 795 | This option enables support for the built-in ATAPI controller on | 821 | This option enables support for generic BIOS configured |
| 796 | Blackfin 54x family chips. | 822 | ATA controllers via the new ATA layer |
| 797 | 823 | ||
| 798 | If unsure, say N. | 824 | If unsure, say N. |
| 799 | 825 | ||
| 800 | config PATA_MACIO | 826 | config PATA_LEGACY |
| 801 | tristate "Apple PowerMac/PowerBook internal 'MacIO' IDE" | 827 | tristate "Legacy ISA PATA support (Experimental)" |
| 802 | depends on PPC_PMAC | 828 | depends on (ISA || PCI) && EXPERIMENTAL |
| 803 | help | 829 | help |
| 804 | Most IDE capable PowerMacs have IDE busses driven by a variant | 830 | This option enables support for ISA/VLB/PCI bus legacy PATA |
| 805 | of this controller which is part of the Apple chipset used on | 831 | ports and allows them to be accessed via the new ATA layer. |
| 806 | most PowerMac models. Some models have multiple busses using | ||
| 807 | different chipsets, though generally, MacIO is one of them. | ||
| 808 | 832 | ||
| 833 | If unsure, say N. | ||
| 809 | 834 | ||
| 810 | endif # ATA_SFF | 835 | endif # ATA_SFF |
| 811 | endif # ATA | 836 | endif # ATA |
diff --git a/drivers/ata/Makefile b/drivers/ata/Makefile index d0a93c4ad3ec..7ef89d73df63 100644 --- a/drivers/ata/Makefile +++ b/drivers/ata/Makefile | |||
| @@ -1,33 +1,39 @@ | |||
| 1 | 1 | ||
| 2 | obj-$(CONFIG_ATA) += libata.o | 2 | obj-$(CONFIG_ATA) += libata.o |
| 3 | 3 | ||
| 4 | # non-SFF interface | ||
| 4 | obj-$(CONFIG_SATA_AHCI) += ahci.o libahci.o | 5 | obj-$(CONFIG_SATA_AHCI) += ahci.o libahci.o |
| 5 | obj-$(CONFIG_SATA_AHCI_PLATFORM) += ahci_platform.o libahci.o | 6 | obj-$(CONFIG_SATA_AHCI_PLATFORM) += ahci_platform.o libahci.o |
| 6 | obj-$(CONFIG_SATA_SVW) += sata_svw.o | 7 | obj-$(CONFIG_SATA_FSL) += sata_fsl.o |
| 8 | obj-$(CONFIG_SATA_INIC162X) += sata_inic162x.o | ||
| 9 | obj-$(CONFIG_SATA_SIL24) += sata_sil24.o | ||
| 10 | |||
| 11 | # SFF w/ custom DMA | ||
| 12 | obj-$(CONFIG_PDC_ADMA) += pdc_adma.o | ||
| 13 | obj-$(CONFIG_PATA_MPC52xx) += pata_mpc52xx.o | ||
| 14 | obj-$(CONFIG_PATA_OCTEON_CF) += pata_octeon_cf.o | ||
| 15 | obj-$(CONFIG_SATA_QSTOR) += sata_qstor.o | ||
| 16 | obj-$(CONFIG_SATA_SX4) += sata_sx4.o | ||
| 17 | |||
| 18 | # SFF SATA w/ BMDMA | ||
| 7 | obj-$(CONFIG_ATA_PIIX) += ata_piix.o | 19 | obj-$(CONFIG_ATA_PIIX) += ata_piix.o |
| 20 | obj-$(CONFIG_SATA_MV) += sata_mv.o | ||
| 21 | obj-$(CONFIG_SATA_NV) += sata_nv.o | ||
| 8 | obj-$(CONFIG_SATA_PROMISE) += sata_promise.o | 22 | obj-$(CONFIG_SATA_PROMISE) += sata_promise.o |
| 9 | obj-$(CONFIG_SATA_QSTOR) += sata_qstor.o | ||
| 10 | obj-$(CONFIG_SATA_SIL) += sata_sil.o | 23 | obj-$(CONFIG_SATA_SIL) += sata_sil.o |
| 11 | obj-$(CONFIG_SATA_SIL24) += sata_sil24.o | ||
| 12 | obj-$(CONFIG_SATA_VIA) += sata_via.o | ||
| 13 | obj-$(CONFIG_SATA_VITESSE) += sata_vsc.o | ||
| 14 | obj-$(CONFIG_SATA_SIS) += sata_sis.o | 24 | obj-$(CONFIG_SATA_SIS) += sata_sis.o |
| 15 | obj-$(CONFIG_SATA_SX4) += sata_sx4.o | 25 | obj-$(CONFIG_SATA_SVW) += sata_svw.o |
| 16 | obj-$(CONFIG_SATA_NV) += sata_nv.o | ||
| 17 | obj-$(CONFIG_SATA_ULI) += sata_uli.o | 26 | obj-$(CONFIG_SATA_ULI) += sata_uli.o |
| 18 | obj-$(CONFIG_SATA_MV) += sata_mv.o | 27 | obj-$(CONFIG_SATA_VIA) += sata_via.o |
| 19 | obj-$(CONFIG_SATA_INIC162X) += sata_inic162x.o | 28 | obj-$(CONFIG_SATA_VITESSE) += sata_vsc.o |
| 20 | obj-$(CONFIG_PDC_ADMA) += pdc_adma.o | ||
| 21 | obj-$(CONFIG_SATA_FSL) += sata_fsl.o | ||
| 22 | obj-$(CONFIG_PATA_MACIO) += pata_macio.o | ||
| 23 | 29 | ||
| 30 | # SFF PATA w/ BMDMA | ||
| 24 | obj-$(CONFIG_PATA_ALI) += pata_ali.o | 31 | obj-$(CONFIG_PATA_ALI) += pata_ali.o |
| 25 | obj-$(CONFIG_PATA_AMD) += pata_amd.o | 32 | obj-$(CONFIG_PATA_AMD) += pata_amd.o |
| 26 | obj-$(CONFIG_PATA_ARTOP) += pata_artop.o | 33 | obj-$(CONFIG_PATA_ARTOP) += pata_artop.o |
| 27 | obj-$(CONFIG_PATA_ATP867X) += pata_atp867x.o | ||
| 28 | obj-$(CONFIG_PATA_AT32) += pata_at32.o | ||
| 29 | obj-$(CONFIG_PATA_ATIIXP) += pata_atiixp.o | 34 | obj-$(CONFIG_PATA_ATIIXP) += pata_atiixp.o |
| 30 | obj-$(CONFIG_PATA_CMD640_PCI) += pata_cmd640.o | 35 | obj-$(CONFIG_PATA_ATP867X) += pata_atp867x.o |
| 36 | obj-$(CONFIG_PATA_BF54X) += pata_bf54x.o | ||
| 31 | obj-$(CONFIG_PATA_CMD64X) += pata_cmd64x.o | 37 | obj-$(CONFIG_PATA_CMD64X) += pata_cmd64x.o |
| 32 | obj-$(CONFIG_PATA_CS5520) += pata_cs5520.o | 38 | obj-$(CONFIG_PATA_CS5520) += pata_cs5520.o |
| 33 | obj-$(CONFIG_PATA_CS5530) += pata_cs5530.o | 39 | obj-$(CONFIG_PATA_CS5530) += pata_cs5530.o |
| @@ -39,47 +45,50 @@ obj-$(CONFIG_PATA_HPT366) += pata_hpt366.o | |||
| 39 | obj-$(CONFIG_PATA_HPT37X) += pata_hpt37x.o | 45 | obj-$(CONFIG_PATA_HPT37X) += pata_hpt37x.o |
| 40 | obj-$(CONFIG_PATA_HPT3X2N) += pata_hpt3x2n.o | 46 | obj-$(CONFIG_PATA_HPT3X2N) += pata_hpt3x2n.o |
| 41 | obj-$(CONFIG_PATA_HPT3X3) += pata_hpt3x3.o | 47 | obj-$(CONFIG_PATA_HPT3X3) += pata_hpt3x3.o |
| 42 | obj-$(CONFIG_PATA_ISAPNP) += pata_isapnp.o | 48 | obj-$(CONFIG_PATA_ICSIDE) += pata_icside.o |
| 43 | obj-$(CONFIG_PATA_IT821X) += pata_it821x.o | ||
| 44 | obj-$(CONFIG_PATA_IT8213) += pata_it8213.o | 49 | obj-$(CONFIG_PATA_IT8213) += pata_it8213.o |
| 50 | obj-$(CONFIG_PATA_IT821X) += pata_it821x.o | ||
| 45 | obj-$(CONFIG_PATA_JMICRON) += pata_jmicron.o | 51 | obj-$(CONFIG_PATA_JMICRON) += pata_jmicron.o |
| 52 | obj-$(CONFIG_PATA_MACIO) += pata_macio.o | ||
| 53 | obj-$(CONFIG_PATA_MARVELL) += pata_marvell.o | ||
| 46 | obj-$(CONFIG_PATA_NETCELL) += pata_netcell.o | 54 | obj-$(CONFIG_PATA_NETCELL) += pata_netcell.o |
| 47 | obj-$(CONFIG_PATA_NINJA32) += pata_ninja32.o | 55 | obj-$(CONFIG_PATA_NINJA32) += pata_ninja32.o |
| 48 | obj-$(CONFIG_PATA_NS87410) += pata_ns87410.o | ||
| 49 | obj-$(CONFIG_PATA_NS87415) += pata_ns87415.o | 56 | obj-$(CONFIG_PATA_NS87415) += pata_ns87415.o |
| 50 | obj-$(CONFIG_PATA_OPTI) += pata_opti.o | ||
| 51 | obj-$(CONFIG_PATA_OPTIDMA) += pata_optidma.o | ||
| 52 | obj-$(CONFIG_PATA_MPC52xx) += pata_mpc52xx.o | ||
| 53 | obj-$(CONFIG_PATA_MARVELL) += pata_marvell.o | ||
| 54 | obj-$(CONFIG_PATA_MPIIX) += pata_mpiix.o | ||
| 55 | obj-$(CONFIG_PATA_OLDPIIX) += pata_oldpiix.o | 57 | obj-$(CONFIG_PATA_OLDPIIX) += pata_oldpiix.o |
| 56 | obj-$(CONFIG_PATA_PALMLD) += pata_palmld.o | 58 | obj-$(CONFIG_PATA_OPTIDMA) += pata_optidma.o |
| 57 | obj-$(CONFIG_PATA_PCMCIA) += pata_pcmcia.o | ||
| 58 | obj-$(CONFIG_PATA_PDC2027X) += pata_pdc2027x.o | 59 | obj-$(CONFIG_PATA_PDC2027X) += pata_pdc2027x.o |
| 59 | obj-$(CONFIG_PATA_PDC_OLD) += pata_pdc202xx_old.o | 60 | obj-$(CONFIG_PATA_PDC_OLD) += pata_pdc202xx_old.o |
| 60 | obj-$(CONFIG_PATA_QDI) += pata_qdi.o | ||
| 61 | obj-$(CONFIG_PATA_RADISYS) += pata_radisys.o | 61 | obj-$(CONFIG_PATA_RADISYS) += pata_radisys.o |
| 62 | obj-$(CONFIG_PATA_RB532) += pata_rb532_cf.o | ||
| 63 | obj-$(CONFIG_PATA_RDC) += pata_rdc.o | 62 | obj-$(CONFIG_PATA_RDC) += pata_rdc.o |
| 64 | obj-$(CONFIG_PATA_RZ1000) += pata_rz1000.o | ||
| 65 | obj-$(CONFIG_PATA_SC1200) += pata_sc1200.o | 63 | obj-$(CONFIG_PATA_SC1200) += pata_sc1200.o |
| 64 | obj-$(CONFIG_PATA_SCC) += pata_scc.o | ||
| 65 | obj-$(CONFIG_PATA_SCH) += pata_sch.o | ||
| 66 | obj-$(CONFIG_PATA_SERVERWORKS) += pata_serverworks.o | 66 | obj-$(CONFIG_PATA_SERVERWORKS) += pata_serverworks.o |
| 67 | obj-$(CONFIG_PATA_SIL680) += pata_sil680.o | 67 | obj-$(CONFIG_PATA_SIL680) += pata_sil680.o |
| 68 | obj-$(CONFIG_PATA_SIS) += pata_sis.o | ||
| 68 | obj-$(CONFIG_PATA_TOSHIBA) += pata_piccolo.o | 69 | obj-$(CONFIG_PATA_TOSHIBA) += pata_piccolo.o |
| 70 | obj-$(CONFIG_PATA_TRIFLEX) += pata_triflex.o | ||
| 69 | obj-$(CONFIG_PATA_VIA) += pata_via.o | 71 | obj-$(CONFIG_PATA_VIA) += pata_via.o |
| 70 | obj-$(CONFIG_PATA_WINBOND) += pata_sl82c105.o | 72 | obj-$(CONFIG_PATA_WINBOND) += pata_sl82c105.o |
| 71 | obj-$(CONFIG_PATA_WINBOND_VLB) += pata_winbond.o | 73 | |
| 72 | obj-$(CONFIG_PATA_SIS) += pata_sis.o | 74 | # SFF PIO only |
| 73 | obj-$(CONFIG_PATA_TRIFLEX) += pata_triflex.o | 75 | obj-$(CONFIG_PATA_AT32) += pata_at32.o |
| 76 | obj-$(CONFIG_PATA_AT91) += pata_at91.o | ||
| 77 | obj-$(CONFIG_PATA_CMD640_PCI) += pata_cmd640.o | ||
| 78 | obj-$(CONFIG_PATA_ISAPNP) += pata_isapnp.o | ||
| 74 | obj-$(CONFIG_PATA_IXP4XX_CF) += pata_ixp4xx_cf.o | 79 | obj-$(CONFIG_PATA_IXP4XX_CF) += pata_ixp4xx_cf.o |
| 75 | obj-$(CONFIG_PATA_SCC) += pata_scc.o | 80 | obj-$(CONFIG_PATA_MPIIX) += pata_mpiix.o |
| 76 | obj-$(CONFIG_PATA_SCH) += pata_sch.o | 81 | obj-$(CONFIG_PATA_NS87410) += pata_ns87410.o |
| 77 | obj-$(CONFIG_PATA_BF54X) += pata_bf54x.o | 82 | obj-$(CONFIG_PATA_OPTI) += pata_opti.o |
| 78 | obj-$(CONFIG_PATA_OCTEON_CF) += pata_octeon_cf.o | 83 | obj-$(CONFIG_PATA_PCMCIA) += pata_pcmcia.o |
| 84 | obj-$(CONFIG_PATA_PALMLD) += pata_palmld.o | ||
| 79 | obj-$(CONFIG_PATA_PLATFORM) += pata_platform.o | 85 | obj-$(CONFIG_PATA_PLATFORM) += pata_platform.o |
| 80 | obj-$(CONFIG_PATA_AT91) += pata_at91.o | ||
| 81 | obj-$(CONFIG_PATA_OF_PLATFORM) += pata_of_platform.o | 86 | obj-$(CONFIG_PATA_OF_PLATFORM) += pata_of_platform.o |
| 82 | obj-$(CONFIG_PATA_ICSIDE) += pata_icside.o | 87 | obj-$(CONFIG_PATA_QDI) += pata_qdi.o |
| 88 | obj-$(CONFIG_PATA_RB532) += pata_rb532_cf.o | ||
| 89 | obj-$(CONFIG_PATA_RZ1000) += pata_rz1000.o | ||
| 90 | obj-$(CONFIG_PATA_WINBOND_VLB) += pata_winbond.o | ||
| 91 | |||
| 83 | # Should be last but two libata driver | 92 | # Should be last but two libata driver |
| 84 | obj-$(CONFIG_PATA_ACPI) += pata_acpi.o | 93 | obj-$(CONFIG_PATA_ACPI) += pata_acpi.o |
| 85 | # Should be last but one libata driver | 94 | # Should be last but one libata driver |
diff --git a/drivers/ata/ata_generic.c b/drivers/ata/ata_generic.c index 33fb614f9784..573158a9668d 100644 --- a/drivers/ata/ata_generic.c +++ b/drivers/ata/ata_generic.c | |||
| @@ -155,7 +155,7 @@ static int ata_generic_init_one(struct pci_dev *dev, const struct pci_device_id | |||
| 155 | return rc; | 155 | return rc; |
| 156 | pcim_pin_device(dev); | 156 | pcim_pin_device(dev); |
| 157 | } | 157 | } |
| 158 | return ata_pci_sff_init_one(dev, ppi, &generic_sht, NULL, 0); | 158 | return ata_pci_bmdma_init_one(dev, ppi, &generic_sht, NULL, 0); |
| 159 | } | 159 | } |
| 160 | 160 | ||
| 161 | static struct pci_device_id ata_generic[] = { | 161 | static struct pci_device_id ata_generic[] = { |
diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c index ec52fc618763..7409f98d2ae6 100644 --- a/drivers/ata/ata_piix.c +++ b/drivers/ata/ata_piix.c | |||
| @@ -1589,7 +1589,7 @@ static int __devinit piix_init_one(struct pci_dev *pdev, | |||
| 1589 | hpriv->map = piix_init_sata_map(pdev, port_info, | 1589 | hpriv->map = piix_init_sata_map(pdev, port_info, |
| 1590 | piix_map_db_table[ent->driver_data]); | 1590 | piix_map_db_table[ent->driver_data]); |
| 1591 | 1591 | ||
| 1592 | rc = ata_pci_sff_prepare_host(pdev, ppi, &host); | 1592 | rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); |
| 1593 | if (rc) | 1593 | if (rc) |
| 1594 | return rc; | 1594 | return rc; |
| 1595 | host->private_data = hpriv; | 1595 | host->private_data = hpriv; |
| @@ -1626,7 +1626,7 @@ static int __devinit piix_init_one(struct pci_dev *pdev, | |||
| 1626 | host->flags |= ATA_HOST_PARALLEL_SCAN; | 1626 | host->flags |= ATA_HOST_PARALLEL_SCAN; |
| 1627 | 1627 | ||
| 1628 | pci_set_master(pdev); | 1628 | pci_set_master(pdev); |
| 1629 | return ata_pci_sff_activate_host(host, ata_sff_interrupt, &piix_sht); | 1629 | return ata_pci_sff_activate_host(host, ata_bmdma_interrupt, &piix_sht); |
| 1630 | } | 1630 | } |
| 1631 | 1631 | ||
| 1632 | static void piix_remove_one(struct pci_dev *pdev) | 1632 | static void piix_remove_one(struct pci_dev *pdev) |
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index c47373f01f89..06b7e49e039c 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c | |||
| @@ -160,6 +160,10 @@ int libata_allow_tpm = 0; | |||
| 160 | module_param_named(allow_tpm, libata_allow_tpm, int, 0444); | 160 | module_param_named(allow_tpm, libata_allow_tpm, int, 0444); |
| 161 | MODULE_PARM_DESC(allow_tpm, "Permit the use of TPM commands (0=off [default], 1=on)"); | 161 | MODULE_PARM_DESC(allow_tpm, "Permit the use of TPM commands (0=off [default], 1=on)"); |
| 162 | 162 | ||
| 163 | static int atapi_an; | ||
| 164 | module_param(atapi_an, int, 0444); | ||
| 165 | MODULE_PARM_DESC(atapi_an, "Enable ATAPI AN media presence notification (0=0ff [default], 1=on)"); | ||
| 166 | |||
| 163 | MODULE_AUTHOR("Jeff Garzik"); | 167 | MODULE_AUTHOR("Jeff Garzik"); |
| 164 | MODULE_DESCRIPTION("Library module for ATA devices"); | 168 | MODULE_DESCRIPTION("Library module for ATA devices"); |
| 165 | MODULE_LICENSE("GPL"); | 169 | MODULE_LICENSE("GPL"); |
| @@ -2122,6 +2126,14 @@ retry: | |||
| 2122 | goto err_out; | 2126 | goto err_out; |
| 2123 | } | 2127 | } |
| 2124 | 2128 | ||
| 2129 | if (dev->horkage & ATA_HORKAGE_DUMP_ID) { | ||
| 2130 | ata_dev_printk(dev, KERN_DEBUG, "dumping IDENTIFY data, " | ||
| 2131 | "class=%d may_fallback=%d tried_spinup=%d\n", | ||
| 2132 | class, may_fallback, tried_spinup); | ||
| 2133 | print_hex_dump(KERN_DEBUG, "", DUMP_PREFIX_OFFSET, | ||
| 2134 | 16, 2, id, ATA_ID_WORDS * sizeof(*id), true); | ||
| 2135 | } | ||
| 2136 | |||
| 2125 | /* Falling back doesn't make sense if ID data was read | 2137 | /* Falling back doesn't make sense if ID data was read |
| 2126 | * successfully at least once. | 2138 | * successfully at least once. |
| 2127 | */ | 2139 | */ |
| @@ -2510,7 +2522,8 @@ int ata_dev_configure(struct ata_device *dev) | |||
| 2510 | * to enable ATAPI AN to discern between PHY status | 2522 | * to enable ATAPI AN to discern between PHY status |
| 2511 | * changed notifications and ATAPI ANs. | 2523 | * changed notifications and ATAPI ANs. |
| 2512 | */ | 2524 | */ |
| 2513 | if ((ap->flags & ATA_FLAG_AN) && ata_id_has_atapi_AN(id) && | 2525 | if (atapi_an && |
| 2526 | (ap->flags & ATA_FLAG_AN) && ata_id_has_atapi_AN(id) && | ||
| 2514 | (!sata_pmp_attached(ap) || | 2527 | (!sata_pmp_attached(ap) || |
| 2515 | sata_scr_read(&ap->link, SCR_NOTIFICATION, &sntf) == 0)) { | 2528 | sata_scr_read(&ap->link, SCR_NOTIFICATION, &sntf) == 0)) { |
| 2516 | unsigned int err_mask; | 2529 | unsigned int err_mask; |
| @@ -6372,6 +6385,7 @@ static int __init ata_parse_force_one(char **cur, | |||
| 6372 | { "3.0Gbps", .spd_limit = 2 }, | 6385 | { "3.0Gbps", .spd_limit = 2 }, |
| 6373 | { "noncq", .horkage_on = ATA_HORKAGE_NONCQ }, | 6386 | { "noncq", .horkage_on = ATA_HORKAGE_NONCQ }, |
| 6374 | { "ncq", .horkage_off = ATA_HORKAGE_NONCQ }, | 6387 | { "ncq", .horkage_off = ATA_HORKAGE_NONCQ }, |
| 6388 | { "dump_id", .horkage_on = ATA_HORKAGE_DUMP_ID }, | ||
| 6375 | { "pio0", .xfer_mask = 1 << (ATA_SHIFT_PIO + 0) }, | 6389 | { "pio0", .xfer_mask = 1 << (ATA_SHIFT_PIO + 0) }, |
| 6376 | { "pio1", .xfer_mask = 1 << (ATA_SHIFT_PIO + 1) }, | 6390 | { "pio1", .xfer_mask = 1 << (ATA_SHIFT_PIO + 1) }, |
| 6377 | { "pio2", .xfer_mask = 1 << (ATA_SHIFT_PIO + 2) }, | 6391 | { "pio2", .xfer_mask = 1 << (ATA_SHIFT_PIO + 2) }, |
diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c index 19ddf924944f..efa4a18cfb9d 100644 --- a/drivers/ata/libata-sff.c +++ b/drivers/ata/libata-sff.c | |||
| @@ -63,7 +63,6 @@ const struct ata_port_operations ata_sff_port_ops = { | |||
| 63 | .sff_tf_read = ata_sff_tf_read, | 63 | .sff_tf_read = ata_sff_tf_read, |
| 64 | .sff_exec_command = ata_sff_exec_command, | 64 | .sff_exec_command = ata_sff_exec_command, |
| 65 | .sff_data_xfer = ata_sff_data_xfer, | 65 | .sff_data_xfer = ata_sff_data_xfer, |
| 66 | .sff_irq_clear = ata_sff_irq_clear, | ||
| 67 | .sff_drain_fifo = ata_sff_drain_fifo, | 66 | .sff_drain_fifo = ata_sff_drain_fifo, |
| 68 | 67 | ||
| 69 | .lost_interrupt = ata_sff_lost_interrupt, | 68 | .lost_interrupt = ata_sff_lost_interrupt, |
| @@ -395,33 +394,12 @@ void ata_sff_irq_on(struct ata_port *ap) | |||
| 395 | ata_sff_set_devctl(ap, ap->ctl); | 394 | ata_sff_set_devctl(ap, ap->ctl); |
| 396 | ata_wait_idle(ap); | 395 | ata_wait_idle(ap); |
| 397 | 396 | ||
| 398 | ap->ops->sff_irq_clear(ap); | 397 | if (ap->ops->sff_irq_clear) |
| 398 | ap->ops->sff_irq_clear(ap); | ||
| 399 | } | 399 | } |
| 400 | EXPORT_SYMBOL_GPL(ata_sff_irq_on); | 400 | EXPORT_SYMBOL_GPL(ata_sff_irq_on); |
| 401 | 401 | ||
| 402 | /** | 402 | /** |
| 403 | * ata_sff_irq_clear - Clear PCI IDE BMDMA interrupt. | ||
| 404 | * @ap: Port associated with this ATA transaction. | ||
| 405 | * | ||
| 406 | * Clear interrupt and error flags in DMA status register. | ||
| 407 | * | ||
| 408 | * May be used as the irq_clear() entry in ata_port_operations. | ||
| 409 | * | ||
| 410 | * LOCKING: | ||
| 411 | * spin_lock_irqsave(host lock) | ||
| 412 | */ | ||
| 413 | void ata_sff_irq_clear(struct ata_port *ap) | ||
| 414 | { | ||
| 415 | void __iomem *mmio = ap->ioaddr.bmdma_addr; | ||
| 416 | |||
| 417 | if (!mmio) | ||
| 418 | return; | ||
| 419 | |||
| 420 | iowrite8(ioread8(mmio + ATA_DMA_STATUS), mmio + ATA_DMA_STATUS); | ||
| 421 | } | ||
| 422 | EXPORT_SYMBOL_GPL(ata_sff_irq_clear); | ||
| 423 | |||
| 424 | /** | ||
| 425 | * ata_sff_tf_load - send taskfile registers to host controller | 403 | * ata_sff_tf_load - send taskfile registers to host controller |
| 426 | * @ap: Port to which output is sent | 404 | * @ap: Port to which output is sent |
| 427 | * @tf: ATA taskfile register set | 405 | * @tf: ATA taskfile register set |
| @@ -820,11 +798,15 @@ static void atapi_send_cdb(struct ata_port *ap, struct ata_queued_cmd *qc) | |||
| 820 | case ATAPI_PROT_NODATA: | 798 | case ATAPI_PROT_NODATA: |
| 821 | ap->hsm_task_state = HSM_ST_LAST; | 799 | ap->hsm_task_state = HSM_ST_LAST; |
| 822 | break; | 800 | break; |
| 801 | #ifdef CONFIG_ATA_BMDMA | ||
| 823 | case ATAPI_PROT_DMA: | 802 | case ATAPI_PROT_DMA: |
| 824 | ap->hsm_task_state = HSM_ST_LAST; | 803 | ap->hsm_task_state = HSM_ST_LAST; |
| 825 | /* initiate bmdma */ | 804 | /* initiate bmdma */ |
| 826 | ap->ops->bmdma_start(qc); | 805 | ap->ops->bmdma_start(qc); |
| 827 | break; | 806 | break; |
| 807 | #endif /* CONFIG_ATA_BMDMA */ | ||
| 808 | default: | ||
| 809 | BUG(); | ||
| 828 | } | 810 | } |
| 829 | } | 811 | } |
| 830 | 812 | ||
| @@ -1491,27 +1473,27 @@ bool ata_sff_qc_fill_rtf(struct ata_queued_cmd *qc) | |||
| 1491 | } | 1473 | } |
| 1492 | EXPORT_SYMBOL_GPL(ata_sff_qc_fill_rtf); | 1474 | EXPORT_SYMBOL_GPL(ata_sff_qc_fill_rtf); |
| 1493 | 1475 | ||
| 1494 | /** | 1476 | static unsigned int ata_sff_idle_irq(struct ata_port *ap) |
| 1495 | * ata_sff_host_intr - Handle host interrupt for given (port, task) | ||
| 1496 | * @ap: Port on which interrupt arrived (possibly...) | ||
| 1497 | * @qc: Taskfile currently active in engine | ||
| 1498 | * | ||
| 1499 | * Handle host interrupt for given queued command. Currently, | ||
| 1500 | * only DMA interrupts are handled. All other commands are | ||
| 1501 | * handled via polling with interrupts disabled (nIEN bit). | ||
| 1502 | * | ||
| 1503 | * LOCKING: | ||
| 1504 | * spin_lock_irqsave(host lock) | ||
| 1505 | * | ||
| 1506 | * RETURNS: | ||
| 1507 | * One if interrupt was handled, zero if not (shared irq). | ||
| 1508 | */ | ||
| 1509 | unsigned int ata_sff_host_intr(struct ata_port *ap, | ||
| 1510 | struct ata_queued_cmd *qc) | ||
| 1511 | { | 1477 | { |
| 1512 | struct ata_eh_info *ehi = &ap->link.eh_info; | 1478 | ap->stats.idle_irq++; |
| 1513 | u8 status, host_stat = 0; | 1479 | |
| 1514 | bool bmdma_stopped = false; | 1480 | #ifdef ATA_IRQ_TRAP |
| 1481 | if ((ap->stats.idle_irq % 1000) == 0) { | ||
| 1482 | ap->ops->sff_check_status(ap); | ||
| 1483 | if (ap->ops->sff_irq_clear) | ||
| 1484 | ap->ops->sff_irq_clear(ap); | ||
| 1485 | ata_port_printk(ap, KERN_WARNING, "irq trap\n"); | ||
| 1486 | return 1; | ||
| 1487 | } | ||
| 1488 | #endif | ||
| 1489 | return 0; /* irq not handled */ | ||
| 1490 | } | ||
| 1491 | |||
| 1492 | static unsigned int __ata_sff_port_intr(struct ata_port *ap, | ||
| 1493 | struct ata_queued_cmd *qc, | ||
| 1494 | bool hsmv_on_idle) | ||
| 1495 | { | ||
| 1496 | u8 status; | ||
| 1515 | 1497 | ||
| 1516 | VPRINTK("ata%u: protocol %d task_state %d\n", | 1498 | VPRINTK("ata%u: protocol %d task_state %d\n", |
| 1517 | ap->print_id, qc->tf.protocol, ap->hsm_task_state); | 1499 | ap->print_id, qc->tf.protocol, ap->hsm_task_state); |
| @@ -1528,90 +1510,56 @@ unsigned int ata_sff_host_intr(struct ata_port *ap, | |||
| 1528 | * need to check ata_is_atapi(qc->tf.protocol) again. | 1510 | * need to check ata_is_atapi(qc->tf.protocol) again. |
| 1529 | */ | 1511 | */ |
| 1530 | if (!(qc->dev->flags & ATA_DFLAG_CDB_INTR)) | 1512 | if (!(qc->dev->flags & ATA_DFLAG_CDB_INTR)) |
| 1531 | goto idle_irq; | 1513 | return ata_sff_idle_irq(ap); |
| 1532 | break; | ||
| 1533 | case HSM_ST_LAST: | ||
| 1534 | if (qc->tf.protocol == ATA_PROT_DMA || | ||
| 1535 | qc->tf.protocol == ATAPI_PROT_DMA) { | ||
| 1536 | /* check status of DMA engine */ | ||
| 1537 | host_stat = ap->ops->bmdma_status(ap); | ||
| 1538 | VPRINTK("ata%u: host_stat 0x%X\n", | ||
| 1539 | ap->print_id, host_stat); | ||
| 1540 | |||
| 1541 | /* if it's not our irq... */ | ||
| 1542 | if (!(host_stat & ATA_DMA_INTR)) | ||
| 1543 | goto idle_irq; | ||
| 1544 | |||
| 1545 | /* before we do anything else, clear DMA-Start bit */ | ||
| 1546 | ap->ops->bmdma_stop(qc); | ||
| 1547 | bmdma_stopped = true; | ||
| 1548 | |||
| 1549 | if (unlikely(host_stat & ATA_DMA_ERR)) { | ||
| 1550 | /* error when transfering data to/from memory */ | ||
| 1551 | qc->err_mask |= AC_ERR_HOST_BUS; | ||
| 1552 | ap->hsm_task_state = HSM_ST_ERR; | ||
| 1553 | } | ||
| 1554 | } | ||
| 1555 | break; | 1514 | break; |
| 1556 | case HSM_ST: | 1515 | case HSM_ST: |
| 1516 | case HSM_ST_LAST: | ||
| 1557 | break; | 1517 | break; |
| 1558 | default: | 1518 | default: |
| 1559 | goto idle_irq; | 1519 | return ata_sff_idle_irq(ap); |
| 1560 | } | 1520 | } |
| 1561 | 1521 | ||
| 1562 | |||
| 1563 | /* check main status, clearing INTRQ if needed */ | 1522 | /* check main status, clearing INTRQ if needed */ |
| 1564 | status = ata_sff_irq_status(ap); | 1523 | status = ata_sff_irq_status(ap); |
| 1565 | if (status & ATA_BUSY) { | 1524 | if (status & ATA_BUSY) { |
| 1566 | if (bmdma_stopped) { | 1525 | if (hsmv_on_idle) { |
| 1567 | /* BMDMA engine is already stopped, we're screwed */ | 1526 | /* BMDMA engine is already stopped, we're screwed */ |
| 1568 | qc->err_mask |= AC_ERR_HSM; | 1527 | qc->err_mask |= AC_ERR_HSM; |
| 1569 | ap->hsm_task_state = HSM_ST_ERR; | 1528 | ap->hsm_task_state = HSM_ST_ERR; |
| 1570 | } else | 1529 | } else |
| 1571 | goto idle_irq; | 1530 | return ata_sff_idle_irq(ap); |
| 1572 | } | 1531 | } |
| 1573 | 1532 | ||
| 1574 | /* clear irq events */ | 1533 | /* clear irq events */ |
| 1575 | ap->ops->sff_irq_clear(ap); | 1534 | if (ap->ops->sff_irq_clear) |
| 1535 | ap->ops->sff_irq_clear(ap); | ||
| 1576 | 1536 | ||
| 1577 | ata_sff_hsm_move(ap, qc, status, 0); | 1537 | ata_sff_hsm_move(ap, qc, status, 0); |
| 1578 | 1538 | ||
| 1579 | if (unlikely(qc->err_mask) && (qc->tf.protocol == ATA_PROT_DMA || | ||
| 1580 | qc->tf.protocol == ATAPI_PROT_DMA)) | ||
| 1581 | ata_ehi_push_desc(ehi, "BMDMA stat 0x%x", host_stat); | ||
| 1582 | |||
| 1583 | return 1; /* irq handled */ | 1539 | return 1; /* irq handled */ |
| 1584 | |||
| 1585 | idle_irq: | ||
| 1586 | ap->stats.idle_irq++; | ||
| 1587 | |||
| 1588 | #ifdef ATA_IRQ_TRAP | ||
| 1589 | if ((ap->stats.idle_irq % 1000) == 0) { | ||
| 1590 | ap->ops->sff_check_status(ap); | ||
| 1591 | ap->ops->sff_irq_clear(ap); | ||
| 1592 | ata_port_printk(ap, KERN_WARNING, "irq trap\n"); | ||
| 1593 | return 1; | ||
| 1594 | } | ||
| 1595 | #endif | ||
| 1596 | return 0; /* irq not handled */ | ||
| 1597 | } | 1540 | } |
| 1598 | EXPORT_SYMBOL_GPL(ata_sff_host_intr); | ||
| 1599 | 1541 | ||
| 1600 | /** | 1542 | /** |
| 1601 | * ata_sff_interrupt - Default ATA host interrupt handler | 1543 | * ata_sff_port_intr - Handle SFF port interrupt |
| 1602 | * @irq: irq line (unused) | 1544 | * @ap: Port on which interrupt arrived (possibly...) |
| 1603 | * @dev_instance: pointer to our ata_host information structure | 1545 | * @qc: Taskfile currently active in engine |
| 1604 | * | 1546 | * |
| 1605 | * Default interrupt handler for PCI IDE devices. Calls | 1547 | * Handle port interrupt for given queued command. |
| 1606 | * ata_sff_host_intr() for each port that is not disabled. | ||
| 1607 | * | 1548 | * |
| 1608 | * LOCKING: | 1549 | * LOCKING: |
| 1609 | * Obtains host lock during operation. | 1550 | * spin_lock_irqsave(host lock) |
| 1610 | * | 1551 | * |
| 1611 | * RETURNS: | 1552 | * RETURNS: |
| 1612 | * IRQ_NONE or IRQ_HANDLED. | 1553 | * One if interrupt was handled, zero if not (shared irq). |
| 1613 | */ | 1554 | */ |
| 1614 | irqreturn_t ata_sff_interrupt(int irq, void *dev_instance) | 1555 | unsigned int ata_sff_port_intr(struct ata_port *ap, struct ata_queued_cmd *qc) |
| 1556 | { | ||
| 1557 | return __ata_sff_port_intr(ap, qc, false); | ||
| 1558 | } | ||
| 1559 | EXPORT_SYMBOL_GPL(ata_sff_port_intr); | ||
| 1560 | |||
| 1561 | static inline irqreturn_t __ata_sff_interrupt(int irq, void *dev_instance, | ||
| 1562 | unsigned int (*port_intr)(struct ata_port *, struct ata_queued_cmd *)) | ||
| 1615 | { | 1563 | { |
| 1616 | struct ata_host *host = dev_instance; | 1564 | struct ata_host *host = dev_instance; |
| 1617 | bool retried = false; | 1565 | bool retried = false; |
| @@ -1631,7 +1579,7 @@ retry: | |||
| 1631 | qc = ata_qc_from_tag(ap, ap->link.active_tag); | 1579 | qc = ata_qc_from_tag(ap, ap->link.active_tag); |
| 1632 | if (qc) { | 1580 | if (qc) { |
| 1633 | if (!(qc->tf.flags & ATA_TFLAG_POLLING)) | 1581 | if (!(qc->tf.flags & ATA_TFLAG_POLLING)) |
| 1634 | handled |= ata_sff_host_intr(ap, qc); | 1582 | handled |= port_intr(ap, qc); |
| 1635 | else | 1583 | else |
| 1636 | polling |= 1 << i; | 1584 | polling |= 1 << i; |
| 1637 | } else | 1585 | } else |
| @@ -1658,7 +1606,8 @@ retry: | |||
| 1658 | 1606 | ||
| 1659 | if (idle & (1 << i)) { | 1607 | if (idle & (1 << i)) { |
| 1660 | ap->ops->sff_check_status(ap); | 1608 | ap->ops->sff_check_status(ap); |
| 1661 | ap->ops->sff_irq_clear(ap); | 1609 | if (ap->ops->sff_irq_clear) |
| 1610 | ap->ops->sff_irq_clear(ap); | ||
| 1662 | } else { | 1611 | } else { |
| 1663 | /* clear INTRQ and check if BUSY cleared */ | 1612 | /* clear INTRQ and check if BUSY cleared */ |
| 1664 | if (!(ap->ops->sff_check_status(ap) & ATA_BUSY)) | 1613 | if (!(ap->ops->sff_check_status(ap) & ATA_BUSY)) |
| @@ -1680,6 +1629,25 @@ retry: | |||
| 1680 | 1629 | ||
| 1681 | return IRQ_RETVAL(handled); | 1630 | return IRQ_RETVAL(handled); |
| 1682 | } | 1631 | } |
| 1632 | |||
| 1633 | /** | ||
| 1634 | * ata_sff_interrupt - Default SFF ATA host interrupt handler | ||
| 1635 | * @irq: irq line (unused) | ||
| 1636 | * @dev_instance: pointer to our ata_host information structure | ||
| 1637 | * | ||
| 1638 | * Default interrupt handler for PCI IDE devices. Calls | ||
| 1639 | * ata_sff_port_intr() for each port that is not disabled. | ||
| 1640 | * | ||
| 1641 | * LOCKING: | ||
| 1642 | * Obtains host lock during operation. | ||
| 1643 | * | ||
| 1644 | * RETURNS: | ||
| 1645 | * IRQ_NONE or IRQ_HANDLED. | ||
| 1646 | */ | ||
| 1647 | irqreturn_t ata_sff_interrupt(int irq, void *dev_instance) | ||
| 1648 | { | ||
| 1649 | return __ata_sff_interrupt(irq, dev_instance, ata_sff_port_intr); | ||
| 1650 | } | ||
| 1683 | EXPORT_SYMBOL_GPL(ata_sff_interrupt); | 1651 | EXPORT_SYMBOL_GPL(ata_sff_interrupt); |
| 1684 | 1652 | ||
| 1685 | /** | 1653 | /** |
| @@ -1717,7 +1685,7 @@ void ata_sff_lost_interrupt(struct ata_port *ap) | |||
| 1717 | status); | 1685 | status); |
| 1718 | /* Run the host interrupt logic as if the interrupt had not been | 1686 | /* Run the host interrupt logic as if the interrupt had not been |
| 1719 | lost */ | 1687 | lost */ |
| 1720 | ata_sff_host_intr(ap, qc); | 1688 | ata_sff_port_intr(ap, qc); |
| 1721 | } | 1689 | } |
| 1722 | EXPORT_SYMBOL_GPL(ata_sff_lost_interrupt); | 1690 | EXPORT_SYMBOL_GPL(ata_sff_lost_interrupt); |
| 1723 | 1691 | ||
| @@ -1744,7 +1712,8 @@ void ata_sff_freeze(struct ata_port *ap) | |||
| 1744 | */ | 1712 | */ |
| 1745 | ap->ops->sff_check_status(ap); | 1713 | ap->ops->sff_check_status(ap); |
| 1746 | 1714 | ||
| 1747 | ap->ops->sff_irq_clear(ap); | 1715 | if (ap->ops->sff_irq_clear) |
| 1716 | ap->ops->sff_irq_clear(ap); | ||
| 1748 | } | 1717 | } |
| 1749 | EXPORT_SYMBOL_GPL(ata_sff_freeze); | 1718 | EXPORT_SYMBOL_GPL(ata_sff_freeze); |
| 1750 | 1719 | ||
| @@ -1761,7 +1730,8 @@ void ata_sff_thaw(struct ata_port *ap) | |||
| 1761 | { | 1730 | { |
| 1762 | /* clear & re-enable interrupts */ | 1731 | /* clear & re-enable interrupts */ |
| 1763 | ap->ops->sff_check_status(ap); | 1732 | ap->ops->sff_check_status(ap); |
| 1764 | ap->ops->sff_irq_clear(ap); | 1733 | if (ap->ops->sff_irq_clear) |
| 1734 | ap->ops->sff_irq_clear(ap); | ||
| 1765 | ata_sff_irq_on(ap); | 1735 | ata_sff_irq_on(ap); |
| 1766 | } | 1736 | } |
| 1767 | EXPORT_SYMBOL_GPL(ata_sff_thaw); | 1737 | EXPORT_SYMBOL_GPL(ata_sff_thaw); |
| @@ -2349,13 +2319,13 @@ int ata_pci_sff_init_host(struct ata_host *host) | |||
| 2349 | EXPORT_SYMBOL_GPL(ata_pci_sff_init_host); | 2319 | EXPORT_SYMBOL_GPL(ata_pci_sff_init_host); |
| 2350 | 2320 | ||
| 2351 | /** | 2321 | /** |
| 2352 | * ata_pci_sff_prepare_host - helper to prepare native PCI ATA host | 2322 | * ata_pci_sff_prepare_host - helper to prepare PCI PIO-only SFF ATA host |
| 2353 | * @pdev: target PCI device | 2323 | * @pdev: target PCI device |
| 2354 | * @ppi: array of port_info, must be enough for two ports | 2324 | * @ppi: array of port_info, must be enough for two ports |
| 2355 | * @r_host: out argument for the initialized ATA host | 2325 | * @r_host: out argument for the initialized ATA host |
| 2356 | * | 2326 | * |
| 2357 | * Helper to allocate ATA host for @pdev, acquire all native PCI | 2327 | * Helper to allocate PIO-only SFF ATA host for @pdev, acquire |
| 2358 | * resources and initialize it accordingly in one go. | 2328 | * all PCI resources and initialize it accordingly in one go. |
| 2359 | * | 2329 | * |
| 2360 | * LOCKING: | 2330 | * LOCKING: |
| 2361 | * Inherited from calling layer (may sleep). | 2331 | * Inherited from calling layer (may sleep). |
| @@ -2385,9 +2355,6 @@ int ata_pci_sff_prepare_host(struct pci_dev *pdev, | |||
| 2385 | if (rc) | 2355 | if (rc) |
| 2386 | goto err_out; | 2356 | goto err_out; |
| 2387 | 2357 | ||
| 2388 | /* init DMA related stuff */ | ||
| 2389 | ata_pci_bmdma_init(host); | ||
| 2390 | |||
| 2391 | devres_remove_group(&pdev->dev, NULL); | 2358 | devres_remove_group(&pdev->dev, NULL); |
| 2392 | *r_host = host; | 2359 | *r_host = host; |
| 2393 | return 0; | 2360 | return 0; |
| @@ -2492,8 +2459,21 @@ out: | |||
| 2492 | } | 2459 | } |
| 2493 | EXPORT_SYMBOL_GPL(ata_pci_sff_activate_host); | 2460 | EXPORT_SYMBOL_GPL(ata_pci_sff_activate_host); |
| 2494 | 2461 | ||
| 2462 | static const struct ata_port_info *ata_sff_find_valid_pi( | ||
| 2463 | const struct ata_port_info * const *ppi) | ||
| 2464 | { | ||
| 2465 | int i; | ||
| 2466 | |||
| 2467 | /* look up the first valid port_info */ | ||
| 2468 | for (i = 0; i < 2 && ppi[i]; i++) | ||
| 2469 | if (ppi[i]->port_ops != &ata_dummy_port_ops) | ||
| 2470 | return ppi[i]; | ||
| 2471 | |||
| 2472 | return NULL; | ||
| 2473 | } | ||
| 2474 | |||
| 2495 | /** | 2475 | /** |
| 2496 | * ata_pci_sff_init_one - Initialize/register PCI IDE host controller | 2476 | * ata_pci_sff_init_one - Initialize/register PIO-only PCI IDE controller |
| 2497 | * @pdev: Controller to be initialized | 2477 | * @pdev: Controller to be initialized |
| 2498 | * @ppi: array of port_info, must be enough for two ports | 2478 | * @ppi: array of port_info, must be enough for two ports |
| 2499 | * @sht: scsi_host_template to use when registering the host | 2479 | * @sht: scsi_host_template to use when registering the host |
| @@ -2502,11 +2482,7 @@ EXPORT_SYMBOL_GPL(ata_pci_sff_activate_host); | |||
| 2502 | * | 2482 | * |
| 2503 | * This is a helper function which can be called from a driver's | 2483 | * This is a helper function which can be called from a driver's |
| 2504 | * xxx_init_one() probe function if the hardware uses traditional | 2484 | * xxx_init_one() probe function if the hardware uses traditional |
| 2505 | * IDE taskfile registers. | 2485 | * IDE taskfile registers and is PIO only. |
| 2506 | * | ||
| 2507 | * This function calls pci_enable_device(), reserves its register | ||
| 2508 | * regions, sets the dma mask, enables bus master mode, and calls | ||
| 2509 | * ata_device_add() | ||
| 2510 | * | 2486 | * |
| 2511 | * ASSUMPTION: | 2487 | * ASSUMPTION: |
| 2512 | * Nobody makes a single channel controller that appears solely as | 2488 | * Nobody makes a single channel controller that appears solely as |
| @@ -2523,20 +2499,13 @@ int ata_pci_sff_init_one(struct pci_dev *pdev, | |||
| 2523 | struct scsi_host_template *sht, void *host_priv, int hflag) | 2499 | struct scsi_host_template *sht, void *host_priv, int hflag) |
| 2524 | { | 2500 | { |
| 2525 | struct device *dev = &pdev->dev; | 2501 | struct device *dev = &pdev->dev; |
| 2526 | const struct ata_port_info *pi = NULL; | 2502 | const struct ata_port_info *pi; |
| 2527 | struct ata_host *host = NULL; | 2503 | struct ata_host *host = NULL; |
| 2528 | int i, rc; | 2504 | int rc; |
| 2529 | 2505 | ||
| 2530 | DPRINTK("ENTER\n"); | 2506 | DPRINTK("ENTER\n"); |
| 2531 | 2507 | ||
| 2532 | /* look up the first valid port_info */ | 2508 | pi = ata_sff_find_valid_pi(ppi); |
| 2533 | for (i = 0; i < 2 && ppi[i]; i++) { | ||
| 2534 | if (ppi[i]->port_ops != &ata_dummy_port_ops) { | ||
| 2535 | pi = ppi[i]; | ||
| 2536 | break; | ||
| 2537 | } | ||
| 2538 | } | ||
| 2539 | |||
| 2540 | if (!pi) { | 2509 | if (!pi) { |
| 2541 | dev_printk(KERN_ERR, &pdev->dev, | 2510 | dev_printk(KERN_ERR, &pdev->dev, |
| 2542 | "no valid port_info specified\n"); | 2511 | "no valid port_info specified\n"); |
| @@ -2557,7 +2526,6 @@ int ata_pci_sff_init_one(struct pci_dev *pdev, | |||
| 2557 | host->private_data = host_priv; | 2526 | host->private_data = host_priv; |
| 2558 | host->flags |= hflag; | 2527 | host->flags |= hflag; |
| 2559 | 2528 | ||
| 2560 | pci_set_master(pdev); | ||
| 2561 | rc = ata_pci_sff_activate_host(host, ata_sff_interrupt, sht); | 2529 | rc = ata_pci_sff_activate_host(host, ata_sff_interrupt, sht); |
| 2562 | out: | 2530 | out: |
| 2563 | if (rc == 0) | 2531 | if (rc == 0) |
| @@ -2571,6 +2539,12 @@ EXPORT_SYMBOL_GPL(ata_pci_sff_init_one); | |||
| 2571 | 2539 | ||
| 2572 | #endif /* CONFIG_PCI */ | 2540 | #endif /* CONFIG_PCI */ |
| 2573 | 2541 | ||
| 2542 | /* | ||
| 2543 | * BMDMA support | ||
| 2544 | */ | ||
| 2545 | |||
| 2546 | #ifdef CONFIG_ATA_BMDMA | ||
| 2547 | |||
| 2574 | const struct ata_port_operations ata_bmdma_port_ops = { | 2548 | const struct ata_port_operations ata_bmdma_port_ops = { |
| 2575 | .inherits = &ata_sff_port_ops, | 2549 | .inherits = &ata_sff_port_ops, |
| 2576 | 2550 | ||
| @@ -2580,6 +2554,7 @@ const struct ata_port_operations ata_bmdma_port_ops = { | |||
| 2580 | .qc_prep = ata_bmdma_qc_prep, | 2554 | .qc_prep = ata_bmdma_qc_prep, |
| 2581 | .qc_issue = ata_bmdma_qc_issue, | 2555 | .qc_issue = ata_bmdma_qc_issue, |
| 2582 | 2556 | ||
| 2557 | .sff_irq_clear = ata_bmdma_irq_clear, | ||
| 2583 | .bmdma_setup = ata_bmdma_setup, | 2558 | .bmdma_setup = ata_bmdma_setup, |
| 2584 | .bmdma_start = ata_bmdma_start, | 2559 | .bmdma_start = ata_bmdma_start, |
| 2585 | .bmdma_stop = ata_bmdma_stop, | 2560 | .bmdma_stop = ata_bmdma_stop, |
| @@ -2804,6 +2779,75 @@ unsigned int ata_bmdma_qc_issue(struct ata_queued_cmd *qc) | |||
| 2804 | EXPORT_SYMBOL_GPL(ata_bmdma_qc_issue); | 2779 | EXPORT_SYMBOL_GPL(ata_bmdma_qc_issue); |
| 2805 | 2780 | ||
| 2806 | /** | 2781 | /** |
| 2782 | * ata_bmdma_port_intr - Handle BMDMA port interrupt | ||
| 2783 | * @ap: Port on which interrupt arrived (possibly...) | ||
| 2784 | * @qc: Taskfile currently active in engine | ||
| 2785 | * | ||
| 2786 | * Handle port interrupt for given queued command. | ||
| 2787 | * | ||
| 2788 | * LOCKING: | ||
| 2789 | * spin_lock_irqsave(host lock) | ||
| 2790 | * | ||
| 2791 | * RETURNS: | ||
| 2792 | * One if interrupt was handled, zero if not (shared irq). | ||
| 2793 | */ | ||
| 2794 | unsigned int ata_bmdma_port_intr(struct ata_port *ap, struct ata_queued_cmd *qc) | ||
| 2795 | { | ||
| 2796 | struct ata_eh_info *ehi = &ap->link.eh_info; | ||
| 2797 | u8 host_stat = 0; | ||
| 2798 | bool bmdma_stopped = false; | ||
| 2799 | unsigned int handled; | ||
| 2800 | |||
| 2801 | if (ap->hsm_task_state == HSM_ST_LAST && ata_is_dma(qc->tf.protocol)) { | ||
| 2802 | /* check status of DMA engine */ | ||
| 2803 | host_stat = ap->ops->bmdma_status(ap); | ||
| 2804 | VPRINTK("ata%u: host_stat 0x%X\n", ap->print_id, host_stat); | ||
| 2805 | |||
| 2806 | /* if it's not our irq... */ | ||
| 2807 | if (!(host_stat & ATA_DMA_INTR)) | ||
| 2808 | return ata_sff_idle_irq(ap); | ||
| 2809 | |||
| 2810 | /* before we do anything else, clear DMA-Start bit */ | ||
| 2811 | ap->ops->bmdma_stop(qc); | ||
| 2812 | bmdma_stopped = true; | ||
| 2813 | |||
| 2814 | if (unlikely(host_stat & ATA_DMA_ERR)) { | ||
| 2815 | /* error when transfering data to/from memory */ | ||
| 2816 | qc->err_mask |= AC_ERR_HOST_BUS; | ||
| 2817 | ap->hsm_task_state = HSM_ST_ERR; | ||
| 2818 | } | ||
| 2819 | } | ||
| 2820 | |||
| 2821 | handled = __ata_sff_port_intr(ap, qc, bmdma_stopped); | ||
| 2822 | |||
| 2823 | if (unlikely(qc->err_mask) && ata_is_dma(qc->tf.protocol)) | ||
| 2824 | ata_ehi_push_desc(ehi, "BMDMA stat 0x%x", host_stat); | ||
| 2825 | |||
| 2826 | return handled; | ||
| 2827 | } | ||
| 2828 | EXPORT_SYMBOL_GPL(ata_bmdma_port_intr); | ||
| 2829 | |||
| 2830 | /** | ||
| 2831 | * ata_bmdma_interrupt - Default BMDMA ATA host interrupt handler | ||
| 2832 | * @irq: irq line (unused) | ||
| 2833 | * @dev_instance: pointer to our ata_host information structure | ||
| 2834 | * | ||
| 2835 | * Default interrupt handler for PCI IDE devices. Calls | ||
| 2836 | * ata_bmdma_port_intr() for each port that is not disabled. | ||
| 2837 | * | ||
| 2838 | * LOCKING: | ||
| 2839 | * Obtains host lock during operation. | ||
| 2840 | * | ||
| 2841 | * RETURNS: | ||
| 2842 | * IRQ_NONE or IRQ_HANDLED. | ||
| 2843 | */ | ||
| 2844 | irqreturn_t ata_bmdma_interrupt(int irq, void *dev_instance) | ||
| 2845 | { | ||
| 2846 | return __ata_sff_interrupt(irq, dev_instance, ata_bmdma_port_intr); | ||
| 2847 | } | ||
| 2848 | EXPORT_SYMBOL_GPL(ata_bmdma_interrupt); | ||
| 2849 | |||
| 2850 | /** | ||
| 2807 | * ata_bmdma_error_handler - Stock error handler for BMDMA controller | 2851 | * ata_bmdma_error_handler - Stock error handler for BMDMA controller |
| 2808 | * @ap: port to handle error for | 2852 | * @ap: port to handle error for |
| 2809 | * | 2853 | * |
| @@ -2848,7 +2892,8 @@ void ata_bmdma_error_handler(struct ata_port *ap) | |||
| 2848 | /* if we're gonna thaw, make sure IRQ is clear */ | 2892 | /* if we're gonna thaw, make sure IRQ is clear */ |
| 2849 | if (thaw) { | 2893 | if (thaw) { |
| 2850 | ap->ops->sff_check_status(ap); | 2894 | ap->ops->sff_check_status(ap); |
| 2851 | ap->ops->sff_irq_clear(ap); | 2895 | if (ap->ops->sff_irq_clear) |
| 2896 | ap->ops->sff_irq_clear(ap); | ||
| 2852 | } | 2897 | } |
| 2853 | } | 2898 | } |
| 2854 | 2899 | ||
| @@ -2882,6 +2927,28 @@ void ata_bmdma_post_internal_cmd(struct ata_queued_cmd *qc) | |||
| 2882 | EXPORT_SYMBOL_GPL(ata_bmdma_post_internal_cmd); | 2927 | EXPORT_SYMBOL_GPL(ata_bmdma_post_internal_cmd); |
| 2883 | 2928 | ||
| 2884 | /** | 2929 | /** |
| 2930 | * ata_bmdma_irq_clear - Clear PCI IDE BMDMA interrupt. | ||
| 2931 | * @ap: Port associated with this ATA transaction. | ||
| 2932 | * | ||
| 2933 | * Clear interrupt and error flags in DMA status register. | ||
| 2934 | * | ||
| 2935 | * May be used as the irq_clear() entry in ata_port_operations. | ||
| 2936 | * | ||
| 2937 | * LOCKING: | ||
| 2938 | * spin_lock_irqsave(host lock) | ||
| 2939 | */ | ||
| 2940 | void ata_bmdma_irq_clear(struct ata_port *ap) | ||
| 2941 | { | ||
| 2942 | void __iomem *mmio = ap->ioaddr.bmdma_addr; | ||
| 2943 | |||
| 2944 | if (!mmio) | ||
| 2945 | return; | ||
| 2946 | |||
| 2947 | iowrite8(ioread8(mmio + ATA_DMA_STATUS), mmio + ATA_DMA_STATUS); | ||
| 2948 | } | ||
| 2949 | EXPORT_SYMBOL_GPL(ata_bmdma_irq_clear); | ||
| 2950 | |||
| 2951 | /** | ||
| 2885 | * ata_bmdma_setup - Set up PCI IDE BMDMA transaction | 2952 | * ata_bmdma_setup - Set up PCI IDE BMDMA transaction |
| 2886 | * @qc: Info associated with this ATA transaction. | 2953 | * @qc: Info associated with this ATA transaction. |
| 2887 | * | 2954 | * |
| @@ -3137,7 +3204,100 @@ void ata_pci_bmdma_init(struct ata_host *host) | |||
| 3137 | } | 3204 | } |
| 3138 | EXPORT_SYMBOL_GPL(ata_pci_bmdma_init); | 3205 | EXPORT_SYMBOL_GPL(ata_pci_bmdma_init); |
| 3139 | 3206 | ||
| 3207 | /** | ||
| 3208 | * ata_pci_bmdma_prepare_host - helper to prepare PCI BMDMA ATA host | ||
| 3209 | * @pdev: target PCI device | ||
| 3210 | * @ppi: array of port_info, must be enough for two ports | ||
| 3211 | * @r_host: out argument for the initialized ATA host | ||
| 3212 | * | ||
| 3213 | * Helper to allocate BMDMA ATA host for @pdev, acquire all PCI | ||
| 3214 | * resources and initialize it accordingly in one go. | ||
| 3215 | * | ||
| 3216 | * LOCKING: | ||
| 3217 | * Inherited from calling layer (may sleep). | ||
| 3218 | * | ||
| 3219 | * RETURNS: | ||
| 3220 | * 0 on success, -errno otherwise. | ||
| 3221 | */ | ||
| 3222 | int ata_pci_bmdma_prepare_host(struct pci_dev *pdev, | ||
| 3223 | const struct ata_port_info * const * ppi, | ||
| 3224 | struct ata_host **r_host) | ||
| 3225 | { | ||
| 3226 | int rc; | ||
| 3227 | |||
| 3228 | rc = ata_pci_sff_prepare_host(pdev, ppi, r_host); | ||
| 3229 | if (rc) | ||
| 3230 | return rc; | ||
| 3231 | |||
| 3232 | ata_pci_bmdma_init(*r_host); | ||
| 3233 | return 0; | ||
| 3234 | } | ||
| 3235 | EXPORT_SYMBOL_GPL(ata_pci_bmdma_prepare_host); | ||
| 3236 | |||
| 3237 | /** | ||
| 3238 | * ata_pci_bmdma_init_one - Initialize/register BMDMA PCI IDE controller | ||
| 3239 | * @pdev: Controller to be initialized | ||
| 3240 | * @ppi: array of port_info, must be enough for two ports | ||
| 3241 | * @sht: scsi_host_template to use when registering the host | ||
| 3242 | * @host_priv: host private_data | ||
| 3243 | * @hflags: host flags | ||
| 3244 | * | ||
| 3245 | * This function is similar to ata_pci_sff_init_one() but also | ||
| 3246 | * takes care of BMDMA initialization. | ||
| 3247 | * | ||
| 3248 | * LOCKING: | ||
| 3249 | * Inherited from PCI layer (may sleep). | ||
| 3250 | * | ||
| 3251 | * RETURNS: | ||
| 3252 | * Zero on success, negative on errno-based value on error. | ||
| 3253 | */ | ||
| 3254 | int ata_pci_bmdma_init_one(struct pci_dev *pdev, | ||
| 3255 | const struct ata_port_info * const * ppi, | ||
| 3256 | struct scsi_host_template *sht, void *host_priv, | ||
| 3257 | int hflags) | ||
| 3258 | { | ||
| 3259 | struct device *dev = &pdev->dev; | ||
| 3260 | const struct ata_port_info *pi; | ||
| 3261 | struct ata_host *host = NULL; | ||
| 3262 | int rc; | ||
| 3263 | |||
| 3264 | DPRINTK("ENTER\n"); | ||
| 3265 | |||
| 3266 | pi = ata_sff_find_valid_pi(ppi); | ||
| 3267 | if (!pi) { | ||
| 3268 | dev_printk(KERN_ERR, &pdev->dev, | ||
| 3269 | "no valid port_info specified\n"); | ||
| 3270 | return -EINVAL; | ||
| 3271 | } | ||
| 3272 | |||
| 3273 | if (!devres_open_group(dev, NULL, GFP_KERNEL)) | ||
| 3274 | return -ENOMEM; | ||
| 3275 | |||
| 3276 | rc = pcim_enable_device(pdev); | ||
| 3277 | if (rc) | ||
| 3278 | goto out; | ||
| 3279 | |||
| 3280 | /* prepare and activate BMDMA host */ | ||
| 3281 | rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); | ||
| 3282 | if (rc) | ||
| 3283 | goto out; | ||
| 3284 | host->private_data = host_priv; | ||
| 3285 | host->flags |= hflags; | ||
| 3286 | |||
| 3287 | pci_set_master(pdev); | ||
| 3288 | rc = ata_pci_sff_activate_host(host, ata_bmdma_interrupt, sht); | ||
| 3289 | out: | ||
| 3290 | if (rc == 0) | ||
| 3291 | devres_remove_group(&pdev->dev, NULL); | ||
| 3292 | else | ||
| 3293 | devres_release_group(&pdev->dev, NULL); | ||
| 3294 | |||
| 3295 | return rc; | ||
| 3296 | } | ||
| 3297 | EXPORT_SYMBOL_GPL(ata_pci_bmdma_init_one); | ||
| 3298 | |||
| 3140 | #endif /* CONFIG_PCI */ | 3299 | #endif /* CONFIG_PCI */ |
| 3300 | #endif /* CONFIG_ATA_BMDMA */ | ||
| 3141 | 3301 | ||
| 3142 | /** | 3302 | /** |
| 3143 | * ata_sff_port_init - Initialize SFF/BMDMA ATA port | 3303 | * ata_sff_port_init - Initialize SFF/BMDMA ATA port |
diff --git a/drivers/ata/pata_acpi.c b/drivers/ata/pata_acpi.c index 066b9f301ed5..c8d47034d5e9 100644 --- a/drivers/ata/pata_acpi.c +++ b/drivers/ata/pata_acpi.c | |||
| @@ -260,7 +260,7 @@ static int pacpi_init_one (struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 260 | return rc; | 260 | return rc; |
| 261 | pcim_pin_device(pdev); | 261 | pcim_pin_device(pdev); |
| 262 | } | 262 | } |
| 263 | return ata_pci_sff_init_one(pdev, ppi, &pacpi_sht, NULL, 0); | 263 | return ata_pci_bmdma_init_one(pdev, ppi, &pacpi_sht, NULL, 0); |
| 264 | } | 264 | } |
| 265 | 265 | ||
| 266 | static const struct pci_device_id pacpi_pci_tbl[] = { | 266 | static const struct pci_device_id pacpi_pci_tbl[] = { |
diff --git a/drivers/ata/pata_ali.c b/drivers/ata/pata_ali.c index f306e10c748d..794ec6e3275d 100644 --- a/drivers/ata/pata_ali.c +++ b/drivers/ata/pata_ali.c | |||
| @@ -583,7 +583,10 @@ static int ali_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 583 | ppi[0] = &info_20_udma; | 583 | ppi[0] = &info_20_udma; |
| 584 | } | 584 | } |
| 585 | 585 | ||
| 586 | return ata_pci_sff_init_one(pdev, ppi, &ali_sht, NULL, 0); | 586 | if (!ppi[0]->mwdma_mask && !ppi[0]->udma_mask) |
| 587 | return ata_pci_sff_init_one(pdev, ppi, &ali_sht, NULL, 0); | ||
| 588 | else | ||
| 589 | return ata_pci_bmdma_init_one(pdev, ppi, &ali_sht, NULL, 0); | ||
| 587 | } | 590 | } |
| 588 | 591 | ||
| 589 | #ifdef CONFIG_PM | 592 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_amd.c b/drivers/ata/pata_amd.c index d95eca9c547e..620a07cabe31 100644 --- a/drivers/ata/pata_amd.c +++ b/drivers/ata/pata_amd.c | |||
| @@ -574,7 +574,7 @@ static int amd_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 574 | } | 574 | } |
| 575 | 575 | ||
| 576 | /* And fire it up */ | 576 | /* And fire it up */ |
| 577 | return ata_pci_sff_init_one(pdev, ppi, &amd_sht, hpriv, 0); | 577 | return ata_pci_bmdma_init_one(pdev, ppi, &amd_sht, hpriv, 0); |
| 578 | } | 578 | } |
| 579 | 579 | ||
| 580 | #ifdef CONFIG_PM | 580 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_artop.c b/drivers/ata/pata_artop.c index 4d066d6c30fa..ba43f0f8c880 100644 --- a/drivers/ata/pata_artop.c +++ b/drivers/ata/pata_artop.c | |||
| @@ -421,7 +421,7 @@ static int artop_init_one (struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 421 | 421 | ||
| 422 | BUG_ON(ppi[0] == NULL); | 422 | BUG_ON(ppi[0] == NULL); |
| 423 | 423 | ||
| 424 | return ata_pci_sff_init_one(pdev, ppi, &artop_sht, NULL, 0); | 424 | return ata_pci_bmdma_init_one(pdev, ppi, &artop_sht, NULL, 0); |
| 425 | } | 425 | } |
| 426 | 426 | ||
| 427 | static const struct pci_device_id artop_pci_tbl[] = { | 427 | static const struct pci_device_id artop_pci_tbl[] = { |
diff --git a/drivers/ata/pata_atiixp.c b/drivers/ata/pata_atiixp.c index 44d88b380ddd..43755616dc5a 100644 --- a/drivers/ata/pata_atiixp.c +++ b/drivers/ata/pata_atiixp.c | |||
| @@ -246,8 +246,8 @@ static int atiixp_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 246 | if (!pci_test_config_bits(pdev, &atiixp_enable_bits[i])) | 246 | if (!pci_test_config_bits(pdev, &atiixp_enable_bits[i])) |
| 247 | ppi[i] = &ata_dummy_port_info; | 247 | ppi[i] = &ata_dummy_port_info; |
| 248 | 248 | ||
| 249 | return ata_pci_sff_init_one(pdev, ppi, &atiixp_sht, NULL, | 249 | return ata_pci_bmdma_init_one(pdev, ppi, &atiixp_sht, NULL, |
| 250 | ATA_HOST_PARALLEL_SCAN); | 250 | ATA_HOST_PARALLEL_SCAN); |
| 251 | } | 251 | } |
| 252 | 252 | ||
| 253 | static const struct pci_device_id atiixp[] = { | 253 | static const struct pci_device_id atiixp[] = { |
diff --git a/drivers/ata/pata_atp867x.c b/drivers/ata/pata_atp867x.c index bb6e0746e07d..95295935dd95 100644 --- a/drivers/ata/pata_atp867x.c +++ b/drivers/ata/pata_atp867x.c | |||
| @@ -525,7 +525,7 @@ static int atp867x_init_one(struct pci_dev *pdev, | |||
| 525 | 525 | ||
| 526 | pci_set_master(pdev); | 526 | pci_set_master(pdev); |
| 527 | 527 | ||
| 528 | rc = ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 528 | rc = ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 529 | IRQF_SHARED, &atp867x_sht); | 529 | IRQF_SHARED, &atp867x_sht); |
| 530 | if (rc) | 530 | if (rc) |
| 531 | dev_printk(KERN_ERR, &pdev->dev, "failed to activate host\n"); | 531 | dev_printk(KERN_ERR, &pdev->dev, "failed to activate host\n"); |
diff --git a/drivers/ata/pata_bf54x.c b/drivers/ata/pata_bf54x.c index 6422cfd13d0d..9cae65de750e 100644 --- a/drivers/ata/pata_bf54x.c +++ b/drivers/ata/pata_bf54x.c | |||
| @@ -1214,7 +1214,7 @@ static unsigned int bfin_data_xfer(struct ata_device *dev, unsigned char *buf, | |||
| 1214 | * bfin_irq_clear - Clear ATAPI interrupt. | 1214 | * bfin_irq_clear - Clear ATAPI interrupt. |
| 1215 | * @ap: Port associated with this ATA transaction. | 1215 | * @ap: Port associated with this ATA transaction. |
| 1216 | * | 1216 | * |
| 1217 | * Note: Original code is ata_sff_irq_clear(). | 1217 | * Note: Original code is ata_bmdma_irq_clear(). |
| 1218 | */ | 1218 | */ |
| 1219 | 1219 | ||
| 1220 | static void bfin_irq_clear(struct ata_port *ap) | 1220 | static void bfin_irq_clear(struct ata_port *ap) |
diff --git a/drivers/ata/pata_cmd64x.c b/drivers/ata/pata_cmd64x.c index 4c81a71b8877..9f5da1c7454b 100644 --- a/drivers/ata/pata_cmd64x.c +++ b/drivers/ata/pata_cmd64x.c | |||
| @@ -367,7 +367,7 @@ static int cmd64x_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 367 | pci_write_config_byte(pdev, UDIDETCR0, 0xF0); | 367 | pci_write_config_byte(pdev, UDIDETCR0, 0xF0); |
| 368 | #endif | 368 | #endif |
| 369 | 369 | ||
| 370 | return ata_pci_sff_init_one(pdev, ppi, &cmd64x_sht, NULL, 0); | 370 | return ata_pci_bmdma_init_one(pdev, ppi, &cmd64x_sht, NULL, 0); |
| 371 | } | 371 | } |
| 372 | 372 | ||
| 373 | #ifdef CONFIG_PM | 373 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_cs5520.c b/drivers/ata/pata_cs5520.c index 17c5f346ff01..030952f1f97c 100644 --- a/drivers/ata/pata_cs5520.c +++ b/drivers/ata/pata_cs5520.c | |||
| @@ -221,7 +221,7 @@ static int __devinit cs5520_init_one(struct pci_dev *pdev, const struct pci_devi | |||
| 221 | continue; | 221 | continue; |
| 222 | 222 | ||
| 223 | rc = devm_request_irq(&pdev->dev, irq[ap->port_no], | 223 | rc = devm_request_irq(&pdev->dev, irq[ap->port_no], |
| 224 | ata_sff_interrupt, 0, DRV_NAME, host); | 224 | ata_bmdma_interrupt, 0, DRV_NAME, host); |
| 225 | if (rc) | 225 | if (rc) |
| 226 | return rc; | 226 | return rc; |
| 227 | 227 | ||
diff --git a/drivers/ata/pata_cs5530.c b/drivers/ata/pata_cs5530.c index e809a4233a81..f792330f0d8e 100644 --- a/drivers/ata/pata_cs5530.c +++ b/drivers/ata/pata_cs5530.c | |||
| @@ -324,7 +324,7 @@ static int cs5530_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 324 | ppi[1] = &info_palmax_secondary; | 324 | ppi[1] = &info_palmax_secondary; |
| 325 | 325 | ||
| 326 | /* Now kick off ATA set up */ | 326 | /* Now kick off ATA set up */ |
| 327 | return ata_pci_sff_init_one(pdev, ppi, &cs5530_sht, NULL, 0); | 327 | return ata_pci_bmdma_init_one(pdev, ppi, &cs5530_sht, NULL, 0); |
| 328 | } | 328 | } |
| 329 | 329 | ||
| 330 | #ifdef CONFIG_PM | 330 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_cs5535.c b/drivers/ata/pata_cs5535.c index a02e6459fdcc..03a93186aa19 100644 --- a/drivers/ata/pata_cs5535.c +++ b/drivers/ata/pata_cs5535.c | |||
| @@ -198,7 +198,7 @@ static int cs5535_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 198 | rdmsr(ATAC_CH0D1_PIO, timings, dummy); | 198 | rdmsr(ATAC_CH0D1_PIO, timings, dummy); |
| 199 | if (CS5535_BAD_PIO(timings)) | 199 | if (CS5535_BAD_PIO(timings)) |
| 200 | wrmsr(ATAC_CH0D1_PIO, 0xF7F4F7F4UL, 0); | 200 | wrmsr(ATAC_CH0D1_PIO, 0xF7F4F7F4UL, 0); |
| 201 | return ata_pci_sff_init_one(dev, ppi, &cs5535_sht, NULL, 0); | 201 | return ata_pci_bmdma_init_one(dev, ppi, &cs5535_sht, NULL, 0); |
| 202 | } | 202 | } |
| 203 | 203 | ||
| 204 | static const struct pci_device_id cs5535[] = { | 204 | static const struct pci_device_id cs5535[] = { |
diff --git a/drivers/ata/pata_cs5536.c b/drivers/ata/pata_cs5536.c index 914ae3506ff5..21ee23f89e88 100644 --- a/drivers/ata/pata_cs5536.c +++ b/drivers/ata/pata_cs5536.c | |||
| @@ -260,7 +260,7 @@ static int cs5536_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 260 | return -ENODEV; | 260 | return -ENODEV; |
| 261 | } | 261 | } |
| 262 | 262 | ||
| 263 | return ata_pci_sff_init_one(dev, ppi, &cs5536_sht, NULL, 0); | 263 | return ata_pci_bmdma_init_one(dev, ppi, &cs5536_sht, NULL, 0); |
| 264 | } | 264 | } |
| 265 | 265 | ||
| 266 | static const struct pci_device_id cs5536[] = { | 266 | static const struct pci_device_id cs5536[] = { |
diff --git a/drivers/ata/pata_cypress.c b/drivers/ata/pata_cypress.c index 0fcc096b8dac..6d915b063d93 100644 --- a/drivers/ata/pata_cypress.c +++ b/drivers/ata/pata_cypress.c | |||
| @@ -138,7 +138,7 @@ static int cy82c693_init_one(struct pci_dev *pdev, const struct pci_device_id *i | |||
| 138 | if (PCI_FUNC(pdev->devfn) != 1) | 138 | if (PCI_FUNC(pdev->devfn) != 1) |
| 139 | return -ENODEV; | 139 | return -ENODEV; |
| 140 | 140 | ||
| 141 | return ata_pci_sff_init_one(pdev, ppi, &cy82c693_sht, NULL, 0); | 141 | return ata_pci_bmdma_init_one(pdev, ppi, &cy82c693_sht, NULL, 0); |
| 142 | } | 142 | } |
| 143 | 143 | ||
| 144 | static const struct pci_device_id cy82c693[] = { | 144 | static const struct pci_device_id cy82c693[] = { |
diff --git a/drivers/ata/pata_efar.c b/drivers/ata/pata_efar.c index 3bac0e079691..a08834758ea2 100644 --- a/drivers/ata/pata_efar.c +++ b/drivers/ata/pata_efar.c | |||
| @@ -277,8 +277,8 @@ static int efar_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 277 | dev_printk(KERN_DEBUG, &pdev->dev, | 277 | dev_printk(KERN_DEBUG, &pdev->dev, |
| 278 | "version " DRV_VERSION "\n"); | 278 | "version " DRV_VERSION "\n"); |
| 279 | 279 | ||
| 280 | return ata_pci_sff_init_one(pdev, ppi, &efar_sht, NULL, | 280 | return ata_pci_bmdma_init_one(pdev, ppi, &efar_sht, NULL, |
| 281 | ATA_HOST_PARALLEL_SCAN); | 281 | ATA_HOST_PARALLEL_SCAN); |
| 282 | } | 282 | } |
| 283 | 283 | ||
| 284 | static const struct pci_device_id efar_pci_tbl[] = { | 284 | static const struct pci_device_id efar_pci_tbl[] = { |
diff --git a/drivers/ata/pata_hpt366.c b/drivers/ata/pata_hpt366.c index 8580eb3cd54d..7688868557b9 100644 --- a/drivers/ata/pata_hpt366.c +++ b/drivers/ata/pata_hpt366.c | |||
| @@ -361,7 +361,7 @@ static int hpt36x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 361 | break; | 361 | break; |
| 362 | } | 362 | } |
| 363 | /* Now kick off ATA set up */ | 363 | /* Now kick off ATA set up */ |
| 364 | return ata_pci_sff_init_one(dev, ppi, &hpt36x_sht, hpriv, 0); | 364 | return ata_pci_bmdma_init_one(dev, ppi, &hpt36x_sht, hpriv, 0); |
| 365 | } | 365 | } |
| 366 | 366 | ||
| 367 | #ifdef CONFIG_PM | 367 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_hpt37x.c b/drivers/ata/pata_hpt37x.c index 98b498b6907c..9ae4c0830577 100644 --- a/drivers/ata/pata_hpt37x.c +++ b/drivers/ata/pata_hpt37x.c | |||
| @@ -987,7 +987,7 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 987 | } | 987 | } |
| 988 | 988 | ||
| 989 | /* Now kick off ATA set up */ | 989 | /* Now kick off ATA set up */ |
| 990 | return ata_pci_sff_init_one(dev, ppi, &hpt37x_sht, private_data, 0); | 990 | return ata_pci_bmdma_init_one(dev, ppi, &hpt37x_sht, private_data, 0); |
| 991 | } | 991 | } |
| 992 | 992 | ||
| 993 | static const struct pci_device_id hpt37x[] = { | 993 | static const struct pci_device_id hpt37x[] = { |
diff --git a/drivers/ata/pata_hpt3x2n.c b/drivers/ata/pata_hpt3x2n.c index 8b95aeba0e74..32f3463216b8 100644 --- a/drivers/ata/pata_hpt3x2n.c +++ b/drivers/ata/pata_hpt3x2n.c | |||
| @@ -548,7 +548,7 @@ static int hpt3x2n_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 548 | outb(inb(iobase + 0x9c) | 0x04, iobase + 0x9c); | 548 | outb(inb(iobase + 0x9c) | 0x04, iobase + 0x9c); |
| 549 | 549 | ||
| 550 | /* Now kick off ATA set up */ | 550 | /* Now kick off ATA set up */ |
| 551 | return ata_pci_sff_init_one(dev, ppi, &hpt3x2n_sht, hpriv, 0); | 551 | return ata_pci_bmdma_init_one(dev, ppi, &hpt3x2n_sht, hpriv, 0); |
| 552 | } | 552 | } |
| 553 | 553 | ||
| 554 | static const struct pci_device_id hpt3x2n[] = { | 554 | static const struct pci_device_id hpt3x2n[] = { |
diff --git a/drivers/ata/pata_hpt3x3.c b/drivers/ata/pata_hpt3x3.c index 727a81ce4c9f..b63d5e2d4628 100644 --- a/drivers/ata/pata_hpt3x3.c +++ b/drivers/ata/pata_hpt3x3.c | |||
| @@ -248,7 +248,7 @@ static int hpt3x3_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 248 | ata_port_pbar_desc(ap, 4, offset_cmd[i], "cmd"); | 248 | ata_port_pbar_desc(ap, 4, offset_cmd[i], "cmd"); |
| 249 | } | 249 | } |
| 250 | pci_set_master(pdev); | 250 | pci_set_master(pdev); |
| 251 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 251 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 252 | IRQF_SHARED, &hpt3x3_sht); | 252 | IRQF_SHARED, &hpt3x3_sht); |
| 253 | } | 253 | } |
| 254 | 254 | ||
diff --git a/drivers/ata/pata_icside.c b/drivers/ata/pata_icside.c index b56e8f722d20..9f2889fe43b2 100644 --- a/drivers/ata/pata_icside.c +++ b/drivers/ata/pata_icside.c | |||
| @@ -470,7 +470,7 @@ static int __devinit pata_icside_add_ports(struct pata_icside_info *info) | |||
| 470 | pata_icside_setup_ioaddr(ap, info->base, info, info->port[i]); | 470 | pata_icside_setup_ioaddr(ap, info->base, info, info->port[i]); |
| 471 | } | 471 | } |
| 472 | 472 | ||
| 473 | return ata_host_activate(host, ec->irq, ata_sff_interrupt, 0, | 473 | return ata_host_activate(host, ec->irq, ata_bmdma_interrupt, 0, |
| 474 | &pata_icside_sht); | 474 | &pata_icside_sht); |
| 475 | } | 475 | } |
| 476 | 476 | ||
diff --git a/drivers/ata/pata_it8213.c b/drivers/ata/pata_it8213.c index f971f0de88e6..4d142a2ab8fd 100644 --- a/drivers/ata/pata_it8213.c +++ b/drivers/ata/pata_it8213.c | |||
| @@ -273,7 +273,7 @@ static int it8213_init_one (struct pci_dev *pdev, const struct pci_device_id *en | |||
| 273 | dev_printk(KERN_DEBUG, &pdev->dev, | 273 | dev_printk(KERN_DEBUG, &pdev->dev, |
| 274 | "version " DRV_VERSION "\n"); | 274 | "version " DRV_VERSION "\n"); |
| 275 | 275 | ||
| 276 | return ata_pci_sff_init_one(pdev, ppi, &it8213_sht, NULL, 0); | 276 | return ata_pci_bmdma_init_one(pdev, ppi, &it8213_sht, NULL, 0); |
| 277 | } | 277 | } |
| 278 | 278 | ||
| 279 | static const struct pci_device_id it8213_pci_tbl[] = { | 279 | static const struct pci_device_id it8213_pci_tbl[] = { |
diff --git a/drivers/ata/pata_it821x.c b/drivers/ata/pata_it821x.c index 2bd2b002d14a..bf88f71a21f4 100644 --- a/drivers/ata/pata_it821x.c +++ b/drivers/ata/pata_it821x.c | |||
| @@ -933,7 +933,7 @@ static int it821x_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 933 | else | 933 | else |
| 934 | ppi[0] = &info_smart; | 934 | ppi[0] = &info_smart; |
| 935 | } | 935 | } |
| 936 | return ata_pci_sff_init_one(pdev, ppi, &it821x_sht, NULL, 0); | 936 | return ata_pci_bmdma_init_one(pdev, ppi, &it821x_sht, NULL, 0); |
| 937 | } | 937 | } |
| 938 | 938 | ||
| 939 | #ifdef CONFIG_PM | 939 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_jmicron.c b/drivers/ata/pata_jmicron.c index 565e01e6ac7c..cb3babbb7035 100644 --- a/drivers/ata/pata_jmicron.c +++ b/drivers/ata/pata_jmicron.c | |||
| @@ -144,7 +144,7 @@ static int jmicron_init_one (struct pci_dev *pdev, const struct pci_device_id *i | |||
| 144 | }; | 144 | }; |
| 145 | const struct ata_port_info *ppi[] = { &info, NULL }; | 145 | const struct ata_port_info *ppi[] = { &info, NULL }; |
| 146 | 146 | ||
| 147 | return ata_pci_sff_init_one(pdev, ppi, &jmicron_sht, NULL, 0); | 147 | return ata_pci_bmdma_init_one(pdev, ppi, &jmicron_sht, NULL, 0); |
| 148 | } | 148 | } |
| 149 | 149 | ||
| 150 | static const struct pci_device_id jmicron_pci_tbl[] = { | 150 | static const struct pci_device_id jmicron_pci_tbl[] = { |
diff --git a/drivers/ata/pata_macio.c b/drivers/ata/pata_macio.c index b5b48e703cb7..76640ac76888 100644 --- a/drivers/ata/pata_macio.c +++ b/drivers/ata/pata_macio.c | |||
| @@ -1110,7 +1110,7 @@ static int __devinit pata_macio_common_init(struct pata_macio_priv *priv, | |||
| 1110 | 1110 | ||
| 1111 | /* Start it up */ | 1111 | /* Start it up */ |
| 1112 | priv->irq = irq; | 1112 | priv->irq = irq; |
| 1113 | return ata_host_activate(priv->host, irq, ata_sff_interrupt, 0, | 1113 | return ata_host_activate(priv->host, irq, ata_bmdma_interrupt, 0, |
| 1114 | &pata_macio_sht); | 1114 | &pata_macio_sht); |
| 1115 | } | 1115 | } |
| 1116 | 1116 | ||
diff --git a/drivers/ata/pata_marvell.c b/drivers/ata/pata_marvell.c index e8ca02e5a71d..dd38083dcbeb 100644 --- a/drivers/ata/pata_marvell.c +++ b/drivers/ata/pata_marvell.c | |||
| @@ -153,7 +153,7 @@ static int marvell_init_one (struct pci_dev *pdev, const struct pci_device_id *i | |||
| 153 | return -ENODEV; | 153 | return -ENODEV; |
| 154 | } | 154 | } |
| 155 | #endif | 155 | #endif |
| 156 | return ata_pci_sff_init_one(pdev, ppi, &marvell_sht, NULL, 0); | 156 | return ata_pci_bmdma_init_one(pdev, ppi, &marvell_sht, NULL, 0); |
| 157 | } | 157 | } |
| 158 | 158 | ||
| 159 | static const struct pci_device_id marvell_pci_tbl[] = { | 159 | static const struct pci_device_id marvell_pci_tbl[] = { |
diff --git a/drivers/ata/pata_mpc52xx.c b/drivers/ata/pata_mpc52xx.c index 36afe2c1c747..f087ab55b1df 100644 --- a/drivers/ata/pata_mpc52xx.c +++ b/drivers/ata/pata_mpc52xx.c | |||
| @@ -659,7 +659,7 @@ mpc52xx_ata_init_one(struct device *dev, struct mpc52xx_ata_priv *priv, | |||
| 659 | ata_port_desc(ap, "ata_regs 0x%lx", raw_ata_regs); | 659 | ata_port_desc(ap, "ata_regs 0x%lx", raw_ata_regs); |
| 660 | 660 | ||
| 661 | /* activate host */ | 661 | /* activate host */ |
| 662 | return ata_host_activate(host, priv->ata_irq, ata_sff_interrupt, 0, | 662 | return ata_host_activate(host, priv->ata_irq, ata_bmdma_interrupt, 0, |
| 663 | &mpc52xx_ata_sht); | 663 | &mpc52xx_ata_sht); |
| 664 | } | 664 | } |
| 665 | 665 | ||
diff --git a/drivers/ata/pata_netcell.c b/drivers/ata/pata_netcell.c index 94f979a7f4f7..3eb921c746a1 100644 --- a/drivers/ata/pata_netcell.c +++ b/drivers/ata/pata_netcell.c | |||
| @@ -82,7 +82,7 @@ static int netcell_init_one (struct pci_dev *pdev, const struct pci_device_id *e | |||
| 82 | ata_pci_bmdma_clear_simplex(pdev); | 82 | ata_pci_bmdma_clear_simplex(pdev); |
| 83 | 83 | ||
| 84 | /* And let the library code do the work */ | 84 | /* And let the library code do the work */ |
| 85 | return ata_pci_sff_init_one(pdev, port_info, &netcell_sht, NULL, 0); | 85 | return ata_pci_bmdma_init_one(pdev, port_info, &netcell_sht, NULL, 0); |
| 86 | } | 86 | } |
| 87 | 87 | ||
| 88 | static const struct pci_device_id netcell_pci_tbl[] = { | 88 | static const struct pci_device_id netcell_pci_tbl[] = { |
diff --git a/drivers/ata/pata_ninja32.c b/drivers/ata/pata_ninja32.c index dd53a66b19e3..cc50bd09aa26 100644 --- a/drivers/ata/pata_ninja32.c +++ b/drivers/ata/pata_ninja32.c | |||
| @@ -149,7 +149,7 @@ static int ninja32_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 149 | 149 | ||
| 150 | ninja32_program(base); | 150 | ninja32_program(base); |
| 151 | /* FIXME: Should we disable them at remove ? */ | 151 | /* FIXME: Should we disable them at remove ? */ |
| 152 | return ata_host_activate(host, dev->irq, ata_sff_interrupt, | 152 | return ata_host_activate(host, dev->irq, ata_bmdma_interrupt, |
| 153 | IRQF_SHARED, &ninja32_sht); | 153 | IRQF_SHARED, &ninja32_sht); |
| 154 | } | 154 | } |
| 155 | 155 | ||
diff --git a/drivers/ata/pata_ns87415.c b/drivers/ata/pata_ns87415.c index fdbba2d76d3e..605f198f958c 100644 --- a/drivers/ata/pata_ns87415.c +++ b/drivers/ata/pata_ns87415.c | |||
| @@ -380,7 +380,7 @@ static int ns87415_init_one (struct pci_dev *pdev, const struct pci_device_id *e | |||
| 380 | 380 | ||
| 381 | ns87415_fixup(pdev); | 381 | ns87415_fixup(pdev); |
| 382 | 382 | ||
| 383 | return ata_pci_sff_init_one(pdev, ppi, &ns87415_sht, NULL, 0); | 383 | return ata_pci_bmdma_init_one(pdev, ppi, &ns87415_sht, NULL, 0); |
| 384 | } | 384 | } |
| 385 | 385 | ||
| 386 | static const struct pci_device_id ns87415_pci_tbl[] = { | 386 | static const struct pci_device_id ns87415_pci_tbl[] = { |
diff --git a/drivers/ata/pata_octeon_cf.c b/drivers/ata/pata_octeon_cf.c index 3001109352ea..06ddd91ffeda 100644 --- a/drivers/ata/pata_octeon_cf.c +++ b/drivers/ata/pata_octeon_cf.c | |||
| @@ -750,20 +750,6 @@ static void octeon_cf_dev_config(struct ata_device *dev) | |||
| 750 | } | 750 | } |
| 751 | 751 | ||
| 752 | /* | 752 | /* |
| 753 | * Trap if driver tries to do standard bmdma commands. They are not | ||
| 754 | * supported. | ||
| 755 | */ | ||
| 756 | static void unreachable_qc(struct ata_queued_cmd *qc) | ||
| 757 | { | ||
| 758 | BUG(); | ||
| 759 | } | ||
| 760 | |||
| 761 | static u8 unreachable_port(struct ata_port *ap) | ||
| 762 | { | ||
| 763 | BUG(); | ||
| 764 | } | ||
| 765 | |||
| 766 | /* | ||
| 767 | * We don't do ATAPI DMA so return 0. | 753 | * We don't do ATAPI DMA so return 0. |
| 768 | */ | 754 | */ |
| 769 | static int octeon_cf_check_atapi_dma(struct ata_queued_cmd *qc) | 755 | static int octeon_cf_check_atapi_dma(struct ata_queued_cmd *qc) |
| @@ -804,10 +790,6 @@ static struct ata_port_operations octeon_cf_ops = { | |||
| 804 | .sff_dev_select = octeon_cf_dev_select, | 790 | .sff_dev_select = octeon_cf_dev_select, |
| 805 | .sff_irq_on = octeon_cf_irq_on, | 791 | .sff_irq_on = octeon_cf_irq_on, |
| 806 | .sff_irq_clear = octeon_cf_irq_clear, | 792 | .sff_irq_clear = octeon_cf_irq_clear, |
| 807 | .bmdma_setup = unreachable_qc, | ||
| 808 | .bmdma_start = unreachable_qc, | ||
| 809 | .bmdma_stop = unreachable_qc, | ||
| 810 | .bmdma_status = unreachable_port, | ||
| 811 | .cable_detect = ata_cable_40wire, | 793 | .cable_detect = ata_cable_40wire, |
| 812 | .set_piomode = octeon_cf_set_piomode, | 794 | .set_piomode = octeon_cf_set_piomode, |
| 813 | .set_dmamode = octeon_cf_set_dmamode, | 795 | .set_dmamode = octeon_cf_set_dmamode, |
diff --git a/drivers/ata/pata_oldpiix.c b/drivers/ata/pata_oldpiix.c index 988ef2627be3..b811c1636204 100644 --- a/drivers/ata/pata_oldpiix.c +++ b/drivers/ata/pata_oldpiix.c | |||
| @@ -248,7 +248,7 @@ static int oldpiix_init_one (struct pci_dev *pdev, const struct pci_device_id *e | |||
| 248 | dev_printk(KERN_DEBUG, &pdev->dev, | 248 | dev_printk(KERN_DEBUG, &pdev->dev, |
| 249 | "version " DRV_VERSION "\n"); | 249 | "version " DRV_VERSION "\n"); |
| 250 | 250 | ||
| 251 | return ata_pci_sff_init_one(pdev, ppi, &oldpiix_sht, NULL, 0); | 251 | return ata_pci_bmdma_init_one(pdev, ppi, &oldpiix_sht, NULL, 0); |
| 252 | } | 252 | } |
| 253 | 253 | ||
| 254 | static const struct pci_device_id oldpiix_pci_tbl[] = { | 254 | static const struct pci_device_id oldpiix_pci_tbl[] = { |
diff --git a/drivers/ata/pata_optidma.c b/drivers/ata/pata_optidma.c index 76b7d12b1e8d..0852cd07de08 100644 --- a/drivers/ata/pata_optidma.c +++ b/drivers/ata/pata_optidma.c | |||
| @@ -429,7 +429,7 @@ static int optidma_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 429 | if (optiplus_with_udma(dev)) | 429 | if (optiplus_with_udma(dev)) |
| 430 | ppi[0] = &info_82c700_udma; | 430 | ppi[0] = &info_82c700_udma; |
| 431 | 431 | ||
| 432 | return ata_pci_sff_init_one(dev, ppi, &optidma_sht, NULL, 0); | 432 | return ata_pci_bmdma_init_one(dev, ppi, &optidma_sht, NULL, 0); |
| 433 | } | 433 | } |
| 434 | 434 | ||
| 435 | static const struct pci_device_id optidma[] = { | 435 | static const struct pci_device_id optidma[] = { |
diff --git a/drivers/ata/pata_pdc2027x.c b/drivers/ata/pata_pdc2027x.c index 09f1f22c0307..b18351122525 100644 --- a/drivers/ata/pata_pdc2027x.c +++ b/drivers/ata/pata_pdc2027x.c | |||
| @@ -754,7 +754,7 @@ static int __devinit pdc2027x_init_one(struct pci_dev *pdev, const struct pci_de | |||
| 754 | return -EIO; | 754 | return -EIO; |
| 755 | 755 | ||
| 756 | pci_set_master(pdev); | 756 | pci_set_master(pdev); |
| 757 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 757 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 758 | IRQF_SHARED, &pdc2027x_sht); | 758 | IRQF_SHARED, &pdc2027x_sht); |
| 759 | } | 759 | } |
| 760 | 760 | ||
diff --git a/drivers/ata/pata_pdc202xx_old.c b/drivers/ata/pata_pdc202xx_old.c index fa1e2f3bc0fd..c39f213e1bbc 100644 --- a/drivers/ata/pata_pdc202xx_old.c +++ b/drivers/ata/pata_pdc202xx_old.c | |||
| @@ -337,7 +337,7 @@ static int pdc202xx_init_one(struct pci_dev *dev, const struct pci_device_id *id | |||
| 337 | return -ENODEV; | 337 | return -ENODEV; |
| 338 | } | 338 | } |
| 339 | } | 339 | } |
| 340 | return ata_pci_sff_init_one(dev, ppi, &pdc202xx_sht, NULL, 0); | 340 | return ata_pci_bmdma_init_one(dev, ppi, &pdc202xx_sht, NULL, 0); |
| 341 | } | 341 | } |
| 342 | 342 | ||
| 343 | static const struct pci_device_id pdc202xx[] = { | 343 | static const struct pci_device_id pdc202xx[] = { |
diff --git a/drivers/ata/pata_piccolo.c b/drivers/ata/pata_piccolo.c index 981615414849..cb01bf9496fe 100644 --- a/drivers/ata/pata_piccolo.c +++ b/drivers/ata/pata_piccolo.c | |||
| @@ -95,7 +95,7 @@ static int ata_tosh_init_one(struct pci_dev *dev, const struct pci_device_id *id | |||
| 95 | }; | 95 | }; |
| 96 | const struct ata_port_info *ppi[] = { &info, &ata_dummy_port_info }; | 96 | const struct ata_port_info *ppi[] = { &info, &ata_dummy_port_info }; |
| 97 | /* Just one port for the moment */ | 97 | /* Just one port for the moment */ |
| 98 | return ata_pci_sff_init_one(dev, ppi, &tosh_sht, NULL, 0); | 98 | return ata_pci_bmdma_init_one(dev, ppi, &tosh_sht, NULL, 0); |
| 99 | } | 99 | } |
| 100 | 100 | ||
| 101 | static struct pci_device_id ata_tosh[] = { | 101 | static struct pci_device_id ata_tosh[] = { |
diff --git a/drivers/ata/pata_radisys.c b/drivers/ata/pata_radisys.c index a5fa388e5398..8574b31f1773 100644 --- a/drivers/ata/pata_radisys.c +++ b/drivers/ata/pata_radisys.c | |||
| @@ -227,7 +227,7 @@ static int radisys_init_one (struct pci_dev *pdev, const struct pci_device_id *e | |||
| 227 | dev_printk(KERN_DEBUG, &pdev->dev, | 227 | dev_printk(KERN_DEBUG, &pdev->dev, |
| 228 | "version " DRV_VERSION "\n"); | 228 | "version " DRV_VERSION "\n"); |
| 229 | 229 | ||
| 230 | return ata_pci_sff_init_one(pdev, ppi, &radisys_sht, NULL, 0); | 230 | return ata_pci_bmdma_init_one(pdev, ppi, &radisys_sht, NULL, 0); |
| 231 | } | 231 | } |
| 232 | 232 | ||
| 233 | static const struct pci_device_id radisys_pci_tbl[] = { | 233 | static const struct pci_device_id radisys_pci_tbl[] = { |
diff --git a/drivers/ata/pata_rdc.c b/drivers/ata/pata_rdc.c index 37092cfd7bc6..5fbe9b166c69 100644 --- a/drivers/ata/pata_rdc.c +++ b/drivers/ata/pata_rdc.c | |||
| @@ -344,7 +344,7 @@ static int __devinit rdc_init_one(struct pci_dev *pdev, | |||
| 344 | */ | 344 | */ |
| 345 | pci_read_config_dword(pdev, 0x54, &hpriv->saved_iocfg); | 345 | pci_read_config_dword(pdev, 0x54, &hpriv->saved_iocfg); |
| 346 | 346 | ||
| 347 | rc = ata_pci_sff_prepare_host(pdev, ppi, &host); | 347 | rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); |
| 348 | if (rc) | 348 | if (rc) |
| 349 | return rc; | 349 | return rc; |
| 350 | host->private_data = hpriv; | 350 | host->private_data = hpriv; |
| @@ -354,7 +354,7 @@ static int __devinit rdc_init_one(struct pci_dev *pdev, | |||
| 354 | host->flags |= ATA_HOST_PARALLEL_SCAN; | 354 | host->flags |= ATA_HOST_PARALLEL_SCAN; |
| 355 | 355 | ||
| 356 | pci_set_master(pdev); | 356 | pci_set_master(pdev); |
| 357 | return ata_pci_sff_activate_host(host, ata_sff_interrupt, &rdc_sht); | 357 | return ata_pci_sff_activate_host(host, ata_bmdma_interrupt, &rdc_sht); |
| 358 | } | 358 | } |
| 359 | 359 | ||
| 360 | static void rdc_remove_one(struct pci_dev *pdev) | 360 | static void rdc_remove_one(struct pci_dev *pdev) |
diff --git a/drivers/ata/pata_sc1200.c b/drivers/ata/pata_sc1200.c index 6b5b63a2fd8e..e2c18257adff 100644 --- a/drivers/ata/pata_sc1200.c +++ b/drivers/ata/pata_sc1200.c | |||
| @@ -237,7 +237,7 @@ static int sc1200_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 237 | }; | 237 | }; |
| 238 | const struct ata_port_info *ppi[] = { &info, NULL }; | 238 | const struct ata_port_info *ppi[] = { &info, NULL }; |
| 239 | 239 | ||
| 240 | return ata_pci_sff_init_one(dev, ppi, &sc1200_sht, NULL, 0); | 240 | return ata_pci_bmdma_init_one(dev, ppi, &sc1200_sht, NULL, 0); |
| 241 | } | 241 | } |
| 242 | 242 | ||
| 243 | static const struct pci_device_id sc1200[] = { | 243 | static const struct pci_device_id sc1200[] = { |
diff --git a/drivers/ata/pata_scc.c b/drivers/ata/pata_scc.c index 6f6193b707cb..d9db3f8d60ef 100644 --- a/drivers/ata/pata_scc.c +++ b/drivers/ata/pata_scc.c | |||
| @@ -875,7 +875,7 @@ static void scc_postreset(struct ata_link *link, unsigned int *classes) | |||
| 875 | * scc_irq_clear - Clear PCI IDE BMDMA interrupt. | 875 | * scc_irq_clear - Clear PCI IDE BMDMA interrupt. |
| 876 | * @ap: Port associated with this ATA transaction. | 876 | * @ap: Port associated with this ATA transaction. |
| 877 | * | 877 | * |
| 878 | * Note: Original code is ata_sff_irq_clear(). | 878 | * Note: Original code is ata_bmdma_irq_clear(). |
| 879 | */ | 879 | */ |
| 880 | 880 | ||
| 881 | static void scc_irq_clear (struct ata_port *ap) | 881 | static void scc_irq_clear (struct ata_port *ap) |
| @@ -1105,7 +1105,7 @@ static int scc_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 1105 | if (rc) | 1105 | if (rc) |
| 1106 | return rc; | 1106 | return rc; |
| 1107 | 1107 | ||
| 1108 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 1108 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 1109 | IRQF_SHARED, &scc_sht); | 1109 | IRQF_SHARED, &scc_sht); |
| 1110 | } | 1110 | } |
| 1111 | 1111 | ||
diff --git a/drivers/ata/pata_sch.c b/drivers/ata/pata_sch.c index 86b3d0133c7c..e97b32f03a6e 100644 --- a/drivers/ata/pata_sch.c +++ b/drivers/ata/pata_sch.c | |||
| @@ -179,7 +179,7 @@ static int __devinit sch_init_one(struct pci_dev *pdev, | |||
| 179 | dev_printk(KERN_DEBUG, &pdev->dev, | 179 | dev_printk(KERN_DEBUG, &pdev->dev, |
| 180 | "version " DRV_VERSION "\n"); | 180 | "version " DRV_VERSION "\n"); |
| 181 | 181 | ||
| 182 | return ata_pci_sff_init_one(pdev, ppi, &sch_sht, NULL, 0); | 182 | return ata_pci_bmdma_init_one(pdev, ppi, &sch_sht, NULL, 0); |
| 183 | } | 183 | } |
| 184 | 184 | ||
| 185 | static int __init sch_init(void) | 185 | static int __init sch_init(void) |
diff --git a/drivers/ata/pata_serverworks.c b/drivers/ata/pata_serverworks.c index 43ea389df2b3..86dd714e3e1d 100644 --- a/drivers/ata/pata_serverworks.c +++ b/drivers/ata/pata_serverworks.c | |||
| @@ -460,7 +460,7 @@ static int serverworks_init_one(struct pci_dev *pdev, const struct pci_device_id | |||
| 460 | if (pdev->device == PCI_DEVICE_ID_SERVERWORKS_CSB5IDE) | 460 | if (pdev->device == PCI_DEVICE_ID_SERVERWORKS_CSB5IDE) |
| 461 | ata_pci_bmdma_clear_simplex(pdev); | 461 | ata_pci_bmdma_clear_simplex(pdev); |
| 462 | 462 | ||
| 463 | return ata_pci_sff_init_one(pdev, ppi, &serverworks_sht, NULL, 0); | 463 | return ata_pci_bmdma_init_one(pdev, ppi, &serverworks_sht, NULL, 0); |
| 464 | } | 464 | } |
| 465 | 465 | ||
| 466 | #ifdef CONFIG_PM | 466 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_sil680.c b/drivers/ata/pata_sil680.c index 43faf106f647..d3190d7ec304 100644 --- a/drivers/ata/pata_sil680.c +++ b/drivers/ata/pata_sil680.c | |||
| @@ -374,11 +374,11 @@ static int __devinit sil680_init_one(struct pci_dev *pdev, | |||
| 374 | ata_sff_std_ports(&host->ports[1]->ioaddr); | 374 | ata_sff_std_ports(&host->ports[1]->ioaddr); |
| 375 | 375 | ||
| 376 | /* Register & activate */ | 376 | /* Register & activate */ |
| 377 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 377 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 378 | IRQF_SHARED, &sil680_sht); | 378 | IRQF_SHARED, &sil680_sht); |
| 379 | 379 | ||
| 380 | use_ioports: | 380 | use_ioports: |
| 381 | return ata_pci_sff_init_one(pdev, ppi, &sil680_sht, NULL, 0); | 381 | return ata_pci_bmdma_init_one(pdev, ppi, &sil680_sht, NULL, 0); |
| 382 | } | 382 | } |
| 383 | 383 | ||
| 384 | #ifdef CONFIG_PM | 384 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_sis.c b/drivers/ata/pata_sis.c index b6708032f321..60cea13cccce 100644 --- a/drivers/ata/pata_sis.c +++ b/drivers/ata/pata_sis.c | |||
| @@ -826,7 +826,7 @@ static int sis_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 826 | 826 | ||
| 827 | sis_fixup(pdev, chipset); | 827 | sis_fixup(pdev, chipset); |
| 828 | 828 | ||
| 829 | return ata_pci_sff_init_one(pdev, ppi, &sis_sht, chipset, 0); | 829 | return ata_pci_bmdma_init_one(pdev, ppi, &sis_sht, chipset, 0); |
| 830 | } | 830 | } |
| 831 | 831 | ||
| 832 | #ifdef CONFIG_PM | 832 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/pata_sl82c105.c b/drivers/ata/pata_sl82c105.c index 733b042a7469..98548f640c8e 100644 --- a/drivers/ata/pata_sl82c105.c +++ b/drivers/ata/pata_sl82c105.c | |||
| @@ -316,7 +316,7 @@ static int sl82c105_init_one(struct pci_dev *dev, const struct pci_device_id *id | |||
| 316 | val |= CTRL_P0EN | CTRL_P0F16 | CTRL_P1F16; | 316 | val |= CTRL_P0EN | CTRL_P0F16 | CTRL_P1F16; |
| 317 | pci_write_config_dword(dev, 0x40, val); | 317 | pci_write_config_dword(dev, 0x40, val); |
| 318 | 318 | ||
| 319 | return ata_pci_sff_init_one(dev, ppi, &sl82c105_sht, NULL, 0); | 319 | return ata_pci_bmdma_init_one(dev, ppi, &sl82c105_sht, NULL, 0); |
| 320 | } | 320 | } |
| 321 | 321 | ||
| 322 | static const struct pci_device_id sl82c105[] = { | 322 | static const struct pci_device_id sl82c105[] = { |
diff --git a/drivers/ata/pata_triflex.c b/drivers/ata/pata_triflex.c index 48f50600ed2a..0d1f89e571dd 100644 --- a/drivers/ata/pata_triflex.c +++ b/drivers/ata/pata_triflex.c | |||
| @@ -201,7 +201,7 @@ static int triflex_init_one(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 201 | if (!printed_version++) | 201 | if (!printed_version++) |
| 202 | dev_printk(KERN_DEBUG, &dev->dev, "version " DRV_VERSION "\n"); | 202 | dev_printk(KERN_DEBUG, &dev->dev, "version " DRV_VERSION "\n"); |
| 203 | 203 | ||
| 204 | return ata_pci_sff_init_one(dev, ppi, &triflex_sht, NULL, 0); | 204 | return ata_pci_bmdma_init_one(dev, ppi, &triflex_sht, NULL, 0); |
| 205 | } | 205 | } |
| 206 | 206 | ||
| 207 | static const struct pci_device_id triflex[] = { | 207 | static const struct pci_device_id triflex[] = { |
diff --git a/drivers/ata/pata_via.c b/drivers/ata/pata_via.c index 7e3e0a5598b7..5e659885de16 100644 --- a/drivers/ata/pata_via.c +++ b/drivers/ata/pata_via.c | |||
| @@ -627,7 +627,7 @@ static int via_init_one(struct pci_dev *pdev, const struct pci_device_id *id) | |||
| 627 | } | 627 | } |
| 628 | 628 | ||
| 629 | /* We have established the device type, now fire it up */ | 629 | /* We have established the device type, now fire it up */ |
| 630 | return ata_pci_sff_init_one(pdev, ppi, &via_sht, (void *)config, 0); | 630 | return ata_pci_bmdma_init_one(pdev, ppi, &via_sht, (void *)config, 0); |
| 631 | } | 631 | } |
| 632 | 632 | ||
| 633 | #ifdef CONFIG_PM | 633 | #ifdef CONFIG_PM |
diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c index f3471bc949d3..a476cd99b95d 100644 --- a/drivers/ata/sata_mv.c +++ b/drivers/ata/sata_mv.c | |||
| @@ -675,8 +675,6 @@ static struct ata_port_operations mv5_ops = { | |||
| 675 | .freeze = mv_eh_freeze, | 675 | .freeze = mv_eh_freeze, |
| 676 | .thaw = mv_eh_thaw, | 676 | .thaw = mv_eh_thaw, |
| 677 | .hardreset = mv_hardreset, | 677 | .hardreset = mv_hardreset, |
| 678 | .error_handler = ata_std_error_handler, /* avoid SFF EH */ | ||
| 679 | .post_internal_cmd = ATA_OP_NULL, | ||
| 680 | 678 | ||
| 681 | .scr_read = mv5_scr_read, | 679 | .scr_read = mv5_scr_read, |
| 682 | .scr_write = mv5_scr_write, | 680 | .scr_write = mv5_scr_write, |
| @@ -2813,7 +2811,7 @@ static void mv_port_intr(struct ata_port *ap, u32 port_cause) | |||
| 2813 | } else if (!edma_was_enabled) { | 2811 | } else if (!edma_was_enabled) { |
| 2814 | struct ata_queued_cmd *qc = mv_get_active_qc(ap); | 2812 | struct ata_queued_cmd *qc = mv_get_active_qc(ap); |
| 2815 | if (qc) | 2813 | if (qc) |
| 2816 | ata_sff_host_intr(ap, qc); | 2814 | ata_bmdma_port_intr(ap, qc); |
| 2817 | else | 2815 | else |
| 2818 | mv_unexpected_intr(ap, edma_was_enabled); | 2816 | mv_unexpected_intr(ap, edma_was_enabled); |
| 2819 | } | 2817 | } |
diff --git a/drivers/ata/sata_nv.c b/drivers/ata/sata_nv.c index baa8f0d2c86f..6fd114784116 100644 --- a/drivers/ata/sata_nv.c +++ b/drivers/ata/sata_nv.c | |||
| @@ -920,7 +920,7 @@ static int nv_host_intr(struct ata_port *ap, u8 irq_stat) | |||
| 920 | } | 920 | } |
| 921 | 921 | ||
| 922 | /* handle interrupt */ | 922 | /* handle interrupt */ |
| 923 | return ata_sff_host_intr(ap, qc); | 923 | return ata_bmdma_port_intr(ap, qc); |
| 924 | } | 924 | } |
| 925 | 925 | ||
| 926 | static irqreturn_t nv_adma_interrupt(int irq, void *dev_instance) | 926 | static irqreturn_t nv_adma_interrupt(int irq, void *dev_instance) |
| @@ -1100,7 +1100,7 @@ static void nv_adma_irq_clear(struct ata_port *ap) | |||
| 1100 | u32 notifier_clears[2]; | 1100 | u32 notifier_clears[2]; |
| 1101 | 1101 | ||
| 1102 | if (pp->flags & NV_ADMA_ATAPI_SETUP_COMPLETE) { | 1102 | if (pp->flags & NV_ADMA_ATAPI_SETUP_COMPLETE) { |
| 1103 | ata_sff_irq_clear(ap); | 1103 | ata_bmdma_irq_clear(ap); |
| 1104 | return; | 1104 | return; |
| 1105 | } | 1105 | } |
| 1106 | 1106 | ||
| @@ -1505,7 +1505,7 @@ static irqreturn_t nv_generic_interrupt(int irq, void *dev_instance) | |||
| 1505 | 1505 | ||
| 1506 | qc = ata_qc_from_tag(ap, ap->link.active_tag); | 1506 | qc = ata_qc_from_tag(ap, ap->link.active_tag); |
| 1507 | if (qc && (!(qc->tf.flags & ATA_TFLAG_POLLING))) { | 1507 | if (qc && (!(qc->tf.flags & ATA_TFLAG_POLLING))) { |
| 1508 | handled += ata_sff_host_intr(ap, qc); | 1508 | handled += ata_bmdma_port_intr(ap, qc); |
| 1509 | } else { | 1509 | } else { |
| 1510 | /* | 1510 | /* |
| 1511 | * No request pending? Clear interrupt status | 1511 | * No request pending? Clear interrupt status |
| @@ -2430,7 +2430,7 @@ static int nv_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 2430 | 2430 | ||
| 2431 | ppi[0] = &nv_port_info[type]; | 2431 | ppi[0] = &nv_port_info[type]; |
| 2432 | ipriv = ppi[0]->private_data; | 2432 | ipriv = ppi[0]->private_data; |
| 2433 | rc = ata_pci_sff_prepare_host(pdev, ppi, &host); | 2433 | rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); |
| 2434 | if (rc) | 2434 | if (rc) |
| 2435 | return rc; | 2435 | return rc; |
| 2436 | 2436 | ||
diff --git a/drivers/ata/sata_qstor.c b/drivers/ata/sata_qstor.c index d533b3d20ca1..daeebf19a6a9 100644 --- a/drivers/ata/sata_qstor.c +++ b/drivers/ata/sata_qstor.c | |||
| @@ -120,8 +120,6 @@ static void qs_host_stop(struct ata_host *host); | |||
| 120 | static void qs_qc_prep(struct ata_queued_cmd *qc); | 120 | static void qs_qc_prep(struct ata_queued_cmd *qc); |
| 121 | static unsigned int qs_qc_issue(struct ata_queued_cmd *qc); | 121 | static unsigned int qs_qc_issue(struct ata_queued_cmd *qc); |
| 122 | static int qs_check_atapi_dma(struct ata_queued_cmd *qc); | 122 | static int qs_check_atapi_dma(struct ata_queued_cmd *qc); |
| 123 | static void qs_bmdma_stop(struct ata_queued_cmd *qc); | ||
| 124 | static u8 qs_bmdma_status(struct ata_port *ap); | ||
| 125 | static void qs_freeze(struct ata_port *ap); | 123 | static void qs_freeze(struct ata_port *ap); |
| 126 | static void qs_thaw(struct ata_port *ap); | 124 | static void qs_thaw(struct ata_port *ap); |
| 127 | static int qs_prereset(struct ata_link *link, unsigned long deadline); | 125 | static int qs_prereset(struct ata_link *link, unsigned long deadline); |
| @@ -137,8 +135,6 @@ static struct ata_port_operations qs_ata_ops = { | |||
| 137 | .inherits = &ata_sff_port_ops, | 135 | .inherits = &ata_sff_port_ops, |
| 138 | 136 | ||
| 139 | .check_atapi_dma = qs_check_atapi_dma, | 137 | .check_atapi_dma = qs_check_atapi_dma, |
| 140 | .bmdma_stop = qs_bmdma_stop, | ||
| 141 | .bmdma_status = qs_bmdma_status, | ||
| 142 | .qc_prep = qs_qc_prep, | 138 | .qc_prep = qs_qc_prep, |
| 143 | .qc_issue = qs_qc_issue, | 139 | .qc_issue = qs_qc_issue, |
| 144 | 140 | ||
| @@ -190,16 +186,6 @@ static int qs_check_atapi_dma(struct ata_queued_cmd *qc) | |||
| 190 | return 1; /* ATAPI DMA not supported */ | 186 | return 1; /* ATAPI DMA not supported */ |
| 191 | } | 187 | } |
| 192 | 188 | ||
| 193 | static void qs_bmdma_stop(struct ata_queued_cmd *qc) | ||
| 194 | { | ||
| 195 | /* nothing */ | ||
| 196 | } | ||
| 197 | |||
| 198 | static u8 qs_bmdma_status(struct ata_port *ap) | ||
| 199 | { | ||
| 200 | return 0; | ||
| 201 | } | ||
| 202 | |||
| 203 | static inline void qs_enter_reg_mode(struct ata_port *ap) | 189 | static inline void qs_enter_reg_mode(struct ata_port *ap) |
| 204 | { | 190 | { |
| 205 | u8 __iomem *chan = qs_mmio_base(ap->host) + (ap->port_no * 0x4000); | 191 | u8 __iomem *chan = qs_mmio_base(ap->host) + (ap->port_no * 0x4000); |
| @@ -454,7 +440,7 @@ static inline unsigned int qs_intr_mmio(struct ata_host *host) | |||
| 454 | if (!pp || pp->state != qs_state_mmio) | 440 | if (!pp || pp->state != qs_state_mmio) |
| 455 | continue; | 441 | continue; |
| 456 | if (!(qc->tf.flags & ATA_TFLAG_POLLING)) | 442 | if (!(qc->tf.flags & ATA_TFLAG_POLLING)) |
| 457 | handled |= ata_sff_host_intr(ap, qc); | 443 | handled |= ata_sff_port_intr(ap, qc); |
| 458 | } | 444 | } |
| 459 | return handled; | 445 | return handled; |
| 460 | } | 446 | } |
diff --git a/drivers/ata/sata_sil.c b/drivers/ata/sata_sil.c index 2dda312b6b9a..3a4f84219719 100644 --- a/drivers/ata/sata_sil.c +++ b/drivers/ata/sata_sil.c | |||
| @@ -503,7 +503,7 @@ static void sil_host_intr(struct ata_port *ap, u32 bmdma2) | |||
| 503 | goto err_hsm; | 503 | goto err_hsm; |
| 504 | 504 | ||
| 505 | /* ack bmdma irq events */ | 505 | /* ack bmdma irq events */ |
| 506 | ata_sff_irq_clear(ap); | 506 | ata_bmdma_irq_clear(ap); |
| 507 | 507 | ||
| 508 | /* kick HSM in the ass */ | 508 | /* kick HSM in the ass */ |
| 509 | ata_sff_hsm_move(ap, qc, status, 0); | 509 | ata_sff_hsm_move(ap, qc, status, 0); |
| @@ -584,7 +584,7 @@ static void sil_thaw(struct ata_port *ap) | |||
| 584 | 584 | ||
| 585 | /* clear IRQ */ | 585 | /* clear IRQ */ |
| 586 | ap->ops->sff_check_status(ap); | 586 | ap->ops->sff_check_status(ap); |
| 587 | ata_sff_irq_clear(ap); | 587 | ata_bmdma_irq_clear(ap); |
| 588 | 588 | ||
| 589 | /* turn on SATA IRQ if supported */ | 589 | /* turn on SATA IRQ if supported */ |
| 590 | if (!(ap->flags & SIL_FLAG_NO_SATA_IRQ)) | 590 | if (!(ap->flags & SIL_FLAG_NO_SATA_IRQ)) |
diff --git a/drivers/ata/sata_sis.c b/drivers/ata/sata_sis.c index f8a91bfd66a8..2bfe3ae03976 100644 --- a/drivers/ata/sata_sis.c +++ b/drivers/ata/sata_sis.c | |||
| @@ -279,7 +279,7 @@ static int sis_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 279 | break; | 279 | break; |
| 280 | } | 280 | } |
| 281 | 281 | ||
| 282 | rc = ata_pci_sff_prepare_host(pdev, ppi, &host); | 282 | rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); |
| 283 | if (rc) | 283 | if (rc) |
| 284 | return rc; | 284 | return rc; |
| 285 | 285 | ||
| @@ -308,7 +308,7 @@ static int sis_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 308 | 308 | ||
| 309 | pci_set_master(pdev); | 309 | pci_set_master(pdev); |
| 310 | pci_intx(pdev, 1); | 310 | pci_intx(pdev, 1); |
| 311 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 311 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 312 | IRQF_SHARED, &sis_sht); | 312 | IRQF_SHARED, &sis_sht); |
| 313 | } | 313 | } |
| 314 | 314 | ||
diff --git a/drivers/ata/sata_svw.c b/drivers/ata/sata_svw.c index 101fd6a19829..7d9db4aaf07e 100644 --- a/drivers/ata/sata_svw.c +++ b/drivers/ata/sata_svw.c | |||
| @@ -502,7 +502,7 @@ static int k2_sata_init_one(struct pci_dev *pdev, const struct pci_device_id *en | |||
| 502 | writel(0x0, mmio_base + K2_SATA_SIM_OFFSET); | 502 | writel(0x0, mmio_base + K2_SATA_SIM_OFFSET); |
| 503 | 503 | ||
| 504 | pci_set_master(pdev); | 504 | pci_set_master(pdev); |
| 505 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 505 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 506 | IRQF_SHARED, &k2_sata_sht); | 506 | IRQF_SHARED, &k2_sata_sht); |
| 507 | } | 507 | } |
| 508 | 508 | ||
diff --git a/drivers/ata/sata_uli.c b/drivers/ata/sata_uli.c index d8dac17dc2c8..b8578c32d344 100644 --- a/drivers/ata/sata_uli.c +++ b/drivers/ata/sata_uli.c | |||
| @@ -242,7 +242,7 @@ static int uli_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 242 | 242 | ||
| 243 | pci_set_master(pdev); | 243 | pci_set_master(pdev); |
| 244 | pci_intx(pdev, 1); | 244 | pci_intx(pdev, 1); |
| 245 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 245 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 246 | IRQF_SHARED, &uli_sht); | 246 | IRQF_SHARED, &uli_sht); |
| 247 | } | 247 | } |
| 248 | 248 | ||
diff --git a/drivers/ata/sata_via.c b/drivers/ata/sata_via.c index 08f65492cc81..101d8c219caf 100644 --- a/drivers/ata/sata_via.c +++ b/drivers/ata/sata_via.c | |||
| @@ -308,7 +308,7 @@ static void svia_noop_freeze(struct ata_port *ap) | |||
| 308 | * certain way. Leave it alone and just clear pending IRQ. | 308 | * certain way. Leave it alone and just clear pending IRQ. |
| 309 | */ | 309 | */ |
| 310 | ap->ops->sff_check_status(ap); | 310 | ap->ops->sff_check_status(ap); |
| 311 | ata_sff_irq_clear(ap); | 311 | ata_bmdma_irq_clear(ap); |
| 312 | } | 312 | } |
| 313 | 313 | ||
| 314 | /** | 314 | /** |
| @@ -463,7 +463,7 @@ static int vt6420_prepare_host(struct pci_dev *pdev, struct ata_host **r_host) | |||
| 463 | struct ata_host *host; | 463 | struct ata_host *host; |
| 464 | int rc; | 464 | int rc; |
| 465 | 465 | ||
| 466 | rc = ata_pci_sff_prepare_host(pdev, ppi, &host); | 466 | rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); |
| 467 | if (rc) | 467 | if (rc) |
| 468 | return rc; | 468 | return rc; |
| 469 | *r_host = host; | 469 | *r_host = host; |
| @@ -520,7 +520,7 @@ static int vt8251_prepare_host(struct pci_dev *pdev, struct ata_host **r_host) | |||
| 520 | struct ata_host *host; | 520 | struct ata_host *host; |
| 521 | int i, rc; | 521 | int i, rc; |
| 522 | 522 | ||
| 523 | rc = ata_pci_sff_prepare_host(pdev, ppi, &host); | 523 | rc = ata_pci_bmdma_prepare_host(pdev, ppi, &host); |
| 524 | if (rc) | 524 | if (rc) |
| 525 | return rc; | 525 | return rc; |
| 526 | *r_host = host; | 526 | *r_host = host; |
| @@ -628,7 +628,7 @@ static int svia_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 628 | svia_configure(pdev); | 628 | svia_configure(pdev); |
| 629 | 629 | ||
| 630 | pci_set_master(pdev); | 630 | pci_set_master(pdev); |
| 631 | return ata_host_activate(host, pdev->irq, ata_sff_interrupt, | 631 | return ata_host_activate(host, pdev->irq, ata_bmdma_interrupt, |
| 632 | IRQF_SHARED, &svia_sht); | 632 | IRQF_SHARED, &svia_sht); |
| 633 | } | 633 | } |
| 634 | 634 | ||
diff --git a/drivers/ata/sata_vsc.c b/drivers/ata/sata_vsc.c index 2107952ebff1..b777176ff494 100644 --- a/drivers/ata/sata_vsc.c +++ b/drivers/ata/sata_vsc.c | |||
| @@ -245,7 +245,7 @@ static void vsc_port_intr(u8 port_status, struct ata_port *ap) | |||
| 245 | 245 | ||
| 246 | qc = ata_qc_from_tag(ap, ap->link.active_tag); | 246 | qc = ata_qc_from_tag(ap, ap->link.active_tag); |
| 247 | if (qc && likely(!(qc->tf.flags & ATA_TFLAG_POLLING))) | 247 | if (qc && likely(!(qc->tf.flags & ATA_TFLAG_POLLING))) |
| 248 | handled = ata_sff_host_intr(ap, qc); | 248 | handled = ata_bmdma_port_intr(ap, qc); |
| 249 | 249 | ||
| 250 | /* We received an interrupt during a polled command, | 250 | /* We received an interrupt during a polled command, |
| 251 | * or some other spurious condition. Interrupt reporting | 251 | * or some other spurious condition. Interrupt reporting |
diff --git a/include/linux/libata.h b/include/linux/libata.h index ee84e7e12039..3bad2701bfa6 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
| @@ -386,6 +386,7 @@ enum { | |||
| 386 | ATA_HORKAGE_1_5_GBPS = (1 << 13), /* force 1.5 Gbps */ | 386 | ATA_HORKAGE_1_5_GBPS = (1 << 13), /* force 1.5 Gbps */ |
| 387 | ATA_HORKAGE_NOSETXFER = (1 << 14), /* skip SETXFER, SATA only */ | 387 | ATA_HORKAGE_NOSETXFER = (1 << 14), /* skip SETXFER, SATA only */ |
| 388 | ATA_HORKAGE_BROKEN_FPDMA_AA = (1 << 15), /* skip AA */ | 388 | ATA_HORKAGE_BROKEN_FPDMA_AA = (1 << 15), /* skip AA */ |
| 389 | ATA_HORKAGE_DUMP_ID = (1 << 16), /* dump IDENTIFY data */ | ||
| 389 | 390 | ||
| 390 | /* DMA mask for user DMA control: User visible values; DO NOT | 391 | /* DMA mask for user DMA control: User visible values; DO NOT |
| 391 | renumber */ | 392 | renumber */ |
| @@ -513,7 +514,9 @@ struct ata_ioports { | |||
| 513 | void __iomem *command_addr; | 514 | void __iomem *command_addr; |
| 514 | void __iomem *altstatus_addr; | 515 | void __iomem *altstatus_addr; |
| 515 | void __iomem *ctl_addr; | 516 | void __iomem *ctl_addr; |
| 517 | #ifdef CONFIG_ATA_BMDMA | ||
| 516 | void __iomem *bmdma_addr; | 518 | void __iomem *bmdma_addr; |
| 519 | #endif /* CONFIG_ATA_BMDMA */ | ||
| 517 | void __iomem *scr_addr; | 520 | void __iomem *scr_addr; |
| 518 | }; | 521 | }; |
| 519 | #endif /* CONFIG_ATA_SFF */ | 522 | #endif /* CONFIG_ATA_SFF */ |
| @@ -721,8 +724,10 @@ struct ata_port { | |||
| 721 | u8 ctl; /* cache of ATA control register */ | 724 | u8 ctl; /* cache of ATA control register */ |
| 722 | u8 last_ctl; /* Cache last written value */ | 725 | u8 last_ctl; /* Cache last written value */ |
| 723 | struct delayed_work sff_pio_task; | 726 | struct delayed_work sff_pio_task; |
| 727 | #ifdef CONFIG_ATA_BMDMA | ||
| 724 | struct ata_bmdma_prd *bmdma_prd; /* BMDMA SG list */ | 728 | struct ata_bmdma_prd *bmdma_prd; /* BMDMA SG list */ |
| 725 | dma_addr_t bmdma_prd_dma; /* and its DMA mapping */ | 729 | dma_addr_t bmdma_prd_dma; /* and its DMA mapping */ |
| 730 | #endif /* CONFIG_ATA_BMDMA */ | ||
| 726 | #endif /* CONFIG_ATA_SFF */ | 731 | #endif /* CONFIG_ATA_SFF */ |
| 727 | 732 | ||
| 728 | unsigned int pio_mask; | 733 | unsigned int pio_mask; |
| @@ -856,10 +861,12 @@ struct ata_port_operations { | |||
| 856 | void (*sff_irq_clear)(struct ata_port *); | 861 | void (*sff_irq_clear)(struct ata_port *); |
| 857 | void (*sff_drain_fifo)(struct ata_queued_cmd *qc); | 862 | void (*sff_drain_fifo)(struct ata_queued_cmd *qc); |
| 858 | 863 | ||
| 864 | #ifdef CONFIG_ATA_BMDMA | ||
| 859 | void (*bmdma_setup)(struct ata_queued_cmd *qc); | 865 | void (*bmdma_setup)(struct ata_queued_cmd *qc); |
| 860 | void (*bmdma_start)(struct ata_queued_cmd *qc); | 866 | void (*bmdma_start)(struct ata_queued_cmd *qc); |
| 861 | void (*bmdma_stop)(struct ata_queued_cmd *qc); | 867 | void (*bmdma_stop)(struct ata_queued_cmd *qc); |
| 862 | u8 (*bmdma_status)(struct ata_port *ap); | 868 | u8 (*bmdma_status)(struct ata_port *ap); |
| 869 | #endif /* CONFIG_ATA_BMDMA */ | ||
| 863 | #endif /* CONFIG_ATA_SFF */ | 870 | #endif /* CONFIG_ATA_SFF */ |
| 864 | 871 | ||
| 865 | ssize_t (*em_show)(struct ata_port *ap, char *buf); | 872 | ssize_t (*em_show)(struct ata_port *ap, char *buf); |
| @@ -1555,7 +1562,6 @@ extern void sata_pmp_error_handler(struct ata_port *ap); | |||
| 1555 | #ifdef CONFIG_ATA_SFF | 1562 | #ifdef CONFIG_ATA_SFF |
| 1556 | 1563 | ||
| 1557 | extern const struct ata_port_operations ata_sff_port_ops; | 1564 | extern const struct ata_port_operations ata_sff_port_ops; |
| 1558 | extern const struct ata_port_operations ata_bmdma_port_ops; | ||
| 1559 | extern const struct ata_port_operations ata_bmdma32_port_ops; | 1565 | extern const struct ata_port_operations ata_bmdma32_port_ops; |
| 1560 | 1566 | ||
| 1561 | /* PIO only, sg_tablesize and dma_boundary limits can be removed */ | 1567 | /* PIO only, sg_tablesize and dma_boundary limits can be removed */ |
| @@ -1564,11 +1570,6 @@ extern const struct ata_port_operations ata_bmdma32_port_ops; | |||
| 1564 | .sg_tablesize = LIBATA_MAX_PRD, \ | 1570 | .sg_tablesize = LIBATA_MAX_PRD, \ |
| 1565 | .dma_boundary = ATA_DMA_BOUNDARY | 1571 | .dma_boundary = ATA_DMA_BOUNDARY |
| 1566 | 1572 | ||
| 1567 | #define ATA_BMDMA_SHT(drv_name) \ | ||
| 1568 | ATA_BASE_SHT(drv_name), \ | ||
| 1569 | .sg_tablesize = LIBATA_MAX_PRD, \ | ||
| 1570 | .dma_boundary = ATA_DMA_BOUNDARY | ||
| 1571 | |||
| 1572 | extern void ata_sff_dev_select(struct ata_port *ap, unsigned int device); | 1573 | extern void ata_sff_dev_select(struct ata_port *ap, unsigned int device); |
| 1573 | extern u8 ata_sff_check_status(struct ata_port *ap); | 1574 | extern u8 ata_sff_check_status(struct ata_port *ap); |
| 1574 | extern void ata_sff_pause(struct ata_port *ap); | 1575 | extern void ata_sff_pause(struct ata_port *ap); |
| @@ -1593,7 +1594,7 @@ extern int ata_sff_hsm_move(struct ata_port *ap, struct ata_queued_cmd *qc, | |||
| 1593 | extern void ata_sff_queue_pio_task(struct ata_port *ap, unsigned long delay); | 1594 | extern void ata_sff_queue_pio_task(struct ata_port *ap, unsigned long delay); |
| 1594 | extern unsigned int ata_sff_qc_issue(struct ata_queued_cmd *qc); | 1595 | extern unsigned int ata_sff_qc_issue(struct ata_queued_cmd *qc); |
| 1595 | extern bool ata_sff_qc_fill_rtf(struct ata_queued_cmd *qc); | 1596 | extern bool ata_sff_qc_fill_rtf(struct ata_queued_cmd *qc); |
| 1596 | extern unsigned int ata_sff_host_intr(struct ata_port *ap, | 1597 | extern unsigned int ata_sff_port_intr(struct ata_port *ap, |
| 1597 | struct ata_queued_cmd *qc); | 1598 | struct ata_queued_cmd *qc); |
| 1598 | extern irqreturn_t ata_sff_interrupt(int irq, void *dev_instance); | 1599 | extern irqreturn_t ata_sff_interrupt(int irq, void *dev_instance); |
| 1599 | extern void ata_sff_lost_interrupt(struct ata_port *ap); | 1600 | extern void ata_sff_lost_interrupt(struct ata_port *ap); |
| @@ -1625,11 +1626,24 @@ extern int ata_pci_sff_init_one(struct pci_dev *pdev, | |||
| 1625 | struct scsi_host_template *sht, void *host_priv, int hflags); | 1626 | struct scsi_host_template *sht, void *host_priv, int hflags); |
| 1626 | #endif /* CONFIG_PCI */ | 1627 | #endif /* CONFIG_PCI */ |
| 1627 | 1628 | ||
| 1629 | #ifdef CONFIG_ATA_BMDMA | ||
| 1630 | |||
| 1631 | extern const struct ata_port_operations ata_bmdma_port_ops; | ||
| 1632 | |||
| 1633 | #define ATA_BMDMA_SHT(drv_name) \ | ||
| 1634 | ATA_BASE_SHT(drv_name), \ | ||
| 1635 | .sg_tablesize = LIBATA_MAX_PRD, \ | ||
| 1636 | .dma_boundary = ATA_DMA_BOUNDARY | ||
| 1637 | |||
| 1628 | extern void ata_bmdma_qc_prep(struct ata_queued_cmd *qc); | 1638 | extern void ata_bmdma_qc_prep(struct ata_queued_cmd *qc); |
| 1629 | extern unsigned int ata_bmdma_qc_issue(struct ata_queued_cmd *qc); | 1639 | extern unsigned int ata_bmdma_qc_issue(struct ata_queued_cmd *qc); |
| 1630 | extern void ata_bmdma_dumb_qc_prep(struct ata_queued_cmd *qc); | 1640 | extern void ata_bmdma_dumb_qc_prep(struct ata_queued_cmd *qc); |
| 1641 | extern unsigned int ata_bmdma_port_intr(struct ata_port *ap, | ||
| 1642 | struct ata_queued_cmd *qc); | ||
| 1643 | extern irqreturn_t ata_bmdma_interrupt(int irq, void *dev_instance); | ||
| 1631 | extern void ata_bmdma_error_handler(struct ata_port *ap); | 1644 | extern void ata_bmdma_error_handler(struct ata_port *ap); |
| 1632 | extern void ata_bmdma_post_internal_cmd(struct ata_queued_cmd *qc); | 1645 | extern void ata_bmdma_post_internal_cmd(struct ata_queued_cmd *qc); |
| 1646 | extern void ata_bmdma_irq_clear(struct ata_port *ap); | ||
| 1633 | extern void ata_bmdma_setup(struct ata_queued_cmd *qc); | 1647 | extern void ata_bmdma_setup(struct ata_queued_cmd *qc); |
| 1634 | extern void ata_bmdma_start(struct ata_queued_cmd *qc); | 1648 | extern void ata_bmdma_start(struct ata_queued_cmd *qc); |
| 1635 | extern void ata_bmdma_stop(struct ata_queued_cmd *qc); | 1649 | extern void ata_bmdma_stop(struct ata_queued_cmd *qc); |
| @@ -1640,7 +1654,15 @@ extern int ata_bmdma_port_start32(struct ata_port *ap); | |||
| 1640 | #ifdef CONFIG_PCI | 1654 | #ifdef CONFIG_PCI |
| 1641 | extern int ata_pci_bmdma_clear_simplex(struct pci_dev *pdev); | 1655 | extern int ata_pci_bmdma_clear_simplex(struct pci_dev *pdev); |
| 1642 | extern void ata_pci_bmdma_init(struct ata_host *host); | 1656 | extern void ata_pci_bmdma_init(struct ata_host *host); |
| 1657 | extern int ata_pci_bmdma_prepare_host(struct pci_dev *pdev, | ||
| 1658 | const struct ata_port_info * const * ppi, | ||
| 1659 | struct ata_host **r_host); | ||
| 1660 | extern int ata_pci_bmdma_init_one(struct pci_dev *pdev, | ||
| 1661 | const struct ata_port_info * const * ppi, | ||
| 1662 | struct scsi_host_template *sht, | ||
| 1663 | void *host_priv, int hflags); | ||
| 1643 | #endif /* CONFIG_PCI */ | 1664 | #endif /* CONFIG_PCI */ |
| 1665 | #endif /* CONFIG_ATA_BMDMA */ | ||
| 1644 | 1666 | ||
| 1645 | /** | 1667 | /** |
| 1646 | * ata_sff_busy_wait - Wait for a port status register | 1668 | * ata_sff_busy_wait - Wait for a port status register |
