ATA / ACPI: remove power dependent device handling
Previously, we wanted SCSI devices corrsponding to ATA devices to
be runtime resumed when the power resource for those ATA device was
turned on by some other device, so we added the SCSI device to the
dependent device list of the ATA device's ACPI node. However, this
code has no effect after commit 41863fc
(ACPI / power: Drop automaitc
resume of power resource dependent devices) and the mechanism it was
supposed to implement is regarded as a bad idea now, so drop it.
[rjw: Changelog]
Signed-off-by: Aaron Lu <aaron.lu@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
parent
41863fcee3
commit
b08fc109ce
|
@ -1035,17 +1035,3 @@ void ata_acpi_on_disable(struct ata_device *dev)
|
||||||
{
|
{
|
||||||
ata_acpi_clear_gtf(dev);
|
ata_acpi_clear_gtf(dev);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ata_scsi_acpi_bind(struct ata_device *dev)
|
|
||||||
{
|
|
||||||
acpi_handle handle = ata_dev_acpi_handle(dev);
|
|
||||||
if (handle)
|
|
||||||
acpi_dev_pm_add_dependent(handle, &dev->sdev->sdev_gendev);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ata_scsi_acpi_unbind(struct ata_device *dev)
|
|
||||||
{
|
|
||||||
acpi_handle handle = ata_dev_acpi_handle(dev);
|
|
||||||
if (handle)
|
|
||||||
acpi_dev_pm_remove_dependent(handle, &dev->sdev->sdev_gendev);
|
|
||||||
}
|
|
||||||
|
|
|
@ -3679,7 +3679,6 @@ void ata_scsi_scan_host(struct ata_port *ap, int sync)
|
||||||
if (!IS_ERR(sdev)) {
|
if (!IS_ERR(sdev)) {
|
||||||
dev->sdev = sdev;
|
dev->sdev = sdev;
|
||||||
scsi_device_put(sdev);
|
scsi_device_put(sdev);
|
||||||
ata_scsi_acpi_bind(dev);
|
|
||||||
} else {
|
} else {
|
||||||
dev->sdev = NULL;
|
dev->sdev = NULL;
|
||||||
}
|
}
|
||||||
|
@ -3767,8 +3766,6 @@ static void ata_scsi_remove_dev(struct ata_device *dev)
|
||||||
struct scsi_device *sdev;
|
struct scsi_device *sdev;
|
||||||
unsigned long flags;
|
unsigned long flags;
|
||||||
|
|
||||||
ata_scsi_acpi_unbind(dev);
|
|
||||||
|
|
||||||
/* Alas, we need to grab scan_mutex to ensure SCSI device
|
/* Alas, we need to grab scan_mutex to ensure SCSI device
|
||||||
* state doesn't change underneath us and thus
|
* state doesn't change underneath us and thus
|
||||||
* scsi_device_get() always succeeds. The mutex locking can
|
* scsi_device_get() always succeeds. The mutex locking can
|
||||||
|
|
|
@ -121,8 +121,6 @@ extern void ata_acpi_set_state(struct ata_port *ap, pm_message_t state);
|
||||||
extern void ata_acpi_bind_port(struct ata_port *ap);
|
extern void ata_acpi_bind_port(struct ata_port *ap);
|
||||||
extern void ata_acpi_bind_dev(struct ata_device *dev);
|
extern void ata_acpi_bind_dev(struct ata_device *dev);
|
||||||
extern acpi_handle ata_dev_acpi_handle(struct ata_device *dev);
|
extern acpi_handle ata_dev_acpi_handle(struct ata_device *dev);
|
||||||
extern void ata_scsi_acpi_bind(struct ata_device *dev);
|
|
||||||
extern void ata_scsi_acpi_unbind(struct ata_device *dev);
|
|
||||||
#else
|
#else
|
||||||
static inline void ata_acpi_dissociate(struct ata_host *host) { }
|
static inline void ata_acpi_dissociate(struct ata_host *host) { }
|
||||||
static inline int ata_acpi_on_suspend(struct ata_port *ap) { return 0; }
|
static inline int ata_acpi_on_suspend(struct ata_port *ap) { return 0; }
|
||||||
|
@ -133,8 +131,6 @@ static inline void ata_acpi_set_state(struct ata_port *ap,
|
||||||
pm_message_t state) { }
|
pm_message_t state) { }
|
||||||
static inline void ata_acpi_bind_port(struct ata_port *ap) {}
|
static inline void ata_acpi_bind_port(struct ata_port *ap) {}
|
||||||
static inline void ata_acpi_bind_dev(struct ata_device *dev) {}
|
static inline void ata_acpi_bind_dev(struct ata_device *dev) {}
|
||||||
static inline void ata_scsi_acpi_bind(struct ata_device *dev) {}
|
|
||||||
static inline void ata_scsi_acpi_unbind(struct ata_device *dev) {}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* libata-scsi.c */
|
/* libata-scsi.c */
|
||||||
|
|
Loading…
Reference in New Issue