ide: delete filenames/versions from comments
[pandora-kernel.git] / drivers / ide / legacy / umc8672.c
index ddc403a..26f38ce 100644 (file)
@@ -1,6 +1,4 @@
 /*
- *  linux/drivers/ide/legacy/umc8672.c         Version 0.05    Jul 31, 1996
- *
  *  Copyright (C) 1995-1996  Linus Torvalds & author (see below)
  */
 
@@ -105,12 +103,11 @@ static void umc_set_speeds (u8 speeds[])
                speeds[0], speeds[1], speeds[2], speeds[3]);
 }
 
-static void tune_umc (ide_drive_t *drive, u8 pio)
+static void umc_set_pio_mode(ide_drive_t *drive, const u8 pio)
 {
        unsigned long flags;
        ide_hwgroup_t *hwgroup = ide_hwifs[HWIF(drive)->index^1].hwgroup;
 
-       pio = ide_get_best_pio_mode(drive, pio, 4, NULL);
        printk("%s: setting umc8672 to PIO mode%d (speed %d)\n",
                drive->name, pio, pio_to_umc[pio]);
        spin_lock_irqsave(&ide_lock, flags);
@@ -125,8 +122,9 @@ static void tune_umc (ide_drive_t *drive, u8 pio)
 
 static int __init umc8672_probe(void)
 {
-       unsigned long flags;
        ide_hwif_t *hwif, *mate;
+       unsigned long flags;
+       static u8 idx[4] = { 0, 1, 0xff, 0xff };
 
        if (!request_region(0x108, 2, "umc8672")) {
                printk(KERN_ERR "umc8672: ports 0x108-0x109 already in use.\n");
@@ -149,19 +147,17 @@ static int __init umc8672_probe(void)
        mate = &ide_hwifs[1];
 
        hwif->chipset = ide_umc8672;
-       hwif->tuneproc = &tune_umc;
+       hwif->pio_mask = ATA_PIO4;
+       hwif->set_pio_mode = &umc_set_pio_mode;
        hwif->mate = mate;
 
        mate->chipset = ide_umc8672;
-       mate->tuneproc = &tune_umc;
+       mate->pio_mask = ATA_PIO4;
+       mate->set_pio_mode = &umc_set_pio_mode;
        mate->mate = hwif;
        mate->channel = 1;
 
-       probe_hwif_init(hwif);
-       probe_hwif_init(mate);
-
-       ide_proc_register_port(hwif);
-       ide_proc_register_port(mate);
+       ide_device_add(idx);
 
        return 0;
 }
@@ -171,8 +167,7 @@ int probe_umc8672 = 0;
 module_param_named(probe, probe_umc8672, bool, 0);
 MODULE_PARM_DESC(probe, "probe for UMC8672 chipset");
 
-/* Can be called directly from ide.c. */
-int __init umc8672_init(void)
+static int __init umc8672_init(void)
 {
        if (probe_umc8672 == 0)
                goto out;
@@ -183,9 +178,7 @@ out:
        return -ENODEV;;
 }
 
-#ifdef MODULE
 module_init(umc8672_init);
-#endif
 
 MODULE_AUTHOR("Wolfram Podien");
 MODULE_DESCRIPTION("Support for UMC 8672 IDE chipset");