blob: b674b01ce9bca519aa2affea750ec74cd1a617f6 [file] [log] [blame]
Anton Vorontsov1c2a49f2010-03-04 20:06:06 +03001/*
2 * AHCI SATA platform driver
3 *
4 * Copyright 2004-2005 Red Hat, Inc.
5 * Jeff Garzik <jgarzik@pobox.com>
6 * Copyright 2010 MontaVista Software, LLC.
7 * Anton Vorontsov <avorontsov@ru.mvista.com>
8 *
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2, or (at your option)
12 * any later version.
13 */
14
15#ifndef _AHCI_PLATFORM_H
16#define _AHCI_PLATFORM_H
17
Jassi Brar08354802010-06-25 18:21:19 +090018#include <linux/compiler.h>
19
Anton Vorontsov1c2a49f2010-03-04 20:06:06 +030020struct device;
21struct ata_port_info;
Hans de Goede156c5882014-02-22 16:53:31 +010022struct ahci_host_priv;
Anton Vorontsov1c2a49f2010-03-04 20:06:06 +030023
24struct ahci_platform_data {
Jassi Brar08354802010-06-25 18:21:19 +090025 int (*init)(struct device *dev, void __iomem *addr);
Anton Vorontsov1c2a49f2010-03-04 20:06:06 +030026 void (*exit)(struct device *dev);
Brian Norris17ab5942011-11-18 11:10:10 -080027 int (*suspend)(struct device *dev);
28 int (*resume)(struct device *dev);
Anton Vorontsov1c2a49f2010-03-04 20:06:06 +030029 const struct ata_port_info *ata_port_info;
30 unsigned int force_port_map;
31 unsigned int mask_port_map;
32};
33
Hans de Goede156c5882014-02-22 16:53:31 +010034int ahci_platform_enable_clks(struct ahci_host_priv *hpriv);
35void ahci_platform_disable_clks(struct ahci_host_priv *hpriv);
Hans de Goede96a01ba2014-02-22 16:53:33 +010036int ahci_platform_enable_resources(struct ahci_host_priv *hpriv);
37void ahci_platform_disable_resources(struct ahci_host_priv *hpriv);
Hans de Goede156c5882014-02-22 16:53:31 +010038
Anton Vorontsov1c2a49f2010-03-04 20:06:06 +030039#endif /* _AHCI_PLATFORM_H */