aboutsummaryrefslogtreecommitdiff
path: root/drivers/ata/pata_optidma.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-11 16:03:03 -0700
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-11 16:03:03 -0700
commitfb2c922b8588115d8914492493a37109bfb07884 (patch)
tree9b532d2989d998b1997bf04eae0f3eb15f1843b5 /drivers/ata/pata_optidma.c
parent9ce3075c20d458040138690edfdf6446664ec3ee (diff)
parentb9a3b4d1453689f2927668fcdc4827fdccf44d1b (diff)
Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev: pata_platform: don't use generic ata_port_start Use menuconfig objects: libata add the ATI SB700 SATA controller device id to AHCI pci table Add the combined mode for ATI SB700 pata_pcmcia: recognize 2GB CompactFlash from Transcend git-libata-all: sata_via build fix libata-acpi: clean up parameters and misc stuff libata-acpi: s/CONFIG_SATA_ACPI/CONFIG_ATA_ACPI/ libata: give devices one last chance even if recovery failed with -EINVAL libata: fallback to the other IDENTIFY on device error, take#2 libata: ignore EH scheduling during initialization libata: clean up SFF init mess libata: implement libata.spindown_compat libata: reimplement suspend/resume support using sdev->manage_start_stop
Diffstat (limited to 'drivers/ata/pata_optidma.c')
-rw-r--r--drivers/ata/pata_optidma.c16
1 files changed, 5 insertions, 11 deletions
diff --git a/drivers/ata/pata_optidma.c b/drivers/ata/pata_optidma.c
index 2843e480f21..3093b02286c 100644
--- a/drivers/ata/pata_optidma.c
+++ b/drivers/ata/pata_optidma.c
@@ -363,10 +363,6 @@ static struct scsi_host_template optidma_sht = {
.slave_configure = ata_scsi_slave_config,
.slave_destroy = ata_scsi_slave_destroy,
.bios_param = ata_std_bios_param,
-#ifdef CONFIG_PM
- .resume = ata_scsi_device_resume,
- .suspend = ata_scsi_device_suspend,
-#endif
};
static struct ata_port_operations optidma_port_ops = {
@@ -486,14 +482,14 @@ done_nomsg: /* Wrong chip revision */
static int optidma_init_one(struct pci_dev *dev, const struct pci_device_id *id)
{
- static struct ata_port_info info_82c700 = {
+ static const struct ata_port_info info_82c700 = {
.sht = &optidma_sht,
.flags = ATA_FLAG_SLAVE_POSS | ATA_FLAG_SRST,
.pio_mask = 0x1f,
.mwdma_mask = 0x07,
.port_ops = &optidma_port_ops
};
- static struct ata_port_info info_82c700_udma = {
+ static const struct ata_port_info info_82c700_udma = {
.sht = &optidma_sht,
.flags = ATA_FLAG_SLAVE_POSS | ATA_FLAG_SRST,
.pio_mask = 0x1f,
@@ -501,8 +497,7 @@ static int optidma_init_one(struct pci_dev *dev, const struct pci_device_id *id)
.udma_mask = 0x07,
.port_ops = &optiplus_port_ops
};
- static struct ata_port_info *port_info[2];
- struct ata_port_info *info = &info_82c700;
+ const struct ata_port_info *ppi[] = { &info_82c700, NULL };
static int printed_version;
if (!printed_version++)
@@ -514,10 +509,9 @@ static int optidma_init_one(struct pci_dev *dev, const struct pci_device_id *id)
pci_clock = inb(0x1F5) & 1; /* 0 = 33Mhz, 1 = 25Mhz */
if (optiplus_with_udma(dev))
- info = &info_82c700_udma;
+ ppi[0] = &info_82c700_udma;
- port_info[0] = port_info[1] = info;
- return ata_pci_init_one(dev, port_info, 2);
+ return ata_pci_init_one(dev, ppi);
}
static const struct pci_device_id optidma[] = {