From 48515f6c006c2a9d7b624ee8ad068018c2d3fe0e Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Mon, 7 Apr 2008 22:47:21 +0900 Subject: libata: separate PMP support code from core code Most of PMP support code is already in libata-pmp.c. All that are in libata-core.c are sata_pmp_port_ops and EXPORTs. Move them to libata-pmp.c. Also, collect PMP related prototypes and declarations in header files and move them right above of SFF stuff. This change is to make PMP support optional. Signed-off-by: Tejun Heo --- drivers/ata/libata-pmp.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'drivers/ata/libata-pmp.c') diff --git a/drivers/ata/libata-pmp.c b/drivers/ata/libata-pmp.c index 9c998611b64..bb10c063079 100644 --- a/drivers/ata/libata-pmp.c +++ b/drivers/ata/libata-pmp.c @@ -11,6 +11,14 @@ #include #include "libata.h" +const struct ata_port_operations sata_pmp_port_ops = { + .inherits = &sata_port_ops, + .pmp_prereset = ata_std_prereset, + .pmp_hardreset = sata_std_hardreset, + .pmp_postreset = ata_std_postreset, + .error_handler = sata_pmp_error_handler, +}; + /** * sata_pmp_read - read PMP register * @link: link to read PMP register for @@ -1012,3 +1020,7 @@ void sata_pmp_error_handler(struct ata_port *ap) sata_pmp_eh_recover(ap); ata_eh_finish(ap); } + +EXPORT_SYMBOL_GPL(sata_pmp_port_ops); +EXPORT_SYMBOL_GPL(sata_pmp_qc_defer_cmd_switch); +EXPORT_SYMBOL_GPL(sata_pmp_error_handler); -- cgit v1.2.3