diff options
author | Tejun Heo <htejun@gmail.com> | 2007-08-06 05:36:23 -0400 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2007-10-12 14:55:31 -0400 |
commit | 0260731f0187840e272bfa10d3ba0f3e417976f5 (patch) | |
tree | d39219275e89ce782f3151b5ac47726957a81e24 /drivers/ata/pata_pdc2027x.c | |
parent | cc0680a580b5be81a1ca321b58f8e9b80b5c1052 (diff) |
libata-link: linkify config/EH related functions
Make the following functions deal with ata_link instead of ata_port.
* ata_set_mode()
* ata_eh_autopsy() and related functions
* ata_eh_report() and related functions
* suspend/resume related functions
* ata_eh_recover() and related functions
Signed-off-by: Tejun Heo <htejun@gmail.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/ata/pata_pdc2027x.c')
-rw-r--r-- | drivers/ata/pata_pdc2027x.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/ata/pata_pdc2027x.c b/drivers/ata/pata_pdc2027x.c index ba39efbe5405..db069d7515bc 100644 --- a/drivers/ata/pata_pdc2027x.c +++ b/drivers/ata/pata_pdc2027x.c | |||
@@ -69,7 +69,7 @@ static void pdc2027x_set_dmamode(struct ata_port *ap, struct ata_device *adev); | |||
69 | static int pdc2027x_check_atapi_dma(struct ata_queued_cmd *qc); | 69 | static int pdc2027x_check_atapi_dma(struct ata_queued_cmd *qc); |
70 | static unsigned long pdc2027x_mode_filter(struct ata_device *adev, unsigned long mask); | 70 | static unsigned long pdc2027x_mode_filter(struct ata_device *adev, unsigned long mask); |
71 | static int pdc2027x_cable_detect(struct ata_port *ap); | 71 | static int pdc2027x_cable_detect(struct ata_port *ap); |
72 | static int pdc2027x_set_mode(struct ata_port *ap, struct ata_device **r_failed); | 72 | static int pdc2027x_set_mode(struct ata_link *link, struct ata_device **r_failed); |
73 | 73 | ||
74 | /* | 74 | /* |
75 | * ATA Timing Tables based on 133MHz controller clock. | 75 | * ATA Timing Tables based on 133MHz controller clock. |
@@ -470,23 +470,24 @@ static void pdc2027x_set_dmamode(struct ata_port *ap, struct ata_device *adev) | |||
470 | 470 | ||
471 | /** | 471 | /** |
472 | * pdc2027x_set_mode - Set the timing registers back to correct values. | 472 | * pdc2027x_set_mode - Set the timing registers back to correct values. |
473 | * @ap: Port to configure | 473 | * @link: link to configure |
474 | * @r_failed: Returned device for failure | 474 | * @r_failed: Returned device for failure |
475 | * | 475 | * |
476 | * The pdc2027x hardware will look at "SET FEATURES" and change the timing registers | 476 | * The pdc2027x hardware will look at "SET FEATURES" and change the timing registers |
477 | * automatically. The values set by the hardware might be incorrect, under 133Mhz PLL. | 477 | * automatically. The values set by the hardware might be incorrect, under 133Mhz PLL. |
478 | * This function overwrites the possibly incorrect values set by the hardware to be correct. | 478 | * This function overwrites the possibly incorrect values set by the hardware to be correct. |
479 | */ | 479 | */ |
480 | static int pdc2027x_set_mode(struct ata_port *ap, struct ata_device **r_failed) | 480 | static int pdc2027x_set_mode(struct ata_link *link, struct ata_device **r_failed) |
481 | { | 481 | { |
482 | struct ata_port *ap = link->ap; | ||
482 | struct ata_device *dev; | 483 | struct ata_device *dev; |
483 | int rc; | 484 | int rc; |
484 | 485 | ||
485 | rc = ata_do_set_mode(ap, r_failed); | 486 | rc = ata_do_set_mode(link, r_failed); |
486 | if (rc < 0) | 487 | if (rc < 0) |
487 | return rc; | 488 | return rc; |
488 | 489 | ||
489 | ata_link_for_each_dev(dev, &ap->link) { | 490 | ata_link_for_each_dev(dev, link) { |
490 | if (ata_dev_enabled(dev)) { | 491 | if (ata_dev_enabled(dev)) { |
491 | 492 | ||
492 | pdc2027x_set_piomode(ap, dev); | 493 | pdc2027x_set_piomode(ap, dev); |