]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/ata/pata_platform.c
ata: Switch all my stuff to a common address
[linux-2.6-omap-h63xx.git] / drivers / ata / pata_platform.c
index a8429f5c3006d2b3879cdd113d9cb78f36d6d971..77e4e3b17f5479b7ee4a2306513f4e8aa5d3a18f 100644 (file)
@@ -5,7 +5,7 @@
  *
  * Based on pata_pcmcia:
  *
- *   Copyright 2005-2006 Red Hat Inc <alan@redhat.com>, all rights reserved.
+ *   Copyright 2005-2006 Red Hat Inc, all rights reserved.
  *
  * This file is subject to the terms and conditions of the GNU General Public
  * License.  See the file "COPYING" in the main directory of this archive
@@ -46,50 +46,16 @@ static int pata_platform_set_mode(struct ata_link *link, struct ata_device **unu
        return 0;
 }
 
-static int ata_dummy_ret0(struct ata_port *ap) { return 0; }
-
 static struct scsi_host_template pata_platform_sht = {
-       .module                 = THIS_MODULE,
-       .name                   = DRV_NAME,
-       .ioctl                  = ata_scsi_ioctl,
-       .queuecommand           = ata_scsi_queuecmd,
-       .can_queue              = ATA_DEF_QUEUE,
-       .this_id                = ATA_SHT_THIS_ID,
-       .sg_tablesize           = LIBATA_MAX_PRD,
-       .cmd_per_lun            = ATA_SHT_CMD_PER_LUN,
-       .emulated               = ATA_SHT_EMULATED,
-       .use_clustering         = ATA_SHT_USE_CLUSTERING,
-       .proc_name              = DRV_NAME,
-       .dma_boundary           = ATA_DMA_BOUNDARY,
-       .slave_configure        = ata_scsi_slave_config,
-       .slave_destroy          = ata_scsi_slave_destroy,
-       .bios_param             = ata_std_bios_param,
+       ATA_PIO_SHT(DRV_NAME),
 };
 
 static struct ata_port_operations pata_platform_port_ops = {
-       .set_mode               = pata_platform_set_mode,
-
-       .tf_load                = ata_tf_load,
-       .tf_read                = ata_tf_read,
-       .check_status           = ata_check_status,
-       .exec_command           = ata_exec_command,
-       .dev_select             = ata_std_dev_select,
-
-       .freeze                 = ata_bmdma_freeze,
-       .thaw                   = ata_bmdma_thaw,
-       .error_handler          = ata_bmdma_error_handler,
-       .post_internal_cmd      = ata_bmdma_post_internal_cmd,
+       .inherits               = &ata_sff_port_ops,
+       .sff_data_xfer          = ata_sff_data_xfer_noirq,
        .cable_detect           = ata_cable_unknown,
-
-       .qc_prep                = ata_qc_prep,
-       .qc_issue               = ata_qc_issue_prot,
-
-       .data_xfer              = ata_data_xfer_noirq,
-
-       .irq_clear              = ata_noop_irq_clear,
-       .irq_on                 = ata_irq_on,
-
-       .port_start             = ata_dummy_ret0,
+       .set_mode               = pata_platform_set_mode,
+       .port_start             = ATA_OP_NULL,
 };
 
 static void pata_platform_setup_port(struct ata_ioports *ioaddr,
@@ -210,7 +176,7 @@ int __devinit __pata_platform_probe(struct device *dev,
                      (unsigned long long)ctl_res->start);
 
        /* activate */
-       return ata_host_activate(host, irq, irq ? ata_interrupt : NULL,
+       return ata_host_activate(host, irq, irq ? ata_sff_interrupt : NULL,
                                 irq_flags, &pata_platform_sht);
 }
 EXPORT_SYMBOL_GPL(__pata_platform_probe);
@@ -311,3 +277,4 @@ MODULE_AUTHOR("Paul Mundt");
 MODULE_DESCRIPTION("low-level driver for platform device ATA");
 MODULE_LICENSE("GPL");
 MODULE_VERSION(DRV_VERSION);
+MODULE_ALIAS("platform:" DRV_NAME);