This commit was manufactured by cvs2svn to create tag
[linux-2.6.git] / drivers / scsi / sata_nv.c
index a21105c..10bebc9 100644 (file)
@@ -44,7 +44,7 @@
 #include <linux/libata.h>
 
 #define DRV_NAME                       "sata_nv"
-#define DRV_VERSION                    "0.5"
+#define DRV_VERSION                    "0.03"
 
 #define NV_PORTS                       2
 #define NV_PIO_MASK                    0x1f
@@ -218,18 +218,10 @@ static struct ata_port_operations nv_ops = {
        .host_stop              = nv_host_stop,
 };
 
-/* FIXME: The hardware provides the necessary SATA PHY controls
- * to support ATA_FLAG_SATA_RESET.  However, it is currently
- * necessary to disable that flag, to solve misdetection problems.
- * See http://bugme.osdl.org/show_bug.cgi?id=3352 for more info.
- *
- * This problem really needs to be investigated further.  But in the
- * meantime, we avoid ATA_FLAG_SATA_RESET to get people working.
- */
 static struct ata_port_info nv_port_info = {
        .sht            = &nv_sht,
        .host_flags     = ATA_FLAG_SATA |
-                         /* ATA_FLAG_SATA_RESET | */
+                         ATA_FLAG_SATA_RESET |
                          ATA_FLAG_SRST |
                          ATA_FLAG_NO_LEGACY,
        .pio_mask       = NV_PIO_MASK,
@@ -463,13 +455,12 @@ static void nv_check_hotplug(struct ata_host_set *host_set)
 
 static void nv_enable_hotplug_ck804(struct ata_probe_ent *probe_ent)
 {
-       struct pci_dev *pdev = to_pci_dev(probe_ent->dev);
        u8 intr_mask;
        u8 regval;
 
-       pci_read_config_byte(pdev, NV_MCP_SATA_CFG_20, &regval);
+       pci_read_config_byte(probe_ent->pdev, NV_MCP_SATA_CFG_20, &regval);
        regval |= NV_MCP_SATA_CFG_20_SATA_SPACE_EN;
-       pci_write_config_byte(pdev, NV_MCP_SATA_CFG_20, regval);
+       pci_write_config_byte(probe_ent->pdev, NV_MCP_SATA_CFG_20, regval);
 
        writeb(NV_INT_STATUS_HOTPLUG, probe_ent->mmio_base + NV_INT_STATUS_CK804);
 
@@ -481,7 +472,6 @@ static void nv_enable_hotplug_ck804(struct ata_probe_ent *probe_ent)
 
 static void nv_disable_hotplug_ck804(struct ata_host_set *host_set)
 {
-       struct pci_dev *pdev = to_pci_dev(host_set->dev);
        u8 intr_mask;
        u8 regval;
 
@@ -491,9 +481,9 @@ static void nv_disable_hotplug_ck804(struct ata_host_set *host_set)
 
        writeb(intr_mask, host_set->mmio_base + NV_INT_ENABLE_CK804);
 
-       pci_read_config_byte(pdev, NV_MCP_SATA_CFG_20, &regval);
+       pci_read_config_byte(host_set->pdev, NV_MCP_SATA_CFG_20, &regval);
        regval &= ~NV_MCP_SATA_CFG_20_SATA_SPACE_EN;
-       pci_write_config_byte(pdev, NV_MCP_SATA_CFG_20, regval);
+       pci_write_config_byte(host_set->pdev, NV_MCP_SATA_CFG_20, regval);
 }
 
 static void nv_check_hotplug_ck804(struct ata_host_set *host_set)