diff options
Diffstat (limited to 'drivers/ata/libata.h')
-rw-r--r-- | drivers/ata/libata.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/ata/libata.h b/drivers/ata/libata.h index 9d0fd0b71852..7f48b602b01b 100644 --- a/drivers/ata/libata.h +++ b/drivers/ata/libata.h @@ -107,6 +107,8 @@ extern const char *sata_spd_string(unsigned int spd); extern int ata_port_probe(struct ata_port *ap); extern void __ata_port_probe(struct ata_port *ap); +#define to_ata_port(d) container_of(d, struct ata_port, tdev) + /* libata-acpi.c */ #ifdef CONFIG_ATA_ACPI extern unsigned int ata_acpi_gtf_filter; @@ -119,6 +121,8 @@ extern void ata_acpi_on_resume(struct ata_port *ap); extern int ata_acpi_on_devcfg(struct ata_device *dev); extern void ata_acpi_on_disable(struct ata_device *dev); extern void ata_acpi_set_state(struct ata_port *ap, pm_message_t state); +extern int ata_acpi_register(void); +extern void ata_acpi_unregister(void); #else static inline void ata_acpi_associate_sata_port(struct ata_port *ap) { } static inline void ata_acpi_associate(struct ata_host *host) { } @@ -129,6 +133,8 @@ static inline int ata_acpi_on_devcfg(struct ata_device *dev) { return 0; } static inline void ata_acpi_on_disable(struct ata_device *dev) { } static inline void ata_acpi_set_state(struct ata_port *ap, pm_message_t state) { } +static inline int ata_acpi_register(void) { return 0; } +static void ata_acpi_unregister(void) { } #endif /* libata-scsi.c */ |