diff options
Diffstat (limited to 'drivers/ata/pata_it821x.c')
-rw-r--r-- | drivers/ata/pata_it821x.c | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/drivers/ata/pata_it821x.c b/drivers/ata/pata_it821x.c index 5d8b91e70ecd..988ef736b936 100644 --- a/drivers/ata/pata_it821x.c +++ b/drivers/ata/pata_it821x.c | |||
@@ -391,7 +391,7 @@ static void it821x_passthru_dev_select(struct ata_port *ap, | |||
391 | { | 391 | { |
392 | struct it821x_dev *itdev = ap->private_data; | 392 | struct it821x_dev *itdev = ap->private_data; |
393 | if (itdev && device != itdev->last_device) { | 393 | if (itdev && device != itdev->last_device) { |
394 | struct ata_device *adev = &ap->device[device]; | 394 | struct ata_device *adev = &ap->link.device[device]; |
395 | it821x_program(ap, adev, itdev->pio[adev->devno]); | 395 | it821x_program(ap, adev, itdev->pio[adev->devno]); |
396 | itdev->last_device = device; | 396 | itdev->last_device = device; |
397 | } | 397 | } |
@@ -450,7 +450,7 @@ static unsigned int it821x_passthru_qc_issue_prot(struct ata_queued_cmd *qc) | |||
450 | 450 | ||
451 | /** | 451 | /** |
452 | * it821x_smart_set_mode - mode setting | 452 | * it821x_smart_set_mode - mode setting |
453 | * @ap: interface to set up | 453 | * @link: interface to set up |
454 | * @unused: device that failed (error only) | 454 | * @unused: device that failed (error only) |
455 | * | 455 | * |
456 | * Use a non standard set_mode function. We don't want to be tuned. | 456 | * Use a non standard set_mode function. We don't want to be tuned. |
@@ -459,12 +459,11 @@ static unsigned int it821x_passthru_qc_issue_prot(struct ata_queued_cmd *qc) | |||
459 | * and respect them. | 459 | * and respect them. |
460 | */ | 460 | */ |
461 | 461 | ||
462 | static int it821x_smart_set_mode(struct ata_port *ap, struct ata_device **unused) | 462 | static int it821x_smart_set_mode(struct ata_link *link, struct ata_device **unused) |
463 | { | 463 | { |
464 | int i; | 464 | struct ata_device *dev; |
465 | 465 | ||
466 | for (i = 0; i < ATA_MAX_DEVICES; i++) { | 466 | ata_link_for_each_dev(dev, link) { |
467 | struct ata_device *dev = &ap->device[i]; | ||
468 | if (ata_dev_enabled(dev)) { | 467 | if (ata_dev_enabled(dev)) { |
469 | /* We don't really care */ | 468 | /* We don't really care */ |
470 | dev->pio_mode = XFER_PIO_0; | 469 | dev->pio_mode = XFER_PIO_0; |
@@ -564,7 +563,7 @@ static int it821x_port_start(struct ata_port *ap) | |||
564 | struct it821x_dev *itdev; | 563 | struct it821x_dev *itdev; |
565 | u8 conf; | 564 | u8 conf; |
566 | 565 | ||
567 | int ret = ata_port_start(ap); | 566 | int ret = ata_sff_port_start(ap); |
568 | if (ret < 0) | 567 | if (ret < 0) |
569 | return ret; | 568 | return ret; |
570 | 569 | ||
@@ -621,7 +620,6 @@ static struct scsi_host_template it821x_sht = { | |||
621 | 620 | ||
622 | static struct ata_port_operations it821x_smart_port_ops = { | 621 | static struct ata_port_operations it821x_smart_port_ops = { |
623 | .set_mode = it821x_smart_set_mode, | 622 | .set_mode = it821x_smart_set_mode, |
624 | .port_disable = ata_port_disable, | ||
625 | .tf_load = ata_tf_load, | 623 | .tf_load = ata_tf_load, |
626 | .tf_read = ata_tf_read, | 624 | .tf_read = ata_tf_read, |
627 | .mode_filter = ata_pci_default_filter, | 625 | .mode_filter = ata_pci_default_filter, |
@@ -651,13 +649,11 @@ static struct ata_port_operations it821x_smart_port_ops = { | |||
651 | .irq_handler = ata_interrupt, | 649 | .irq_handler = ata_interrupt, |
652 | .irq_clear = ata_bmdma_irq_clear, | 650 | .irq_clear = ata_bmdma_irq_clear, |
653 | .irq_on = ata_irq_on, | 651 | .irq_on = ata_irq_on, |
654 | .irq_ack = ata_irq_ack, | ||
655 | 652 | ||
656 | .port_start = it821x_port_start, | 653 | .port_start = it821x_port_start, |
657 | }; | 654 | }; |
658 | 655 | ||
659 | static struct ata_port_operations it821x_passthru_port_ops = { | 656 | static struct ata_port_operations it821x_passthru_port_ops = { |
660 | .port_disable = ata_port_disable, | ||
661 | .set_piomode = it821x_passthru_set_piomode, | 657 | .set_piomode = it821x_passthru_set_piomode, |
662 | .set_dmamode = it821x_passthru_set_dmamode, | 658 | .set_dmamode = it821x_passthru_set_dmamode, |
663 | .mode_filter = ata_pci_default_filter, | 659 | .mode_filter = ata_pci_default_filter, |
@@ -688,7 +684,6 @@ static struct ata_port_operations it821x_passthru_port_ops = { | |||
688 | .irq_clear = ata_bmdma_irq_clear, | 684 | .irq_clear = ata_bmdma_irq_clear, |
689 | .irq_handler = ata_interrupt, | 685 | .irq_handler = ata_interrupt, |
690 | .irq_on = ata_irq_on, | 686 | .irq_on = ata_irq_on, |
691 | .irq_ack = ata_irq_ack, | ||
692 | 687 | ||
693 | .port_start = it821x_port_start, | 688 | .port_start = it821x_port_start, |
694 | }; | 689 | }; |