Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 56255
b: refs/heads/master
c: 9666f40
h: refs/heads/master
i:
  56253: 845ac41
  56251: 4e12a53
  56247: af0c163
  56239: c44a30f
  56223: 8e48361
  56191: 94a04c7
v: v3
  • Loading branch information
Tejun Heo authored and Jeff Garzik committed May 11, 2007
1 parent ff9bec7 commit 9d99402
Show file tree
Hide file tree
Showing 82 changed files with 3,130 additions and 1,344 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9ce3075c20d458040138690edfdf6446664ec3ee
refs/heads/master: 9666f4009c22f6520ac3fb8a19c9e32ab973e828
4 changes: 0 additions & 4 deletions trunk/drivers/ata/ahci.c
Original file line number Diff line number Diff line change
Expand Up @@ -250,10 +250,6 @@ static struct scsi_host_template ahci_sht = {
.slave_configure = ata_scsi_slave_config,
.slave_destroy = ata_scsi_slave_destroy,
.bios_param = ata_std_bios_param,
#ifdef CONFIG_PM
.suspend = ata_scsi_device_suspend,
.resume = ata_scsi_device_resume,
#endif
};

static const struct ata_port_operations ahci_ops = {
Expand Down
6 changes: 1 addition & 5 deletions trunk/drivers/ata/ata_generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ static int generic_set_mode(struct ata_port *ap, struct ata_device **unused)

for (i = 0; i < ATA_MAX_DEVICES; i++) {
struct ata_device *dev = &ap->device[i];
if (ata_dev_ready(dev)) {
if (ata_dev_enabled(dev)) {
/* We don't really care */
dev->pio_mode = XFER_PIO_0;
dev->dma_mode = XFER_MW_DMA_0;
Expand Down Expand Up @@ -90,10 +90,6 @@ static struct scsi_host_template generic_sht = {
.slave_configure = ata_scsi_slave_config,
.slave_destroy = ata_scsi_slave_destroy,
.bios_param = ata_std_bios_param,
#ifdef CONFIG_PM
.resume = ata_scsi_device_resume,
.suspend = ata_scsi_device_suspend,
#endif
};

static struct ata_port_operations generic_port_ops = {
Expand Down
4 changes: 0 additions & 4 deletions trunk/drivers/ata/ata_piix.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,10 +275,6 @@ static struct scsi_host_template piix_sht = {
.slave_configure = ata_scsi_slave_config,
.slave_destroy = ata_scsi_slave_destroy,
.bios_param = ata_std_bios_param,
#ifdef CONFIG_PM
.resume = ata_scsi_device_resume,
.suspend = ata_scsi_device_suspend,
#endif
};

static const struct ata_port_operations piix_pata_ops = {
Expand Down
39 changes: 4 additions & 35 deletions trunk/drivers/ata/libata-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -2860,7 +2860,7 @@ int ata_do_set_mode(struct ata_port *ap, struct ata_device **r_failed_dev)
dev = &ap->device[i];

/* don't update suspended devices' xfer mode */
if (!ata_dev_ready(dev))
if (!ata_dev_enabled(dev))
continue;

rc = ata_dev_set_mode(dev);
Expand Down Expand Up @@ -5845,37 +5845,11 @@ static int ata_host_request_pm(struct ata_host *host, pm_message_t mesg,
*/
int ata_host_suspend(struct ata_host *host, pm_message_t mesg)
{
int i, j, rc;
int rc;

rc = ata_host_request_pm(host, mesg, 0, ATA_EHI_QUIET, 1);
if (rc)
goto fail;

/* EH is quiescent now. Fail if we have any ready device.
* This happens if hotplug occurs between completion of device
* suspension and here.
*/
for (i = 0; i < host->n_ports; i++) {
struct ata_port *ap = host->ports[i];

for (j = 0; j < ATA_MAX_DEVICES; j++) {
struct ata_device *dev = &ap->device[j];

if (ata_dev_ready(dev)) {
ata_port_printk(ap, KERN_WARNING,
"suspend failed, device %d "
"still active\n", dev->devno);
rc = -EBUSY;
goto fail;
}
}
}

host->dev->power.power_state = mesg;
return 0;

fail:
ata_host_resume(host);
if (rc == 0)
host->dev->power.power_state = mesg;
return rc;
}

Expand Down Expand Up @@ -6889,11 +6863,6 @@ EXPORT_SYMBOL_GPL(ata_pci_default_filter);
EXPORT_SYMBOL_GPL(ata_pci_clear_simplex);
#endif /* CONFIG_PCI */

#ifdef CONFIG_PM
EXPORT_SYMBOL_GPL(ata_scsi_device_suspend);
EXPORT_SYMBOL_GPL(ata_scsi_device_resume);
#endif /* CONFIG_PM */

EXPORT_SYMBOL_GPL(ata_eng_timeout);
EXPORT_SYMBOL_GPL(ata_port_schedule_eh);
EXPORT_SYMBOL_GPL(ata_port_abort);
Expand Down
Loading

0 comments on commit 9d99402

Please sign in to comment.