vserver 1.9.3
[linux-2.6.git] / drivers / ide / pci / sgiioc4.c
index d8e739f..6a3d79b 100644 (file)
@@ -570,7 +570,6 @@ sgiioc4_build_dma_table(ide_drive_t * drive, struct request *rq, int ddir)
 use_pio_instead:
        pci_unmap_sg(hwif->pci_dev, hwif->sg_table, hwif->sg_nents,
                     hwif->sg_dma_direction);
-       hwif->sg_dma_active = 0;
 
        return 0;               /* revert to PIO for this request */
 }
@@ -702,6 +701,10 @@ sgiioc4_ide_setup_pci_device(struct pci_dev *dev, ide_pci_device_t * d)
                       hwif->name, d->name);
 
        probe_hwif_init(hwif);
+
+       /* Create /proc/ide entries */
+       create_proc_ide_interfaces(); 
+
        return 0;
 }
 
@@ -757,8 +760,6 @@ pci_init_sgiioc4(struct pci_dev *dev, ide_pci_device_t * d)
 static ide_pci_device_t sgiioc4_chipsets[] __devinitdata = {
        {
         /* Channel 0 */
-        .vendor = PCI_VENDOR_ID_SGI,
-        .device = PCI_DEVICE_ID_SGI_IOC4,
         .name = "SGIIOC4",
         .init_hwif = ide_init_sgiioc4,
         .init_dma = ide_dma_sgiioc4,
@@ -772,16 +773,7 @@ static ide_pci_device_t sgiioc4_chipsets[] __devinitdata = {
 static int __devinit
 sgiioc4_init_one(struct pci_dev *dev, const struct pci_device_id *id)
 {
-       ide_pci_device_t *d = &sgiioc4_chipsets[id->driver_data];
-       if (dev->device != d->device) {
-               printk(KERN_ERR "Error in %s(dev 0x%p | id 0x%p )\n",
-                      __FUNCTION__, (void *) dev, (void *) id);
-               BUG();
-       }
-
-       if (pci_init_sgiioc4(dev, d))
-               return 0;
-
+       pci_init_sgiioc4(dev, &sgiioc4_chipsets[id->driver_data]);
        return 0;
 }
 
@@ -793,7 +785,7 @@ static struct pci_device_id sgiioc4_pci_tbl[] = {
 MODULE_DEVICE_TABLE(pci, sgiioc4_pci_tbl);
 
 static struct pci_driver driver = {
-       .name = "SGI-IOC4 IDE",
+       .name = "SGI-IOC4_IDE",
        .id_table = sgiioc4_pci_tbl,
        .probe = sgiioc4_init_one,
 };